cpu/stm32f1/include/cpu_conf.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2013 INRIA
3  * Copyright (C) 2014 Freie Universit├Ąt Berlin
4  *
5  * This file is subject to the terms and conditions of the GNU Lesser General
6  * Public License v2.1. See the file LICENSE in the top level directory for more
7  * details.
8  */
9 
23 #ifndef CPU_CONF_H
24 #define CPU_CONF_H
25 
26 #include "cpu_conf_common.h"
27 
28 #if defined(CPU_MODEL_STM32F103CB) || defined(CPU_MODEL_STM32F103RB)
29 #include "vendor/stm32f103xb.h"
30 #elif defined(CPU_MODEL_STM32F103RE)
31 #include "vendor/stm32f103xe.h"
32 #endif
33 
34 #ifdef __cplusplus
35 extern "C" {
36 #endif
37 
42 #define CPU_DEFAULT_IRQ_PRIO (1U)
43 #if defined(CPU_MODEL_STM32F103RE)
44 #define CPU_IRQ_NUMOF (60U)
45 #else
46 #define CPU_IRQ_NUMOF (43U)
47 #endif
48 #define CPU_FLASH_BASE FLASH_BASE
49 
55 #define FLASHPAGE_SIZE (2048U)
56 
57 #if defined(CPU_MODEL_STM32F103C8)
58 #define FLASHPAGE_NUMOF (32U)
59 #elif defined(CPU_MODEL_STM32F103CB) || defined(CPU_MODEL_STM32F103RB)
60 #define FLASHPAGE_NUMOF (64U)
61 #elif defined(CPU_MODEL_STM32F103RE)
62 #define FLASHPAGE_NUMOF (256U)
63 #endif
64 
66 #ifdef __cplusplus
67 }
68 #endif
69 
70 #endif /* CPU_CONF_H */
71 
Common CPU definitione for Cortex-M family based MCUs.