please choosego to mobile | Continue to access the PC version
12
Return to list Post new posts
Author: ivan_ucherdjiev

UART1,2,3c

[Copy link]

6

threads

24

posts

118

credits

Registered member

Rank: 2

credits
118
Published in 2015-11-1 12:59:41 | Show all floors
Edited by 3Point14 at 2015-11-1 14:31

Glad I didn't see any of this before my UART cable came in the mail today. Maybe you guys are trying to do something different than what I was trying to do. I wanted a UART terminal and to see boot messages. I did try to connect the UART cable the same way to the same pins as the Rpi and it didn't work. Then I found a note that the Opi has more serial pins than the Rpi.


http://linux-sunxi.org/UART

There are dedicated UART pins on the Orange Pi PC. They are the three pins by the power supply. From the power supply, plug in Black, Green & White. Leave red alone. Open s serial terminal (I used Droid Term from my tablet). I've been having the time of my life.

I installed the preconfigured Lubuntu and made no changes to enable UART.

3

threads

31

posts

139

credits

Registered member

Rank: 2

credits
139
 Author| Published in 2016-3-19 14:23:33 | Show all floors
Edited by ivan_ucherdjiev at 2016-3-19 14:30
3Point14 replied at 2015-11-1 12:59
Glad I didn't see any of this before my UART cable came in the mail today. Maybe you guys are trying ...

Yes , you are right there are specified UART for debug. The topic here is how to use the other 3 UARTS, which are on the 40 pin header, for aplications not for debugging and system messages. Thats why the topic is named UART1,2,3 .... this are the UARTs on the 40 pin header of the OPI. The debugging UART is UART0 and it have his own pins, next to the power supply, separated from the 40 pin header.

Best regards,
Ivan

0

threads

2

posts

14

credits

Novice

Rank: 1

credits
14
Published in 2016-5-16 16:16:24 | Show all floors
Hello!

I need to enable UARTs for Orangepi PC. For this I'm trying to do following  instructions which are written above in this topic:
fex2bin .out/sys_config.fex out/sys_config.bin
but I have an error:
E: ./sdk/out/sys_config.fex:314: invalid character at 17.
in the file I have:
;SPI device configuration
;----------------------------------------------------------------------------------
[spi_devices]
spi_dev_num = 1

[spi_board0]
modalias      = m25p32  
max_speed_hz  = 33000000d
bus_num       = 0
chip_select   = 0
mode          = 0

where
"modalias      = m25p32"  is line number 314

If I try do
"./sdk/lichee/tools/pack/pctools/linux/mod_update/update_uboot ./sdk/out/u-boot.fex ./sdk/out/sys_config.bin " after this I get following error:

uboot file Path=//./sdk/out/u-boot.fex
script file Path=//./sdk/out/sys_config.bin

*** Error in `./sdk/lichee/tools/pack/pctools/linux/mod_update/update_uboot': free(): invalid next size (fast): 0x0000000001ecf730 ***
Aborted (core dumped)

Could anybody help me to build u-boot with enabled UARTs for Orangepi PC?

Best regards,
  Oleg

0

threads

2

posts

14

credits

Novice

Rank: 1

credits
14
Published in 2016-5-17 21:11:52 | Show all floors
oleg.wr replied at 2016-5-16 12:16
Hello!

I need to enable UARTs for Orangepi PC. For this I'm trying to do following  instructions wh ...

OK, I've read the source code of fex2bin and had changed the config file agree with the source code.


3

threads

10

posts

111

credits

Registered member

Rank: 2

credits
111
Published in 2016-6-21 23:33:27 | Show all floors
review you fex if you really need all pins, maybe they just work whit Tx/Rx only


[uart0]
uart_used       = 1
uart_port       = 0
uart_type       = 2
uart_tx         = portA04<2><1><default><default>
uart_rx         = portA05<2><1><default><default>


[uart1]
uart_used       = 1
uart_port       = 1
uart_type       = 2
uart_tx         = portG06<2><1><default><default>
uart_rx         = portG07<2><1><default><default>

[uart2]
uart_used       = 1
uart_port       = 2
uart_type       = 2
uart_tx         = portA13<2><1><default><default>
uart_rx         = portA14<2><1><default><default>


[uart3]
uart_used       = 1
uart_port       = 3
uart_type       = 2
uart_tx         = portA02<2><1><default><default>
uart_rx         = portA01<2><1><default><default>

[uart4]
uart_used       = 1
uart_port       = 4
uart_type       = 2
uart_tx         = portA00<2><1><default><default>
uart_rx         = portA01<2><1><default><default>

then remember to set speed and specs with stty -F /dev/ttyS? speed (i.e. 9600)

my only problem is each serial works fine individually but I can't make them work together (all at the same time with different devices, like GPS or sensors)

Regards
12
Return to list Post new posts
You need to log in before you can reply login | Register

Points Rule

Quick reply Top Return list