From 8b2ddb7f2bdedc7a7c62d9a1197e9f6a746bd106 Mon Sep 17 00:00:00 2001 From: barthess Date: Tue, 3 Mar 2015 21:10:03 +0300 Subject: EICU. Cosmetical improvements. --- os/hal/include/eicu.h | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'os') diff --git a/os/hal/include/eicu.h b/os/hal/include/eicu.h index 121fc2d..a4ab30f 100644 --- a/os/hal/include/eicu.h +++ b/os/hal/include/eicu.h @@ -43,27 +43,27 @@ * @brief Driver state machine possible states. */ typedef enum { - EICU_UNINIT = 0, /* Not initialized. */ - EICU_STOP = 1, /* Stopped. */ - EICU_READY = 2, /* Ready. */ - EICU_WAITING = 3, /* Waiting for first edge. */ - EICU_ACTIVE = 4, /* Active cycle phase. */ - EICU_IDLE = 5 /* Idle cycle phase. */ + EICU_UNINIT, /* Not initialized. */ + EICU_STOP, /* Stopped. */ + EICU_READY, /* Ready. */ + EICU_WAITING, /* Waiting for first edge. */ + EICU_ACTIVE, /* Active cycle phase. */ + EICU_IDLE /* Idle cycle phase. */ } eicustate_t; /** * @brief Channel state machine possible states. */ typedef enum { - EICU_CH_IDLE = 0, /* Idle cycle phase. */ - EICU_CH_ACTIVE = 1 /* Active cycle phase. */ + EICU_CH_IDLE, /* Idle cycle phase. */ + EICU_CH_ACTIVE /* Active cycle phase. */ } eicuchannelstate_t; /** * @brief EICU channel selection definition */ typedef enum { - EICU_CHANNEL_1 = 0, + EICU_CHANNEL_1, EICU_CHANNEL_2, EICU_CHANNEL_3, EICU_CHANNEL_4, @@ -158,9 +158,9 @@ static inline void _eicu_isr_invoke_pwm_period_cb(EICUDriver *eicup, * * @notapi */ -#define _eicu_isr_invoke_overflow_cb(icup) { \ +#define _eicu_isr_invoke_overflow_cb(icup) do { \ (eicup)->config->overflow_cb(eicup, 0, 0, 0); \ -} +} while (0) /** @} */ /*===========================================================================*/ -- cgit v1.2.3