libopencm3
A free/libre/open-source firmware library for various ARM Cortex-M3 microcontrollers.
|
Defined Constants and Types for the NRF52xx Timer More...
Modules | |
TIMER instances | |
Timer event -> task shortcuts | |
Macros | |
#define | TIMER_TASK_START(T) MMIO32((T) + 0x000) |
#define | TIMER_TASK_STOP(T) MMIO32((T) + 0x004) |
#define | TIMER_TASK_COUNT(T) MMIO32((T) + 0x008) |
#define | TIMER_TASK_CLEAR(T) MMIO32((T) + 0x00C) |
#define | TIMER_TASK_SHUTDOWN(T) MMIO32((T) + 0x010) |
#define | TIMER_TASK_CAPTURE(T, C) MMIO32((T) + 0x040 + (uint32_t)(0x4 * (C))) |
#define | TIMER_EVENT_COMPARE(T, C) MMIO32((T) + 0x140 + (uint32_t)(0x4 * (C))) |
#define | TIMER_SHORTS(T) _PERIPH_SHORTS(T) |
#define | TIMER_INTENSET(T) _PERIPH_INTENSET(T) |
#define | TIMER_INTENCLR(T) _PERIPH_INTENCLR(T) |
#define | TIMER_MODE(T) MMIO32((T) + 0x504) |
#define | TIMER_BITMODE(T) MMIO32((T) + 0x508) |
#define | TIMER_PRESCALER(T) MMIO32((T) + 0x510) |
#define | TIMER_PRESCALER_MASK (0xf) |
#define | TIMER_CC(T, C) MMIO32((T) + 0x540 + 0x4 * (C)) |
#define | TIMER_INTEN_COMPARE(C) (1 << (16 + (C))) |
#define | TIMER_MODE_SELECT (1 << 0) |
Enumerations | |
enum | timer_mode { TIMER_MODE_TIMER , TIMER_MODE_COUNTER } |
enum | timer_bitmode { TIMER_BITMODE_16BIT , TIMER_BITMODE_08BIT , TIMER_BITMODE_24BIT , TIMER_BITMODE_32BIT } |
Defined Constants and Types for the NRF52xx Timer
LGPL License Terms libopencm3 License
#define TIMER_BITMODE | ( | T | ) | MMIO32((T) + 0x508) |
Definition at line 68 of file common/timer.h.
#define TIMER_CC | ( | T, | |
C | |||
) | MMIO32((T) + 0x540 + 0x4 * (C)) |
Definition at line 72 of file common/timer.h.
#define TIMER_EVENT_COMPARE | ( | T, | |
C | |||
) | MMIO32((T) + 0x140 + (uint32_t)(0x4 * (C))) |
Definition at line 60 of file common/timer.h.
#define TIMER_INTEN_COMPARE | ( | C | ) | (1 << (16 + (C))) |
Definition at line 87 of file common/timer.h.
#define TIMER_INTENCLR | ( | T | ) | _PERIPH_INTENCLR(T) |
Definition at line 66 of file common/timer.h.
#define TIMER_INTENSET | ( | T | ) | _PERIPH_INTENSET(T) |
Definition at line 65 of file common/timer.h.
#define TIMER_MODE | ( | T | ) | MMIO32((T) + 0x504) |
Definition at line 67 of file common/timer.h.
#define TIMER_MODE_SELECT (1 << 0) |
Definition at line 89 of file common/timer.h.
#define TIMER_PRESCALER | ( | T | ) | MMIO32((T) + 0x510) |
Definition at line 69 of file common/timer.h.
#define TIMER_PRESCALER_MASK (0xf) |
Definition at line 70 of file common/timer.h.
#define TIMER_SHORTS | ( | T | ) | _PERIPH_SHORTS(T) |
Definition at line 64 of file common/timer.h.
#define TIMER_TASK_CAPTURE | ( | T, | |
C | |||
) | MMIO32((T) + 0x040 + (uint32_t)(0x4 * (C))) |
Definition at line 53 of file common/timer.h.
#define TIMER_TASK_CLEAR | ( | T | ) | MMIO32((T) + 0x00C) |
Definition at line 51 of file common/timer.h.
#define TIMER_TASK_COUNT | ( | T | ) | MMIO32((T) + 0x008) |
Definition at line 50 of file common/timer.h.
#define TIMER_TASK_SHUTDOWN | ( | T | ) | MMIO32((T) + 0x010) |
Definition at line 52 of file common/timer.h.
#define TIMER_TASK_START | ( | T | ) | MMIO32((T) + 0x000) |
Definition at line 48 of file common/timer.h.
#define TIMER_TASK_STOP | ( | T | ) | MMIO32((T) + 0x004) |
Definition at line 49 of file common/timer.h.
enum timer_bitmode |
Enumerator | |
---|---|
TIMER_BITMODE_16BIT | |
TIMER_BITMODE_08BIT | |
TIMER_BITMODE_24BIT | |
TIMER_BITMODE_32BIT |
Definition at line 96 of file common/timer.h.
enum timer_mode |
Enumerator | |
---|---|
TIMER_MODE_TIMER | |
TIMER_MODE_COUNTER |
Definition at line 91 of file common/timer.h.