Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cpu: added place for shared STM32 files
- Loading branch information
1 parent
436d8f6
commit f4587b3
Showing
4 changed files
with
57 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
DIRS = periph | ||
|
||
include $(RIOTBASE)/Makefile.base |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# export the CPU family so we can differentiate between them in the code | ||
FAM = $(shell echo $(CPU_FAM) | tr 'a-z-' 'A-Z_') | ||
export CFLAGS += -DCPU_FAM_$(FAM) | ||
|
||
# includ common periph module | ||
USEMODULE += periph_common | ||
|
||
# export the common include directory | ||
export INCLUDES += -I$(RIOTCPU)/stm32_common/include |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* Copyright (C) 2016 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. | ||
*/ | ||
|
||
/** | ||
* @ingroup cpu_stm32_common | ||
* @{ | ||
* | ||
* @file | ||
* @brief Shared CPU specific definitions for the STM32 family | ||
* | ||
* @author Hauke Petersen <hauke.peterse@fu-berlin.de> | ||
*/ | ||
|
||
#ifndef PERIPH_CPU_COMMON_H | ||
#define PERIPH_CPU_COMMON_H | ||
|
||
#include "cpu.h" | ||
|
||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
/** | ||
* @brief Use the shared SPI functions | ||
* @{ | ||
*/ | ||
#define PERIPH_SPI_NEEDS_TRANSFER_BYTES | ||
#define PERIPH_SPI_NEEDS_TRANSFER_REG | ||
#define PERIPH_SPI_NEEDS_TRANSFER_REGS | ||
/** @} */ | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif | ||
|
||
#endif /* PERIPH_CPU_COMMON_H */ | ||
/** @} */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
MODULE = periph | ||
|
||
include $(RIOTBASE)/Makefile.base |