cfg_spi_default.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2016-2018 Freie Universität Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
9 #pragma once
10 
22 #include "periph_cpu.h"
23 
24 #ifdef __cplusplus
25 extern "C" {
26 #endif
27 
32 static const spi_conf_t spi_config[] = {
33  {
34  .dev = NRF_SPIM0,
35  .sclk = GPIO_PIN(0, 15),
36  .mosi = GPIO_PIN(0, 13),
37  .miso = GPIO_PIN(0, 14),
38 #ifdef ERRATA_SPI_SINGLE_BYTE_WORKAROUND
39  .ppi = 0,
40 #endif
41  }
42 };
43 
44 #define SPI_NUMOF ARRAY_SIZE(spi_config)
47 #ifdef __cplusplus
48 }
49 #endif
50 
#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