CPU specific definitions for internal peripheral handling. More...
CPU specific definitions for internal peripheral handling.
CPU specific definitions for internal peripheral handling
Definition in file periph_cpu.h.
#include <limits.h>#include "periph_cpu_common.h"
Include dependency graph for periph_cpu.h:Go to the source code of this file.
Data Structures | |
| struct | sam0_aux_cfg_mapping |
| NVM User Row Mapping - Dedicated Entries Config values will be applied at power-on. More... | |
Macros | |
| #define | PM_BLOCKER_INITIAL 0x00000001 |
| Override the default initial PM blocker. More... | |
| #define | SPI_HWCS(x) (UINT_MAX - 1) |
| Override SPI hardware chip select macro. More... | |
| #define | DAC_RES_BITS (10) |
| The MCU has a 10 bit DAC. | |
| #define | DAC_NUMOF (1) |
| The MCU has one DAC Output. | |
Functions | |
| static int | _sercom_id (SercomUsart *sercom) |
| Return the numeric id of a SERCOM device derived from its address. More... | |
Power mode configuration | |
| #define | PM_NUM_MODES (3) |
SAMD21 sleep modes for PM | |
| #define | SAMD21_PM_STANDBY (0U) |
| Standby mode (stops main clock) | |
| #define | SAMD21_PM_IDLE_2 (1U) |
| Idle 2 (stops AHB, APB and CPU) | |
| #define | SAMD21_PM_IDLE_1 (2U) |
| Idle 1 (stops AHB and CPU) | |
| #define | SAMD21_PM_IDLE_0 (3U) |
| Idle 0 (stops CPU) | |
SAMD21 GCLK definitions | |
| enum | { SAM0_GCLK_MAIN = 0, SAM0_GCLK_1MHZ, SAM0_GCLK_32KHZ, SAM0_GCLK_1KHZ, SAM0_GCLK_DISABLED = 0xF } |
| #define PM_BLOCKER_INITIAL 0x00000001 |
Override the default initial PM blocker.
Definition at line 42 of file periph_cpu.h.
| #define SPI_HWCS | ( | x | ) | (UINT_MAX - 1) |
Override SPI hardware chip select macro.
As of now, we do not support HW CS, so we always set it to a fixed value
Definition at line 72 of file periph_cpu.h.
| anonymous enum |
| Enumerator | |
|---|---|
| SAM0_GCLK_MAIN | 48 MHz main clock |
| SAM0_GCLK_1MHZ | 1 MHz clock for xTimer |
| SAM0_GCLK_32KHZ | 32 kHz clock |
| SAM0_GCLK_1KHZ | 1 kHz clock |
| SAM0_GCLK_DISABLED | disabled GCLK |
Definition at line 58 of file periph_cpu.h.
|
inlinestatic |
Return the numeric id of a SERCOM device derived from its address.
| [in] | sercom | SERCOM device |
Definition at line 81 of file periph_cpu.h.