I've been trying to connect my hifive unleahed using usb

I tried connect my hifive unleashed with my PC using usb to figure out IP.
So I typed sudo screen /dev/serial/by-path/*-port0 115200 in my ubuntu terminal.
but i can’t get anything about login prompt except black screen.
Could you help what i have to do.
By the way I am using ubuntu 18.04.1 LTS
Plz help me, i’m in real trouble
thank you

The board provides two serial ports. One is the serial console, and the other is for JTAG. The exact numbering may depend on what you are connecting with, so if the first serial port does not work as a console, try the second one. Normally, one would use /dev/ttyUSB0 or /dev/ttyUSB1. I need to use /dev/ttyUSB1 on my primary machine.

By using “sudo screen /dev/serial/by-path/*-port0 115200” you are actually passing two serial ports to screen. Perhaps that is why it doesn’t work. I use minicom personally, so I’m not sure how screen works in this case.

1 Like

Hi Jim, Thank you for your kind answer. it’s really appreciate. However it doesn’t work for me. :disappointed_relieved: I tried to find ttyUSB0 but i can’t find this directory. and I typed other instruction many time. However result are same, i can’t get anything about login prompt. Have a nice day Jim.

You have to power on the board before /dev/ttyUSB0 or /dev/ttyUSB1 will exist. Unfortunately that means you might miss some boot up messages, but after you are able to connect to the tty, you can then power cycle the board if necessary to see the boot up messages. Try both ttys, as the first one you try might be the jtag port. I have Ubuntu 18.04 on my machine. I don’t think any special package is necessary to make this work. There are the usual issues with serial ports, get the speed right, and you might try disabling hardware/software flow control.

1 Like

Thanks to your kind answers, I have a progression in my connecting hifive unleashed. But… still have som problem. I typed sudo screen /dev/ttyUSB0 and It works. However, It dosen’t seem like login prompt. I can’t understand what terminal says. So I added screenshot. Could you help one more time?? You are the only savior I ever met.

Did you try /dev/ttyUSB1? You might be connected to the wrong port. Otherwise, I don’t know much about screen. I use minicom. I tried using screen, and it does appear to work. I did see some gibberish on the screen when I first tried screen, but I don’t know how I managed to do that. I only see console output now.

I am pretty sure this means that you have the wrong baud/speed setting. For example, if I connect with 9600 then I see

2C�B�BB!�BB�BB�"BB�BN:B BB�"B�B�B^�BBNrB^B!B!B!�

You can check the current speed, for example, like so:

stty -F /dev/ttyUSB1 speed

BTW, you must connect with 115200, I think!

Hi,
You need to set the baud rate to 115200 with 8-data bits, No parity bit and 1 stop bit.
I use minicom, “sudo minicom -D /dev/ttyUSB1 -b 115200 -8”

Hi ,

Please check the UART connection .are you connected properly in that header pins check. Please connect tx to rx and rx to tx connect ground also. Using dev/ttyUSB1 it can be vary also check your device identity which one is identified based on you can connect.

Regards,
Sateesh