From 27e1398be3821f814aee4eaf7627b2d8fb5c4934 Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Sat, 20 Feb 2016 13:51:02 +0000 Subject: Shell reorganization. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8913 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/various/shell/shell_cmd.h | 106 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 106 insertions(+) create mode 100644 os/various/shell/shell_cmd.h (limited to 'os/various/shell/shell_cmd.h') diff --git a/os/various/shell/shell_cmd.h b/os/various/shell/shell_cmd.h new file mode 100644 index 000000000..36e6c0728 --- /dev/null +++ b/os/various/shell/shell_cmd.h @@ -0,0 +1,106 @@ +/* + ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + +/** + * @file shell_cmd.h + * @brief Simple CLI shell common commands header. + * + * @addtogroup SHELL + * @{ + */ + +#ifndef _SHELLCMD_H_ +#define _SHELLCMD_H_ + +/*===========================================================================*/ +/* Module constants. */ +/*===========================================================================*/ + +/*===========================================================================*/ +/* Module pre-compile time settings. */ +/*===========================================================================*/ + +#if !defined(SHELL_CMD_INFO_ENABLED) || defined(__DOXYGEN__) +#define SHELL_CMD_INFO_ENABLED TRUE +#endif + +#if !defined(SHELL_CMD_SYSTIME_ENABLED) || defined(__DOXYGEN__) +#define SHELL_CMD_SYSTIME_ENABLED TRUE +#endif + +#if !defined(SHELL_CMD_MEM_ENABLED) || defined(__DOXYGEN__) +#define SHELL_CMD_MEM_ENABLED TRUE +#endif + +#if !defined(SHELL_CMD_THREADS_ENABLED) || defined(__DOXYGEN__) +#define SHELL_CMD_THREADS_ENABLED TRUE +#endif + +#if !defined(SHELL_CMD_TEST_ENABLED) || defined(__DOXYGEN__) +#define SHELL_CMD_TEST_ENABLED TRUE +#endif + +#if !defined(SHELL_CMD_TEST_WA_SIZE) || defined(__DOXYGEN__) +#define SHELL_CMD_TEST_WA_SIZE THD_WORKING_AREA_SIZE(256) +#endif + +/*===========================================================================*/ +/* Derived constants and error checks. */ +/*===========================================================================*/ + +#if (SHELL_CMD_MEM_ENABLED == TRUE) && (CH_CFG_USE_MEMCORE == FALSE) +#error "SHELL_CMD_MEM_ENABLED requires CH_CFG_USE_MEMCORE" +#endif + +#if (SHELL_CMD_MEM_ENABLED == TRUE) && (CH_CFG_USE_HEAP == FALSE) +#error "SHELL_CMD_MEM_ENABLED requires CH_CFG_USE_HEAP" +#endif + +#if (SHELL_CMD_THREADS_ENABLED == TRUE) && (CH_CFG_USE_REGISTRY == FALSE) +#error "SHELL_CMD_THREADS_ENABLED requires CH_CFG_USE_REGISTRY" +#endif + +/*===========================================================================*/ +/* Module data structures and types. */ +/*===========================================================================*/ + +/*===========================================================================*/ +/* Module macros. */ +/*===========================================================================*/ + +/*===========================================================================*/ +/* External declarations. */ +/*===========================================================================*/ + +#if !defined(__DOXYGEN__) +extern ShellCommand shell_local_commands[]; +#endif + +#ifdef __cplusplus +extern "C" { +#endif + +#ifdef __cplusplus +} +#endif + +/*===========================================================================*/ +/* Module inline functions. */ +/*===========================================================================*/ + +#endif /* _SHELLCMD_H_ */ + +/** @} */ -- cgit v1.2.3