From 50f9e505e509956d401341762da15c1d8267522e Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Tue, 16 Feb 2016 10:47:01 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@8903 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile | 6 ++--- demos/LPC21xx/RT-LPC214x-OLIMEX/chconf.h | 43 +++++++++++++++++++++++++++----- 2 files changed, 40 insertions(+), 9 deletions(-) (limited to 'demos/LPC21xx') diff --git a/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile b/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile index b6c0a82c6..5a3896d68 100644 --- a/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile +++ b/demos/LPC21xx/RT-LPC214x-OLIMEX/Makefile @@ -112,7 +112,7 @@ PROJECT = ch # Imported source files and paths CHIBIOS = ../../.. # Startup files. -include $(CHIBIOS)/os/common/ports/ARM/compilers/GCC/mk/startup_lpc214x.mk +include $(CHIBIOS)/os/common/startup/ARM/compilers/GCC/mk/startup_lpc214x.mk # HAL-OSAL files (optional). include $(CHIBIOS)/os/hal/hal.mk include $(CHIBIOS)/os/hal/ports/LPC/LPC214x/platform.mk @@ -120,7 +120,7 @@ include $(CHIBIOS)/os/hal/boards/OLIMEX_LPC_P2148/board.mk include $(CHIBIOS)/os/hal/osal/rt/osal.mk # RTOS files (optional). include $(CHIBIOS)/os/rt/rt.mk -include $(CHIBIOS)/os/rt/ports/ARM/compilers/GCC/mk/port_generic.mk +include $(CHIBIOS)/os/common/ports/ARM/compilers/GCC/mk/port_generic.mk # Other files (optional). include $(CHIBIOS)/test/rt/test.mk @@ -236,5 +236,5 @@ ULIBS = # End of user defines ############################################################################## -RULESPATH = $(CHIBIOS)/os/common/ports/ARM/compilers/GCC +RULESPATH = $(CHIBIOS)/os/common/startup/ARM/compilers/GCC include $(RULESPATH)/rules.mk diff --git a/demos/LPC21xx/RT-LPC214x-OLIMEX/chconf.h b/demos/LPC21xx/RT-LPC214x-OLIMEX/chconf.h index 4fb581a09..e49bdc2a2 100644 --- a/demos/LPC21xx/RT-LPC214x-OLIMEX/chconf.h +++ b/demos/LPC21xx/RT-LPC214x-OLIMEX/chconf.h @@ -28,6 +28,8 @@ #ifndef _CHCONF_H_ #define _CHCONF_H_ +#define _CHIBIOS_RT_CONF_ + /*===========================================================================*/ /** * @name System timers settings @@ -190,6 +192,7 @@ * memory footprint. * * @note The default is @p FALSE. + * @note Requires @p CH_CFG_USE_MUTEXES. */ #define CH_CFG_USE_MUTEXES_RECURSIVE FALSE @@ -359,9 +362,16 @@ * @details If enabled then the context switch circular trace buffer is * activated. * - * @note The default is @p FALSE. + * @note The default is @p CH_DBG_TRACE_MASK_NONE. + */ +#define CH_DBG_TRACE_MASK CH_DBG_TRACE_MASK_NONE + +/** + * @brief Trace buffer entries. + * @note The trace buffer is only allocated if @p CH_DBG_TRACE_MASK is + * different from @p CH_DBG_TRACE_MASK_NONE. */ -#define CH_DBG_ENABLE_TRACE FALSE +#define CH_DBG_TRACE_BUFFER_SIZE 128 /** * @brief Debug option, stack checks. @@ -426,10 +436,6 @@ /** * @brief Threads finalization hook. * @details User finalization code added to the @p chThdExit() API. - * - * @note It is inserted into lock zone. - * @note It is also invoked when the threads simply return in order to - * terminate. */ #define CH_CFG_THREAD_EXIT_HOOK(tp) { \ /* Add threads finalization code here.*/ \ @@ -443,6 +449,20 @@ /* Context switch code here.*/ \ } +/** + * @brief ISR enter hook. + */ +#define CH_CFG_IRQ_PROLOGUE_HOOK() { \ + /* IRQ prologue code here.*/ \ +} + +/** + * @brief ISR exit hook. + */ +#define CH_CFG_IRQ_EPILOGUE_HOOK() { \ + /* IRQ epilogue code here.*/ \ +} + /** * @brief Idle thread enter hook. * @note This hook is invoked within a critical zone, no OS functions @@ -450,6 +470,7 @@ * @note This macro can be used to activate a power saving mode. */ #define CH_CFG_IDLE_ENTER_HOOK() { \ + /* Idle-enter code here.*/ \ } /** @@ -459,6 +480,7 @@ * @note This macro can be used to deactivate a power saving mode. */ #define CH_CFG_IDLE_LEAVE_HOOK() { \ + /* Idle-leave code here.*/ \ } /** @@ -487,6 +509,15 @@ /* System halt code here.*/ \ } +/** + * @brief Trace hook. + * @details This hook is invoked each time a new record is written in the + * trace buffer. + */ +#define CH_CFG_TRACE_HOOK(tep) { \ + /* Trace code here.*/ \ +} + /** @} */ /*===========================================================================*/ -- cgit v1.2.3