![]() |
LPCOpen Platform
LPCOpen Platform for NXP LPC Microcontrollers
|
Functions | |
STATIC INLINE bool | Chip_TIMER_MatchPending (LPC_TIMER_Type *TMRx, int8_t matchnum) |
Determine if a match interrupt is pending. | |
STATIC INLINE bool | Chip_TIMER_CapturePending (LPC_TIMER_Type *TMRx, int8_t capnum) |
Determine if a capture interrupt is pending. | |
STATIC INLINE void | Chip_TIMER_ClearMatch (LPC_TIMER_Type *TMRx, int8_t matchnum) |
Clears a (pending) match interrupt. | |
STATIC INLINE void | Chip_TIMER_ClearCapture (LPC_TIMER_Type *TMRx, int8_t capnum) |
Clears a (pending) capture interrupt. | |
STATIC INLINE void | Chip_TIMER_Enable (LPC_TIMER_Type *TMRx) |
Enables the timer (starts count) | |
STATIC INLINE void | Chip_TIMER_Disable (LPC_TIMER_Type *TMRx) |
Disables the timer (stops count) | |
STATIC INLINE uint32_t | Chip_TIMER_ReadCount (LPC_TIMER_Type *TMRx) |
Returns the current timer count. | |
STATIC INLINE uint32_t | Chip_TIMER_ReadPrescale (LPC_TIMER_Type *TMRx) |
Returns the current prescale count. | |
STATIC INLINE void | Chip_TIMER_PrescaleSet (LPC_TIMER_Type *TMRx, uint32_t prescale) |
Sets the prescaler value. | |
STATIC INLINE void | Chip_TIMER_SetMatch (LPC_TIMER_Type *TMRx, int8_t matchnum, uint32_t matchval) |
Sets a timer match value. | |
STATIC INLINE uint32_t | Chip_TIMER_ReadCapture (LPC_TIMER_Type *TMRx, int8_t capnum) |
Reads a capture register. | |
STATIC INLINE void | Chip_TIMER_Reset (LPC_TIMER_Type *TMRx) |
Resets the timer terminal and prescale counts to 0. | |
STATIC INLINE void | Chip_TIMER_MatchEnableInt (LPC_TIMER_Type *TMRx, int8_t matchnum) |
Enables a match interrupt that fires when the terminal count matches the match counter value. | |
STATIC INLINE void | Chip_TIMER_MatchDisableInt (LPC_TIMER_Type *TMRx, int8_t matchnum) |
Disables a match interrupt for a match counter. | |
STATIC INLINE void | Chip_TIMER_ResetOnMatchEnable (LPC_TIMER_Type *TMRx, int8_t matchnum) |
For the specific match counter, enables reset of the terminal count register when a match occurs. | |
STATIC INLINE void | Chip_TIMER_ResetOnMatchDisable (LPC_TIMER_Type *TMRx, int8_t matchnum) |
For the specific match counter, disables reset of the terminal count register when a match occurs. | |
STATIC INLINE void | Chip_TIMER_StopOnMatchEnable (LPC_TIMER_Type *TMRx, int8_t matchnum) |
Enable a match timer to stop the terminal count when a match count equals the terminal count. | |
STATIC INLINE void | Chip_TIMER_StopOnMatchDisable (LPC_TIMER_Type *TMRx, int8_t matchnum) |
Disable stop on match for a match timer. Disables a match timer to stop the terminal count when a match count equals the terminal count. | |
STATIC INLINE void | Chip_TIMER_CaptureRisingEdgeEnable (LPC_TIMER_Type *TMRx, int8_t capnum) |
Enables capture on on rising edge of selected CAP signal for the selected capture register, enables the selected CAPn.capnum signal to load the capture register with the terminal coount on a rising edge. | |
STATIC INLINE void | Chip_TIMER_CaptureRisingEdgeDisable (LPC_TIMER_Type *TMRx, int8_t capnum) |
Disables capture on on rising edge of selected CAP signal. For the selected capture register, disables the selected CAPn.capnum signal to load the capture register with the terminal coount on a rising edge. | |
STATIC INLINE void | Chip_TIMER_CaptureFallingEdgeEnable (LPC_TIMER_Type *TMRx, int8_t capnum) |
Enables capture on on falling edge of selected CAP signal. For the selected capture register, enables the selected CAPn.capnum signal to load the capture register with the terminal coount on a falling edge. | |
STATIC INLINE void | Chip_TIMER_CaptureFallingEdgeDisable (LPC_TIMER_Type *TMRx, int8_t capnum) |
Disables capture on on falling edge of selected CAP signal. For the selected capture register, disables the selected CAPn.capnum signal to load the capture register with the terminal coount on a falling edge. | |
STATIC INLINE void | Chip_TIMER_CaptureEnableInt (LPC_TIMER_Type *TMRx, int8_t capnum) |
Enables interrupt on capture of selected CAP signal. For the selected capture register, an interrupt will be generated when the enabled rising or falling edge on CAPn.capnum is detected. | |
STATIC INLINE void | Chip_TIMER_CaptureDisableInt (LPC_TIMER_Type *TMRx, int8_t capnum) |
Disables interrupt on capture of selected CAP signal. | |
STATIC INLINE void | Chip_TIMER_ExtMatchControlSet (LPC_TIMER_Type *TMRx, int8_t initial_state, IP_TIMER_PIN_MATCH_STATE_Type matchState, int8_t matchnum) |
Sets external match control (MATn.matchnum) pin control. | |
STATIC INLINE void | Chip_TIMER_TIMER_SetCountClockSrc (LPC_TIMER_Type *TMRx, IP_TIMER_CAP_SRC_STATE_Type capSrc, int8_t capnum) |
Sets timer count source and edge with the selected passed from CapSrc. | |
STATIC INLINE void Chip_TIMER_CaptureDisableInt | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Disables interrupt on capture of selected CAP signal.
TMRx | : Pointer to timer IP register address |
capnum | : Capture signal/register to use |
Definition at line 327 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_CaptureEnableInt | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Enables interrupt on capture of selected CAP signal. For the selected capture register, an interrupt will be generated when the enabled rising or falling edge on CAPn.capnum is detected.
TMRx | : Pointer to timer IP register address |
capnum | : Capture signal/register to use |
Definition at line 316 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_CaptureFallingEdgeDisable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Disables capture on on falling edge of selected CAP signal. For the selected capture register, disables the selected CAPn.capnum signal to load the capture register with the terminal coount on a falling edge.
TMRx | : Pointer to timer IP register address |
capnum | : Capture signal/register to use |
Definition at line 303 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_CaptureFallingEdgeEnable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Enables capture on on falling edge of selected CAP signal. For the selected capture register, enables the selected CAPn.capnum signal to load the capture register with the terminal coount on a falling edge.
TMRx | : Pointer to timer IP register address |
capnum | : Capture signal/register to use |
Definition at line 290 of file timer_18xx_43xx.h.
STATIC INLINE bool Chip_TIMER_CapturePending | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Determine if a capture interrupt is pending.
TMRx | : Pointer to timer IP register address |
capnum | : Capture interrupt number to check |
Definition at line 67 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_CaptureRisingEdgeDisable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Disables capture on on rising edge of selected CAP signal. For the selected capture register, disables the selected CAPn.capnum signal to load the capture register with the terminal coount on a rising edge.
TMRx | : Pointer to timer IP register address |
capnum | : Capture signal/register to use |
Definition at line 277 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_CaptureRisingEdgeEnable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Enables capture on on rising edge of selected CAP signal for the selected capture register, enables the selected CAPn.capnum signal to load the capture register with the terminal coount on a rising edge.
TMRx | : Pointer to timer IP register address |
capnum | : Capture signal/register to use |
Definition at line 264 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_ClearCapture | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Clears a (pending) capture interrupt.
TMRx | : Pointer to timer IP register address |
capnum | : Capture interrupt number to clear |
Definition at line 91 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_ClearMatch | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
Clears a (pending) match interrupt.
TMRx | : Pointer to timer IP register address |
matchnum | : Match interrupt number to clear |
Definition at line 79 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_Disable | ( | LPC_TIMER_Type * | TMRx | ) |
Disables the timer (stops count)
TMRx | : Pointer to timer IP register address |
Definition at line 113 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_Enable | ( | LPC_TIMER_Type * | TMRx | ) |
Enables the timer (starts count)
TMRx | : Pointer to timer IP register address |
Definition at line 102 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_ExtMatchControlSet | ( | LPC_TIMER_Type * | TMRx, |
int8_t | initial_state, | ||
IP_TIMER_PIN_MATCH_STATE_Type | matchState, | ||
int8_t | matchnum | ||
) |
Sets external match control (MATn.matchnum) pin control.
TMRx | : Pointer to timer IP register address |
initial_state | : Initial state of the pin, high(1) or low(0) |
matchState | : Selects the match state for the pin |
matchnum | : MATn.matchnum signal to use |
Definition at line 342 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_MatchDisableInt | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
Disables a match interrupt for a match counter.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer, 0 to 3 |
Definition at line 205 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_MatchEnableInt | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
Enables a match interrupt that fires when the terminal count matches the match counter value.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer, 0 to 3 |
Definition at line 194 of file timer_18xx_43xx.h.
STATIC INLINE bool Chip_TIMER_MatchPending | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
Determine if a match interrupt is pending.
TMRx | : Pointer to timer IP register address |
matchnum | : Match interrupt number to check |
Definition at line 54 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_PrescaleSet | ( | LPC_TIMER_Type * | TMRx, |
uint32_t | prescale | ||
) |
Sets the prescaler value.
TMRx | : Pointer to timer IP register address |
prescale | : Prescale value to set the prescale register to |
Definition at line 147 of file timer_18xx_43xx.h.
STATIC INLINE uint32_t Chip_TIMER_ReadCapture | ( | LPC_TIMER_Type * | TMRx, |
int8_t | capnum | ||
) |
Reads a capture register.
TMRx | : Pointer to timer IP register address |
capnum | : Capture register to read |
Definition at line 172 of file timer_18xx_43xx.h.
STATIC INLINE uint32_t Chip_TIMER_ReadCount | ( | LPC_TIMER_Type * | TMRx | ) |
Returns the current timer count.
TMRx | : Pointer to timer IP register address |
Definition at line 124 of file timer_18xx_43xx.h.
STATIC INLINE uint32_t Chip_TIMER_ReadPrescale | ( | LPC_TIMER_Type * | TMRx | ) |
Returns the current prescale count.
TMRx | : Pointer to timer IP register address |
Definition at line 135 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_Reset | ( | LPC_TIMER_Type * | TMRx | ) |
Resets the timer terminal and prescale counts to 0.
TMRx | : Pointer to timer IP register address |
Definition at line 182 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_ResetOnMatchDisable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
For the specific match counter, disables reset of the terminal count register when a match occurs.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer, 0 to 3 |
Definition at line 227 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_ResetOnMatchEnable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
For the specific match counter, enables reset of the terminal count register when a match occurs.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer, 0 to 3 |
Definition at line 216 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_SetMatch | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum, | ||
uint32_t | matchval | ||
) |
Sets a timer match value.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer to set match count for |
matchval | : Match value for the selected match count |
Definition at line 160 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_StopOnMatchDisable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
Disable stop on match for a match timer. Disables a match timer to stop the terminal count when a match count equals the terminal count.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer, 0 to 3 |
Definition at line 251 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_StopOnMatchEnable | ( | LPC_TIMER_Type * | TMRx, |
int8_t | matchnum | ||
) |
Enable a match timer to stop the terminal count when a match count equals the terminal count.
TMRx | : Pointer to timer IP register address |
matchnum | : Match timer, 0 to 3 |
Definition at line 239 of file timer_18xx_43xx.h.
STATIC INLINE void Chip_TIMER_TIMER_SetCountClockSrc | ( | LPC_TIMER_Type * | TMRx, |
IP_TIMER_CAP_SRC_STATE_Type | capSrc, | ||
int8_t | capnum | ||
) |
Sets timer count source and edge with the selected passed from CapSrc.
TMRx | : Pointer to timer IP register address |
capSrc | : timer clock source and edge |
capnum | : CAPn.capnum pin to use (if used) |
Definition at line 356 of file timer_18xx_43xx.h.