![]() |
RTEMS
5.0.0
|
Timer API for the lpc176x bsp. More...
#include <bsp/timer-defs.h>
Go to the source code of this file.
Timer API for the lpc176x bsp.
|
inline |
Configures the capture ports.
tnumber | the device to be modified |
capture_port | which port of this timer will be setted |
function | At which edge/s will the capture work, and if it will interrupt |
|
inline |
Configures the external match ports.
tnumber | the device to be modified |
match_port | which match for this timer |
function | what should do when match: set, clear toggle or nothing |
|
inline |
Gets the captured value.
tnumber | the device to be modified |
capnumber | which capture port for this timer |
|
inline |
Gets the timer value.
tnumber | the device |
rtems_status_code lpc176x_timer_init | ( | lpc176x_timer_number | tnumber | ) |
Initializes timer in timer mode and resets counter but without starting it, and without any capture or match function.
tnumber | which timer |
rtems_status_code lpc176x_timer_init_with_interrupt | ( | lpc176x_timer_number | tnumber, |
const lpc176x_isr_funct_vector * | vector | ||
) |
Initializes timer in timer mode and resets counter but without starting it, and without any capture or match function.
tnumber | which timer to init |
vector | the functions to be used by the isr. |
|
inline |
true if timer is started.
tnumber | the timer number to check. |
is_started | TRUE if the timer is running. |
void lpc176x_timer_isr | ( | void * | lpc176x_timer_number | ) |
Timer generic isroutine.
timernumber | the number of timer. |
rtems_status_code lpc176x_timer_match_config | ( | lpc176x_timer_number | tnumber, |
lpc176x_match_port | match_port, | ||
lpc176x_match_function | function, | ||
uint32_t | match_value | ||
) |
Configures the timer match.
tnumber | the device to be modified |
match_port | which port of this timer will be setted |
function | what the timer should do when match: stop timer, clear, and/or interrupt |
match_value | the value that the timer should match. |
|
inline |
resets timer counter and stops it.
tnumber | the device to be reseted |
|
inline |
Sets mode of the timer (timer, counter rising, counter falling or counter both edges)
tnumber | the device to be setted |
mode | the desired mode |
|
inline |
sets the resolution in microseconds of the timer
tnumber | the device to be modified. |
resolution | how many microseconds will mean each timer counter unit. |
|
inline |
Sets the timer value.
tnumber | the timer to modify. |
timer_value | the value to set. |
|
inline |
Starts the timer counter.
tnumber | the device to be started |