extern "C" {\r
#endif\r
\r
+/* IDs for commands that can be sent/received on the timer queue. */\r
+#define tmrCOMMAND_START 0\r
+#define tmrCOMMAND_STOP 1\r
+#define tmrCOMMAND_CHANGE_PERIOD 2\r
+#define tmrCOMMAND_DELETE 3\r
+\r
/*-----------------------------------------------------------\r
* MACROS AND DEFINITIONS\r
*----------------------------------------------------------*/\r
\r
portBASE_TYPE xTimerCreateTimerTask( void ) PRIVILEGED_FUNCTION;\r
xTimerHandle xTimerCreate( const signed char *pcTimerName, portTickType xTimerPeriod, unsigned portBASE_TYPE uxAutoReload, void * pvTimerID, tmrTIMER_CALLBACK pxCallbackFunction ) PRIVILEGED_FUNCTION;\r
-portBASE_TYPE xTimerStart( xTimerHandle xTimer, portTickType xBlockTime ); /* Must not attempt to block if scheduler not started. */\r
void *pvTimerGetTimerID( xTimerHandle xTimer );\r
+portBASE_TYPE xTimerGenericCommand( xTimerHandle xTimer, portBASE_TYPE xCommandID, portTickType xOptionalValue, portTickType xBlockTime );\r
+portBASE_TYPE xTimerIsTimerActive( xTimerHandle xTimer );\r
\r
+#define xTimerStart( xTimer, xBlockTime ) xTimerGenericCommand( xTimer, tmrCOMMAND_START, 0, xBlockTime )\r
+#define xTimerStop( xTimer, xBlockTime ) xTimerGenericCommand( xTimer, tmrCOMMAND_STOP, 0, xBlockTime )\r
+#define xTimerChangePeriod( xTimer, xNewPeriod, xBlockTime ) xTimerGenericCommand( xTimer, tmrCOMMAND_CHANGE_PERIOD, xNewPeriod, xBlockTime )\r
+#define xTimerDelete( xTimer, xBlockTime ) xTimerGenericCommand( xTimer, tmrCOMMAND_DELETE, 0, xBlockTime )\r
\r
#ifdef __cplusplus\r
}\r