RTEMS 7.0-rc1
Loading...
Searching...
No Matches
spi.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: GPL-2.0+-with-RTEMS-exception */
2
11/*
12 * Copyright (c) 2014-2015 Andre Marques <andre.lousa.marques at gmail.com>
13 *
14 * The license and distribution terms for this file may be
15 * found in the file LICENSE in this distribution or at
16 * http://www.rtems.org/license/LICENSE.
17 */
18
19#ifndef LIBBSP_ARM_RASPBERRYPI_SPI_H
20#define LIBBSP_ARM_RASPBERRYPI_SPI_H
21
22#include <rtems/libi2c.h>
23
24#ifdef __cplusplus
25extern "C" {
26#endif /* __cplusplus */
27
41/* TODO: It would be nice if this value could be probed at startup, probably
42 * using the Mailbox interface since the usual way of setting this on
43 * the hardware is through a "config.txt" text file on the SD card.
44 * Having this setup on the configure.ac script would require changing
45 * the same setting on two different places. */
46#define GPU_CORE_CLOCK_RATE 250000000
47
71extern int rpi_spi_init(bool bidirectional_mode);
72
75#ifdef __cplusplus
76}
77#endif /* __cplusplus */
78
79#endif /* LIBBSP_ARM_RASPBERRYPI_SPI_H */
int rpi_spi_init(bool bidirectional_mode)
Setups the Raspberry Pi SPI bus (located on the GPIO header) on the "/dev/spi" device file,...
Definition: spi.c:646
Legacy I2C Library.