cpu/sam0_common/include/cpu_conf.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2014-2016 Freie Universit├Ąt Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
20 #ifndef CPU_CONF_H
21 #define CPU_CONF_H
22 
23 #include "cpu_conf_common.h"
24 #include "vendor/sam0.h"
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
34 #define CPU_DEFAULT_IRQ_PRIO (1U)
35 #define CPU_IRQ_NUMOF PERIPH_COUNT_IRQn
36 #define CPU_FLASH_BASE FLASH_ADDR
37 
43 /* a flashpage in RIOT is mapped to a flash row on the SAM0s */
44 #define FLASHPAGE_SIZE (256U)
45 /* one SAM0 row contains 4 SAM0 pages -> 4x the amount of RIOT flashpages */
46 #define FLASHPAGE_NUMOF (FLASH_NB_OF_PAGES / 4)
47 
49 #ifdef __cplusplus
50 }
51 #endif
52 
53 #endif /* CPU_CONF_H */
54 
Common CPU definitione for Cortex-M family based MCUs.