2014-06-24 23:36:38 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2014 Freie Universität Berlin
|
|
|
|
*
|
|
|
|
* This file is subject to the terms and conditions of the GNU Lesser General
|
|
|
|
* Public License v2.1. See the file LICENSE in the top level directory for more
|
|
|
|
* details.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @defgroup cpu_stm32f3 STM32F3
|
|
|
|
* @ingroup cpu
|
|
|
|
* @brief CPU specific implementations for the STM32F3
|
|
|
|
* @{
|
|
|
|
*
|
|
|
|
* @file
|
|
|
|
* @brief Implementation specific CPU configuration options
|
|
|
|
*
|
|
|
|
* @author Hauke Petersen <hauke.petersen@fu-berlin.de>
|
2015-04-23 13:39:06 +02:00
|
|
|
* @author Katja Kirstein <katja.kirstein@haw-hamburg.de>
|
2014-06-24 23:36:38 +02:00
|
|
|
*/
|
|
|
|
|
2017-05-23 18:19:52 +02:00
|
|
|
#ifndef CPU_CONF_H
|
|
|
|
#define CPU_CONF_H
|
2014-06-24 23:36:38 +02:00
|
|
|
|
2016-01-14 23:21:49 +01:00
|
|
|
#include "cpu_conf_common.h"
|
|
|
|
|
2018-06-19 11:49:11 +02:00
|
|
|
#include "vendor/stm32f3xx.h"
|
|
|
|
|
2015-05-27 23:07:57 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
2014-06-24 23:36:38 +02:00
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
2015-05-27 23:07:57 +02:00
|
|
|
* @brief ARM Cortex-M specific CPU configuration
|
2014-06-24 23:36:38 +02:00
|
|
|
* @{
|
|
|
|
*/
|
2015-05-27 23:07:57 +02:00
|
|
|
#define CPU_DEFAULT_IRQ_PRIO (1U)
|
2018-06-19 11:49:11 +02:00
|
|
|
#if defined(CPU_LINE_STM32F303xE)
|
2017-08-20 13:57:32 +02:00
|
|
|
#define CPU_IRQ_NUMOF (85U)
|
|
|
|
#else
|
2015-05-27 23:07:57 +02:00
|
|
|
#define CPU_IRQ_NUMOF (82U)
|
2017-08-20 13:57:32 +02:00
|
|
|
#endif
|
2015-05-27 23:07:57 +02:00
|
|
|
#define CPU_FLASH_BASE FLASH_BASE
|
2014-06-24 23:36:38 +02:00
|
|
|
/** @} */
|
|
|
|
|
2019-06-25 13:52:24 +02:00
|
|
|
/**
|
|
|
|
* @name Flash page configuration
|
|
|
|
* @{
|
|
|
|
*/
|
|
|
|
#define FLASHPAGE_SIZE (2048U)
|
|
|
|
#define FLASHPAGE_NUMOF (STM32_FLASHSIZE / FLASHPAGE_SIZE)
|
|
|
|
|
|
|
|
/* The minimum block size which can be written is 2B. However, the erase
|
|
|
|
* block is always FLASHPAGE_SIZE.
|
|
|
|
*/
|
|
|
|
#define FLASHPAGE_RAW_BLOCKSIZE (2U)
|
|
|
|
/* Writing should be always 4 bytes aligned */
|
|
|
|
#define FLASHPAGE_RAW_ALIGNMENT (4U)
|
|
|
|
/** @} */
|
2014-10-13 10:53:20 +02:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2017-05-23 18:19:52 +02:00
|
|
|
#endif /* CPU_CONF_H */
|
2014-06-24 23:36:38 +02:00
|
|
|
/** @} */
|