Jump to content
Sign in to follow this  
jim

How to use the serial port?

Recommended Posts

I compile the kernel and use Linaro Ubuntu for pcDuino.I want to use the serial port to connect other device,but,I don't know how to disable the console output and shell process on the port(UART0).Please~

Share this post


Link to post
Share on other sites

If you just want to use one UART, you can use gpio0/gpio1 as UART.

In a script, we need to first configure them to be UART mode.
 
$echo 3 > /sys/devices/virtual/misc/gpio/mode/gpio0
$echo 3 > /sys/devices/virtual/misc/gpio/mode/gpio1

Then, we can output through  device /dev/ttyS1.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×