Skip to content

Commit 0a8dc5b

Browse files
pabigotnashif
authored andcommitted
boards: hifive1_revb: add arduino gpio nexus map
Provide the mapping from FE310-G002 GPIO pins to the Arduino Uno headers. Note where pins have pre-assigned functions that may interfere with use as GPIOs with the default pinmux assignments. Signed-off-by: Peter A. Bigot <[email protected]>
1 parent 3805290 commit 0a8dc5b

File tree

2 files changed

+32
-0
lines changed

2 files changed

+32
-0
lines changed

boards/riscv/hifive1_revb/hifive1_revb.dts

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,35 @@
3636
label = "Red LED";
3737
};
3838
};
39+
40+
arduino_header: connector {
41+
compatible = "arduino-header-r3";
42+
#gpio-cells = <2>;
43+
gpio-map-mask = <0xffffffff 0xffffffc0>;
44+
gpio-map-pass-thru = <0 0x3f>;
45+
gpio-map = /* A0 not connected */
46+
<1 0 &gpio0 9 0>, /* A1, also CS2 */
47+
<2 0 &gpio0 10 0>, /* A2, also WF_INT */
48+
<3 0 &gpio0 11 0>, /* A3 */
49+
<4 0 &gpio0 12 0>, /* A4 */
50+
<5 0 &gpio0 13 0>, /* A5 */
51+
<6 0 &gpio0 16 0>, /* D0, also TX */
52+
<7 0 &gpio0 17 0>, /* D1, also RX */
53+
<8 0 &gpio0 18 0>, /* D2 */
54+
<9 0 &gpio0 19 0>, /* D3 */
55+
<10 0 &gpio0 20 0>, /* D4 */
56+
<11 0 &gpio0 21 0>, /* D5 */
57+
<12 0 &gpio0 22 0>, /* D6 */
58+
<13 0 &gpio0 23 0>, /* D7 */
59+
<14 0 &gpio0 0 0>, /* D8 */
60+
<15 0 &gpio0 1 0>, /* D9 */
61+
<16 0 &gpio0 2 0>, /* D10 */
62+
<17 0 &gpio0 3 0>, /* D11, also MOSI */
63+
<18 0 &gpio0 4 0>, /* D12, also MISO */
64+
<19 0 &gpio0 5 0>, /* D13, also SCK */
65+
<20 0 &gpio0 12 0>, /* D14, also SDA */
66+
<21 0 &gpio0 13 0>; /* D15, also SCL */
67+
};
3968
};
4069

4170
&gpio0 {

boards/riscv/hifive1_revb/hifive1_revb.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,6 @@ testing:
99
ignore_tags:
1010
- net
1111
- bluetooth
12+
supported:
13+
- arduino_gpio
14+
- gpio

0 commit comments

Comments
 (0)