uc-sdk
|
Macros | |
#define | TIM_IR_CLR(n) _BIT(n) |
#define | TIM_MATCH_INT(n) (_BIT(n & 0x0F)) |
#define | TIM_CAP_INT(n) (_BIT(((n & 0x0F) + 4))) |
#define | TIM_ENABLE ((uint32_t)(1<<0)) |
#define | TIM_RESET ((uint32_t)(1<<1)) |
#define | TIM_TCR_MASKBIT ((uint32_t)(3)) |
#define | TIM_INT_ON_MATCH(n) (_BIT((n * 3))) |
#define | TIM_RESET_ON_MATCH(n) (_BIT(((n * 3) + 1))) |
#define | TIM_STOP_ON_MATCH(n) (_BIT(((n * 3) + 2))) |
#define | TIM_MCR_MASKBIT ((uint32_t)(0x0FFF)) |
#define | TIM_MCR_CHANNEL_MASKBIT(n) ((uint32_t)(7<<(n*3))) |
#define | TIM_CAP_RISING(n) (_BIT((n * 3))) |
#define | TIM_CAP_FALLING(n) (_BIT(((n * 3) + 1))) |
#define | TIM_INT_ON_CAP(n) (_BIT(((n * 3) + 2))) |
#define | TIM_EDGE_MASK(n) (_SBF((n * 3), 0x03)) |
#define | TIM_CCR_MASKBIT ((uint32_t)(0x3F)) |
#define | TIM_CCR_CHANNEL_MASKBIT(n) ((uint32_t)(7<<(n*3))) |
#define | TIM_EM(n) _BIT(n) |
#define | TIM_EM_NOTHING ((uint8_t)(0x0)) |
#define | TIM_EM_LOW ((uint8_t)(0x1)) |
#define | TIM_EM_HIGH ((uint8_t)(0x2)) |
#define | TIM_EM_TOGGLE ((uint8_t)(0x3)) |
#define | TIM_EM_SET(n, s) (_SBF(((n << 1) + 4), (s & 0x03))) |
#define | TIM_EM_MASK(n) (_SBF(((n << 1) + 4), 0x03)) |
#define | TIM_EMR_MASKBIT 0x0FFF |
#define | TIM_CTCR_MODE_MASK 0x3 |
#define | TIM_CTCR_INPUT_MASK 0xC |
#define | TIM_CTCR_MASKBIT 0xF |
#define | TIM_COUNTER_MODE ((uint8_t)(1)) |
#define | PARAM_TIMx(n) |
#define | PARAM_TIM_INT_TYPE(TYPE) |
#define | PARAM_TIM_MODE_OPT(MODE) |
#define | PARAM_TIM_PRESCALE_OPT(OPT) ((OPT == TIM_PRESCALE_TICKVAL)||(OPT == TIM_PRESCALE_USVAL)) |
#define | PARAM_TIM_COUNTER_INPUT_OPT(OPT) ((OPT == TIM_COUNTER_INCAP0)||(OPT == TIM_COUNTER_INCAP1)) |
#define | PARAM_TIM_EXTMATCH_OPT(OPT) |
#define | PARAM_TIM_CAP_MODE_OPT(OPT) |
#define PARAM_TIM_CAP_MODE_OPT | ( | OPT) |
Definition at line 156 of file lpc17xx_timer.h.
#define PARAM_TIM_COUNTER_INPUT_OPT | ( | OPT) | ((OPT == TIM_COUNTER_INCAP0)||(OPT == TIM_COUNTER_INCAP1)) |
Definition at line 149 of file lpc17xx_timer.h.
#define PARAM_TIM_EXTMATCH_OPT | ( | OPT) |
Definition at line 152 of file lpc17xx_timer.h.
#define PARAM_TIM_INT_TYPE | ( | TYPE) |
Definition at line 137 of file lpc17xx_timer.h.
#define PARAM_TIM_MODE_OPT | ( | MODE) |
Definition at line 142 of file lpc17xx_timer.h.
#define PARAM_TIM_PRESCALE_OPT | ( | OPT) | ((OPT == TIM_PRESCALE_TICKVAL)||(OPT == TIM_PRESCALE_USVAL)) |
Definition at line 146 of file lpc17xx_timer.h.
#define PARAM_TIMx | ( | n) |
#define TIM_CAP_FALLING | ( | n) | (_BIT(((n * 3) + 1))) |
Bit location for CAP.n on CRx falling edge, n = 0 to 3
Definition at line 88 of file lpc17xx_timer.h.
#define TIM_CAP_INT | ( | n) | (_BIT(((n & 0x0F) + 4))) |
Macro for getting a capture event interrupt bit
Definition at line 56 of file lpc17xx_timer.h.
#define TIM_CAP_RISING | ( | n) | (_BIT((n * 3))) |
Bit location for CAP.n on CRx rising edge, n = 0 to 3
Definition at line 86 of file lpc17xx_timer.h.
#define TIM_CCR_CHANNEL_MASKBIT | ( | n) | ((uint32_t)(7<<(n*3))) |
Timer Capture control bit mask for specific channel
Definition at line 96 of file lpc17xx_timer.h.
#define TIM_CCR_MASKBIT ((uint32_t)(0x3F)) |
Timer capture control bit mask
Definition at line 94 of file lpc17xx_timer.h.
#define TIM_COUNTER_MODE ((uint8_t)(1)) |
Definition at line 128 of file lpc17xx_timer.h.
#define TIM_CTCR_INPUT_MASK 0xC |
Mask to get the count input select bits
Definition at line 125 of file lpc17xx_timer.h.
#define TIM_CTCR_MASKBIT 0xF |
Timer Count control bit mask
Definition at line 127 of file lpc17xx_timer.h.
#define TIM_CTCR_MODE_MASK 0x3 |
Mask to get the Counter/timer mode bits
Definition at line 123 of file lpc17xx_timer.h.
#define TIM_EDGE_MASK | ( | n) | (_SBF((n * 3), 0x03)) |
Mask bit for rising and falling edge bit
Definition at line 92 of file lpc17xx_timer.h.
#define TIM_EM | ( | n) | _BIT(n) |
Bit location for output state change of MAT.n when external match happens, n = 0 to 3
Definition at line 103 of file lpc17xx_timer.h.
#define TIM_EM_HIGH ((uint8_t)(0x2)) |
Output state change of MAT.n when external match happens: high
Definition at line 109 of file lpc17xx_timer.h.
#define TIM_EM_LOW ((uint8_t)(0x1)) |
Output state change of MAT.n when external match happens: low
Definition at line 107 of file lpc17xx_timer.h.
#define TIM_EM_MASK | ( | n) | (_SBF(((n << 1) + 4), 0x03)) |
Mask for the MAT.n change state bits
Definition at line 115 of file lpc17xx_timer.h.
#define TIM_EM_NOTHING ((uint8_t)(0x0)) |
Output state change of MAT.n when external match happens: no change
Definition at line 105 of file lpc17xx_timer.h.
#define TIM_EM_SET | ( | n, | |
s | |||
) | (_SBF(((n << 1) + 4), (s & 0x03))) |
Macro for setting for the MAT.n change state bits
Definition at line 113 of file lpc17xx_timer.h.
#define TIM_EM_TOGGLE ((uint8_t)(0x3)) |
Output state change of MAT.n when external match happens: toggle
Definition at line 111 of file lpc17xx_timer.h.
#define TIM_EMR_MASKBIT 0x0FFF |
Timer external match bit mask
Definition at line 117 of file lpc17xx_timer.h.
#define TIM_ENABLE ((uint32_t)(1<<0)) |
Timer/counter enable bit
Definition at line 62 of file lpc17xx_timer.h.
#define TIM_INT_ON_CAP | ( | n) | (_BIT(((n * 3) + 2))) |
Bit location for CAP.n on CRx interrupt enable, n = 0 to 3
Definition at line 90 of file lpc17xx_timer.h.
#define TIM_INT_ON_MATCH | ( | n) | (_BIT((n * 3))) |
Bit location for interrupt on MRx match, n = 0 to 3
Definition at line 72 of file lpc17xx_timer.h.
#define TIM_IR_CLR | ( | n) | _BIT(n) |
Macro to clean interrupt pending
Definition at line 48 of file lpc17xx_timer.h.
#define TIM_MATCH_INT | ( | n) | (_BIT(n & 0x0F)) |
Macro for getting a timer match interrupt bit
Definition at line 54 of file lpc17xx_timer.h.
#define TIM_MCR_CHANNEL_MASKBIT | ( | n) | ((uint32_t)(7<<(n*3))) |
Timer Match control bit mask for specific channel
Definition at line 80 of file lpc17xx_timer.h.
#define TIM_MCR_MASKBIT ((uint32_t)(0x0FFF)) |
Timer Match control bit mask
Definition at line 78 of file lpc17xx_timer.h.
#define TIM_RESET ((uint32_t)(1<<1)) |
Timer/counter reset bit
Definition at line 64 of file lpc17xx_timer.h.
#define TIM_RESET_ON_MATCH | ( | n) | (_BIT(((n * 3) + 1))) |
Bit location for reset on MRx match, n = 0 to 3
Definition at line 74 of file lpc17xx_timer.h.
#define TIM_STOP_ON_MATCH | ( | n) | (_BIT(((n * 3) + 2))) |
Bit location for stop on MRx match, n = 0 to 3
Definition at line 76 of file lpc17xx_timer.h.
#define TIM_TCR_MASKBIT ((uint32_t)(3)) |
Timer control bit mask
Definition at line 66 of file lpc17xx_timer.h.