RTEMS
6.3
Toggle main menu visibility
Loading...
Searching...
No Matches
bsps
arm
raspberrypi
include
bsp
rpi-gpio.h
Go to the documentation of this file.
1
8
9
/*
10
* Copyright (c) 2015 Andre Marques <andre.lousa.marques at gmail.com>
11
*
12
* The license and distribution terms for this file may be
13
* found in the file LICENSE in this distribution or at
14
* http://www.rtems.org/license/LICENSE.
15
*/
16
17
#ifndef LIBBSP_ARM_RASPBERRYPI_RPI_GPIO_H
18
#define LIBBSP_ARM_RASPBERRYPI_RPI_GPIO_H
19
20
#include <
rtems.h
>
21
22
#ifdef __cplusplus
23
extern
"C"
{
24
#endif
/* __cplusplus */
25
29
#define RPI_DIGITAL_IN 0
30
#define RPI_DIGITAL_OUT 1
31
#define RPI_ALT_FUNC_0 4
32
#define RPI_ALT_FUNC_1 5
33
#define RPI_ALT_FUNC_2 6
34
#define RPI_ALT_FUNC_3 7
35
#define RPI_ALT_FUNC_4 3
36
#define RPI_ALT_FUNC_5 2
37
#define RPI_ALT_FUNC_MASK 7
38
46
extern
rtems_status_code
rpi_gpio_select_jtag
(
void
);
47
55
extern
rtems_status_code
rpi_gpio_select_spi
(
void
);
56
64
extern
rtems_status_code
rpi_gpio_select_i2c
(
void
);
65
66
#ifdef __cplusplus
67
}
68
#endif
/* __cplusplus */
69
70
#endif
/* LIBBSP_ARM_RASPBERRYPI_RPI_GPIO_H */
rtems_status_code
rtems_status_code
This enumeration provides status codes for directives of the Classic API.
Definition
status.h:85
rpi_gpio_select_spi
rtems_status_code rpi_gpio_select_spi(void)
Setups a SPI interface.
Definition
rpi-gpio.c:285
rpi_gpio_select_jtag
rtems_status_code rpi_gpio_select_jtag(void)
Setups a JTAG interface.
Definition
rpi-gpio.c:280
rpi_gpio_select_i2c
rtems_status_code rpi_gpio_select_i2c(void)
Setups a I2C interface.
Definition
rpi-gpio.c:290
rtems.h
This header file defines the RTEMS Classic API.
Generated by
1.18.0