5
Last change
on this file since 8f550d2 was
8f550d2,
checked in by Sichen Zhao <1473996754@…>, on 06/14/17 at 14:53:44
|
Add the i2c driver for Beaglebone Black
Update ticket #2891 and my GSOC project
add c/src/lib/libbsp/arm/beagle/i2c/bbb-i2c.c
modify c/src/lib/libbsp/arm/beagle/include/i2c.h
modify c/src/lib/libbsp/arm/beagle/include/bbb-gpio.h
modify c/src/lib/libcpu/arm/shared/include/am335x.h
modify c/src/lib/libbsp/arm/beagle/Makefile.am
Now can read the EEPROM by i2c, the test application link is: https://github.com/hahchenchen/GSOC-test-application
|
-
Property mode set to
100644
|
File size:
915 bytes
|
Line | |
---|
1 | /** |
---|
2 | * @file |
---|
3 | * |
---|
4 | * @ingroup arm_beagle |
---|
5 | * |
---|
6 | * @brief BeagleBone Black BSP definitions. |
---|
7 | */ |
---|
8 | |
---|
9 | /** |
---|
10 | * Copyright (c) 2015 Ketul Shah <ketulshah1993 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_BEAGLE_BBB_GPIO_H |
---|
18 | #define LIBBSP_ARM_BEAGLE_BBB_GPIO_H |
---|
19 | |
---|
20 | #ifdef __cplusplus |
---|
21 | extern "C" { |
---|
22 | #endif /* __cplusplus */ |
---|
23 | |
---|
24 | /** |
---|
25 | * @brief BeagleBone Black GPIO functions. |
---|
26 | */ |
---|
27 | #define BBB_DIGITAL_IN 2 |
---|
28 | #define BBB_DIGITAL_OUT 1 |
---|
29 | |
---|
30 | /** |
---|
31 | * @brief BeagleBone Black GPIO pad configuration. |
---|
32 | */ |
---|
33 | #define BBB_PUDEN (1 << 3) |
---|
34 | #define BBB_PUDDIS ~BBB_PUDEN |
---|
35 | #define BBB_PU_EN (1 << 4) |
---|
36 | #define BBB_PD_EN ~BBB_PU_EN |
---|
37 | #define BBB_MUXMODE(X) (X & 0x7) |
---|
38 | #define BBB_RXACTIVE (1 << 5) |
---|
39 | #define BBB_SLEWCTRL (1 << 6) |
---|
40 | |
---|
41 | #ifdef __cplusplus |
---|
42 | } |
---|
43 | #endif /* __cplusplus */ |
---|
44 | |
---|
45 | #endif /* LIBBSP_ARM_BEAGLE_BBB_GPIO_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.