board_modules.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: 2018 Gunar Schorcht
3  * SPDX-License-Identifier: LGPL-2.1-only
4  */
5 
6 #pragma once
7 
28 #include <stdint.h>
29 
30 #ifdef __cplusplus
31 extern "C" {
32 #endif
33 
34 #if defined(MODULE_ENC28J60) || defined(DOXYGEN)
49 #define ENC28J60_PARAM_SPI SPI_DEV(0)
51 #ifndef ENC28J60_PARAM_CS
52 #define ENC28J60_PARAM_CS GPIO4
53 #endif
54 #ifndef ENC28J60_PARAM_INT
55 #define ENC28J60_PARAM_INT GPIO9
56 #endif
57 #ifndef ENC28J60_PARAM_RESET
58 #define ENC28J60_PARAM_RESET GPIO10
59 #endif
61 #endif /* defined(MODULE_ENC28J60) || defined(DOXYGEN) */
62 
63 #if defined(MODULE_MRF24J40) || defined(DOXYGEN)
77 #define MRF24J40_PARAM_SPI SPI_DEV(0)
79 #ifndef MRF24J40_PARAM_SPI_CLK
80 #define MRF24J40_PARAM_SPI_CLK SPI_CLK_1MHZ
81 #endif
82 #ifndef MRF24J40_PARAM_CS
83 #define MRF24J40_PARAM_CS GPIO16
84 #endif
85 #ifndef MRF24J40_PARAM_INT
86 #define MRF24J40_PARAM_INT GPIO0
87 #endif
88 #ifndef MRF24J40_PARAM_RESET
89 #define MRF24J40_PARAM_RESET GPIO2
90 #endif
92 #endif /* defined(MODULE_MRF24J40) || defined(DOXYGEN) */
93 
94 #if defined(MODULE_SDCARD_SPI) || defined(DOXYGEN)
108 #define SDCARD_SPI_PARAM_SPI SPI_DEV(0)
109 #define SDCARD_SPI_PARAM_CLK SPI0_SCK
110 #define SDCARD_SPI_PARAM_MOSI SPI0_MOSI
111 #define SDCARD_SPI_PARAM_MISO SPI0_MISO
112 #define SDCARD_SPI_PARAM_POWER GPIO_UNDEF
114 #ifndef SDCARD_SPI_PARAM_CS
115 #define SDCARD_SPI_PARAM_CS SPI0_CS0
116 #endif
118 #endif /* defined(MODULE_SDCARD_SPI) || defined(DOXYGEN) */
119 
120 #ifdef __cplusplus
121 } /* end extern "C" */
122 #endif
123