Serial Debugging Tool

Hi Gouwa,

I have received new USB to TTL Convertor with five pins: GND, RxD, TxD, 5.0V, 3.3V. But it doesn’t transfer any data.

Could you please renew the https://github.com/khadas/documents/blob/master/SetupSerialTool.md
with understandable pictures.

Best Regards,
Andrey K.

HI, Andrey:
Okay, we’ll do that soon, before we update the picture, following one take by my mobile phone for your reference:

BTW, we’ve move the documentation to Khadas website, take a check at Khadas Docs for more the latest documentations.

Hi Gouwa,

I see that the 3.3V VCC (pin20) doesn’t needed.

Is it right?

1 Like

Yes, 3.3V Pin is optional

If your problem is solved, please follow the guidance to mark it as solved.

Thanks!

Not yet.

I still cannot receive any output fro U-Boot. The green led on the USB-TTL adapter is blinking but neither minicom nor kermit can receive symbols.

Do we need to do some additional settings, for example, terminal settings in minicom?

I didn’t use minicom, and the Setup Serial Debugging Tool tutorial setup with c-kermit.

I think following things you might take a notice:

  • Exchange the Tx and Rx pins and have a try again
  • Check the USB access permission setup again:
  • Check the configuration with serial tools:

Kermit also doesn’t work with new USB-TTL converter.

I will test the connection later with another adapter at home tonight.

Which USB-TTL converter did you used? The one we used is PL2303 chipset solution and the driver is built-in Linux Distro. So you might need to install the driver on your PC first in the other case.

Hi Gouwa,

That instance of USB-TTL converter which I received doesn’t work. This is visible by kernel driver, minicom, and kermit but doesn’t transfer data. Probably this error related to 3.3V (pin 20) connection.
When you will edit documentation please double check do we need the pin20.

I think 3.3V pin should be disconnected to avoid problems.

I have taken other converter and can say that kermit and minicom work properly.

Thank you.

Best Regards,
Andrey K.

It works here with the 3.3V pin connecting. (I’ve also try with other USB-TTL chipset modules, also work fine)

I just wonder whether it related to different USB-TTL modules.

Could you please post the output of dmesg when you plug in the USB-TTL converter on the PC side.

Here a kernel with usbserial support but without pl2303 support:
- No tty will be attached:

#dmesg
[670693.025588] usb 3-1.3: new full-speed USB device number 7 using usb20_host
[670693.126332] usb 3-1.3: New USB device found, idVendor=067b, idProduct=2303
[670693.126465] usb 3-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[670693.126563] usb 3-1.3: Product: USB-Serial Controller
[670693.126654] usb 3-1.3: Manufacturer: Prolific Technology Inc.

Here a kernel with usbserial support: (works out of the box on Raspberry Pi)
- here ttyUSB0 is attached:

[ 1861.683813] usb 1-1.4: new full-speed USB device number 16 using dwc_otg
[ 1861.785944] usb 1-1.4: New USB device found, idVendor=067b, idProduct=2303
[ 1861.785968] usb 1-1.4: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[ 1861.785985] usb 1-1.4: Product: USB-Serial Controller
[ 1861.786004] usb 1-1.4: Manufacturer: Prolific Technology Inc.
[ 1861.789326] pl2303 1-1.4:1.0: pl2303 converter detected
[ 1861.793521] usb 1-1.4: pl2303 converter now attached to ttyUSB0

You can use the minicom program for serial communication:
sudo apt-get install minicom

Start minicom on ttyUSB0:

$sudo minicom -b 115200 -o -D /dev/ttyUSB0

I am using a converter from adafruit. It works just fine without just tx, rx, and gnd connected.

1 Like

@Gouwa: For me it was not sufficient to execute: $ sudo usermod -a -G dialout myusername to enable access. Rather I needed to execute $ sudo chmod 777 /dev/ttyUSB0 before. Maybe you could add this information to the ‘Setup Serial Debugging Tool’-Doc

I think it depends on the Linux/Ubuntu version you install, which version you installed?

@Gouwa

which version you installed? I ran a mint (don’t ask me which version, it is relatively old 2 years, I can check when I am at home) from USB-stick.

Yep, old Ubuntu (like 12.04) also use the same way to add the permission, but most latest Linux distro manage with the new way.

Anyway, thanks for feedback!

Good day!

chmod 777 /dev/ttyUSB0 - is not a UNIX way !!! Only Windows users can do that.

You have to do following:
$ sudo usermod -a -G uucp username
$ sudo usermod -a -G dialout username

Also you may need:

$ sudo chmod a+w /var/lock

or include the user into group which has pernissions for /var/lock directory.

(also please look at option -s of minicom utility)

$ minicom /dev/ttyUSB0

1 Like

Hi, Andrey:
Too long time haven’t seen you, miss you soooo much :blush:

1 Like