APM:Libraries
|
Go to the source code of this file.
Macros | |
#define | DEMCR_TRCENA 0x01000000 |
#define | DEMCR (*((volatile uint32_t *)0xE000EDFC)) |
#define | DWT_CTRL (*(volatile uint32_t *)0xe0001000) |
#define | CYCCNTENA (1<<0) |
#define | DWT_CYCCNT ((volatile uint32_t *)0xE0001004) |
#define | CPU_CYCLES *DWT_CYCCNT |
Functions | |
void | stopwatch_init (void) |
void | stopwatch_delay_us (uint32_t us) |
static void | stopwatch_reset (void) |
static uint32_t | stopwatch_getticks () |
Variables | |
uint32_t | us_ticks |
#define CPU_CYCLES *DWT_CYCCNT |
Definition at line 19 of file stopwatch.h.
Referenced by stopwatch_getticks().
#define CYCCNTENA (1<<0) |
Definition at line 17 of file stopwatch.h.
Referenced by stopwatch_init(), and stopwatch_reset().
#define DEMCR (*((volatile uint32_t *)0xE000EDFC)) |
Definition at line 14 of file stopwatch.h.
Referenced by stopwatch_init(), and stopwatch_reset().
#define DEMCR_TRCENA 0x01000000 |
Definition at line 11 of file stopwatch.h.
Referenced by stopwatch_init(), and stopwatch_reset().
#define DWT_CTRL (*(volatile uint32_t *)0xe0001000) |
Definition at line 16 of file stopwatch.h.
Referenced by stopwatch_init(), and stopwatch_reset().
#define DWT_CYCCNT ((volatile uint32_t *)0xE0001004) |
Definition at line 18 of file stopwatch.h.
Referenced by stopwatch_reset().
void stopwatch_delay_us | ( | uint32_t | us | ) |
|
inlinestatic |
Definition at line 33 of file stopwatch.h.
Referenced by F4Light::Scheduler::_delay_us_ny(), Soft_I2C::bus_reset(), dispatch_adv_brk(), dispatch_adv_cc(), dispatch_adv_trg_com(), dispatch_adv_up(), dispatch_general(), dispatch_general_h(), dispatch_handler(), exti_serv(), i2c_bus_reset(), stopwatch_delay_us(), Soft_I2C::tick(), usart_rx_irq(), and usart_tx_irq().
void stopwatch_init | ( | void | ) |
Definition at line 12 of file stopwatch.c.
Referenced by init().
|
inlinestatic |
Definition at line 24 of file stopwatch.h.
Referenced by stopwatch_init().
uint32_t us_ticks |
Definition at line 10 of file stopwatch.c.