Skip to content

Commit 96a4ca7

Browse files
rpi: add uart device_path
Currently there is no device_path registered for UART in Raspberry Pi source. This will hinder the working of UART driver in mraa. So, register the device_path with '/dev/serial0' as most of the raspbian images make this as a soft link to _real_ UART port by default. Tested-on: Raspberry pi 3 model B Signed-off-by: Manivannan Sadhasivam <[email protected]>
1 parent 02963b7 commit 96a4ca7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/arm/raspberry_pi.c

+1
Original file line numberDiff line numberDiff line change
@@ -834,6 +834,7 @@ mraa_raspberry_pi()
834834
b->def_uart_dev = 0;
835835
b->uart_dev[0].rx = 10;
836836
b->uart_dev[0].tx = 8;
837+
b->uart_dev[0].device_path = "/dev/serial0";
837838

838839
if ((platform_detected == PLATFORM_RASPBERRY_PI_A_PLUS_REV_1) ||
839840
(platform_detected == PLATFORM_RASPBERRY_PI_B_PLUS_REV_1) ||

0 commit comments

Comments
 (0)