From a86b48c578db236dddea8f141db7607741d48e57 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Thu, 12 Sep 2013 17:45:10 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/kernel_3_dev@6298 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/nil/osal/osal.h | 24 +++++++++++++++++++----- 1 file changed, 19 insertions(+), 5 deletions(-) (limited to 'os/nil') diff --git a/os/nil/osal/osal.h b/os/nil/osal/osal.h index 71d47894f..93483e6f0 100644 --- a/os/nil/osal/osal.h +++ b/os/nil/osal/osal.h @@ -85,6 +85,20 @@ #define OSAL_ST_MODE_FREERUNNING 2 /** @} */ +/** + * @name Systick parameters. + * @{ + */ +/** + * @brief Size in bits of the @p systick_t type. + */ +#define OSAL_ST_RESOLUTION NIL_CFG_ST_RESOLUTION + +/** + * @brief Required systick frequency or resolution. + */ +#define OSAL_ST_FREQUENCY NIL_CFG_ST_FREQUENCY + /** * @brief Systick mode required by the underlying OS. */ @@ -93,11 +107,7 @@ #else #define OSAL_ST_MODE OSAL_ST_MODE_FREERUNNING #endif - -/** - * @brief Required systick frequency or resolution. - */ -#define OSAL_SYSTICK_FREQUENCY NIL_CFG_ST_FREQUENCY +/** @} */ /*===========================================================================*/ /* Module pre-compile time settings. */ @@ -117,6 +127,10 @@ #error "invalid OSAL_ST_MODE setting in osal.h" #endif +#if (OSAL_ST_RESOLUTION != 16) && (OSAL_ST_RESOLUTION != 32) +#error "invalid OSAL_ST_RESOLUTION, must be 16 or 32" +#endif + /*===========================================================================*/ /* Module data structures and types. */ /*===========================================================================*/ -- cgit v1.2.3