cfg_spi_default.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: 2016-2018 Freie Universität Berlin
3  * SPDX-License-Identifier: LGPL-2.1-only
4  */
5 
6 #pragma once
7 
19 #include "periph_cpu.h"
20 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
29 static const spi_conf_t spi_config[] = {
30  {
31  .dev = NRF_SPIM0,
32  .sclk = GPIO_PIN(0, 15),
33  .mosi = GPIO_PIN(0, 13),
34  .miso = GPIO_PIN(0, 14),
35 #ifdef ERRATA_SPI_SINGLE_BYTE_WORKAROUND
36  .ppi = 0,
37 #endif
38  }
39 };
40 
41 #define SPI_NUMOF ARRAY_SIZE(spi_config)
44 #ifdef __cplusplus
45 }
46 #endif
47 
#define GPIO_PIN(x, y)
Define a CPU specific GPIO pin generator macro.
Definition: periph_cpu.h:45
static const spi_conf_t spi_config[]
Default SPI device configuration.
SPI device configuration.
Definition: periph_cpu.h:336
SPI_t * dev
pointer to the used SPI device
Definition: periph_cpu.h:337