R3 console via uART no response

I decided to install the latest release to my R3 and opted for a fresh install. The serial console via the uART pins and USB adapter has worked well since purchase. Today it simply stopped. I am lost for a solution, or even a troubleshooting method. I use a CP2102 USB 2.0 to TTL Module Serial Converter. (one of these https://www.aliexpress.us/item/3256805964804901.html?gatewayAdapt=glo2usa4itemAdapt)
Connecting the 3 wires as usual (GND ↔ GND, TXD ↔ RXD, RXD ↔ TXD) Two LEDS on the adapter that seem to correspond to GND and RXD illuminate.

Weirdly and I haven’t previously noticed, when I power on the R3 the RXD light immediately goes out and only GND remains. This seems very odd. As soon as I power off the RXD light illuminates. The TXD light does not light up. I don’t know if this is new and indicative of failure or its always been like that.

I have checked the serial cabling, testing the condition of the three cables for conductivity. Removed and replugged them many times.

When I connect to the USB adapter port I get no response and it hangs my session and cannot quit it within the terminal. I use this command on a Raspberry Pi where the adapter is connected. screen -L /dev/ttyUSB0 115200 This has always worked without issue.

Has something failed on the R3 in the uART circuitry? Is the USB adapter now faulty?

But mainly how can I troubleshoot this?

The R3 install seems a bit broken right now. I was midway through putting the 24.10.0 version onto eMMC via the boot menu but it seems that fails as if I boot from eMMC it seems to be falling back to an old version or some recovery boot, as if I connect via a local 192.168.1.1 network I can see this evidence.

From dmesg I see:

 6.025730] Run /init as init process
[    6.029374]   with arguments:
[    6.032331]     /init
[    6.034588]   with environment:
[    6.037712]     HOME=/
[    6.040056]     TERM=linux
[    6.167090] init: Console is alive
[    6.170613] init: - watchdog -
[    6.176529] kmodloader: loading kernel modules from /etc/modules-boot.d/*
[    6.185523] mt7986a-pinctrl 1001f000.pinctrl: pin GPIO_4 already requested by 11280000.pcie; cannot claim for pinctrl_moore:420
[    6.197000] mt7986a-pinctrl 1001f000.pinctrl: pin-9 (pinctrl_moore:420) status -22
[    6.204552] gpio-keys: probe of gpio-keys failed with error -22

So says console is alive.

Also I see this output:

root@OpenWrt:~# cat /etc/openwrt_release 
DISTRIB_ID='OpenWrt'
DISTRIB_RELEASE='23.05.5'
DISTRIB_REVISION='r24106-10cc5fcd00'
DISTRIB_TARGET='mediatek/filogic'
DISTRIB_ARCH='aarch64_cortex-a53'
DISTRIB_DESCRIPTION='OpenWrt 23.05.5 r24106-10cc5fcd00'
DISTRIB_TAINTS=''
root@OpenWrt:~# cat /etc/openwrt_version 
r24106-10cc5fcd00

root@OpenWrt:~# df -hP
Filesystem                Size      Used Available Capacity Mounted on
tmpfs                   996.8M     18.7M    978.1M   2% /
tmpfs                   996.8M     60.0K    996.7M   0% /tmp
tmpfs                   512.0K         0    512.0K   0% /dev

root@OpenWrt:~# mount
tmpfs on / type tmpfs (rw,relatime)
proc on /proc type proc (rw,nosuid,nodev,noexec,noatime)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,noatime)
cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime)
tmpfs on /dev type tmpfs (rw,nosuid,noexec,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,nosuid,noexec,noatime,mode=600,ptmxmode=000)
debugfs on /sys/kernel/debug type debugfs (rw,noatime)
bpffs on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,noatime,mode=700)
pstore on /sys/fs/pstore type pstore (rw,noatime)

But my question now is getting the console and USB Serial connection to work as it previously did. Really appreciate aany assistance from you.

Many thanks

LvR.

As you checked polarity (rx-tx) and settings,I would replace the dupont cables first then try another adapter. Are you sure there is only 1 ttyUSB on your rpi and starting screen on the right one?

Thank you very much.

Yes there is only one ttyUSB0 device shown in /dev. There is no ttyS000 or ttyUSB1 or anything like that.

I even tried deleting the device ttyUSB0 file and then watch it be re-created when I attached the adapter. Created with same major/minor numbers, permissions, owner and so on.

With a multimeter I checked the resistance of all the cables. They all showed no measurable resistance so thought good. I did this by using the silver contact which is on one surface of the connector (as the multimeter probes are too big to fit inside the connector).

Nevertheless I will find some other cables, test and report back.

Thanks again.

LvR.

Linux should delete it on removal and recreated on plugging in. Make sure your user has permission for this device (on ubuntu the device is for group dialout,so just add your user to this group and relogin)

I am using screen as the root user (my own user returned permission denied). It all used to work.

The device I see in /dev is

# ls -l /dev |grep USB
crw-rw---- 1 root dialout 188,   0 Apr 21 20:05 ttyUSB0

As i said,add your user (here pi as example) to dialout group

adduser pi dialout

But possibly your adapter or cables are broken.

Thanks. I need to acquire some cables first to test. I have also ordered a new adapter.

As for adding a local user to the dial out group, I run screen as root and it has always worked so I don’t think adding my own user to the dial out group will help.

I will get back to this - very helpful - discussion when I have new cables and or new adapter.

LvR.

Btw. For mtk filogic chips the recommended uart adapter is ftdi. Cp2102 causes some issues with wifi frontends.

I do not see any 3.3v / 5v selection switch or jumper.

So what are the pullups of the tx and rx lines connected to? If they are pulling up to 5v you may have broken your uart input/output.

Use something with a 3.3v jumper or switch (or only 3.3v possible), preferably the ft232(rl). from ftdi.

Afair cp2102 were only 3v3…used many of them with bpi-r2 without issues,but they fail with r3/r4 in case of the wifi-frontends.

You can measure tx to gnd with multimeter to check the voltage (tx is pulled to gnd when transmitting data so without data transmission it has the maximum voltage).

Indeed I see some schematics that do not have pullups. Hopefully it is one of these and his uart is still ok.

To update. I have purchased new Dupont cables. They have made no difference. Just as the previous post, when the Usb adapter is connected there are two LEDS lit GND and RXD. As soon as power us apples to the R3 the RXD light goes out. There is no connectivity.

I am now ordering a new adapter. Will report.

Thank you.

I have now ordered a new adapter. Described as this: FTDI FT232RL USB UART TTL 5V 3V3 TO 4PIN DEBUG DUPONT JUMPER

But I see in the order page it says I’ selected 5V, not 3V3. Is it a risk that if I use this I will break the uART as it’s only meant to use 3V3? I recall during the order process it had a small selection option of5V or 3V3 and I left it at the default, which was 5V.

Am I better off cancelling and choosing the 3V3 one or am I safe?

I do not know exactly what you ordered, but if it has a voltage selection jumper, it should be ok to adjust the jumper.

I have now tested two new USB - UART TTL adapter cables.

The first one uses the CP2102 chip which I was advised in this forum may have issues with the wifi circuitry in the R3. However this adapter does not work. With the same USB connection to a Raspberry PI that runs screen -L /dev/ttyUSB0 115200 I get no connection at all. I have repeatedly checked the connections and polarity. Disconnecting and reconnecting with many combinations of powering on the R3, starting and stopping screen, and so on. No sign of any data from the connection.

The second device I purchased was a 232RL 3V3 FTDI based adapter. Recommended here as that chip is not known to have any issues with the R3. It too does not work. On a few occasions during power on, or connecting to the R3 UART pins the screen shows a few instances of random characters, for example “?x???<???8?x???” on one occasion the screen came to life producing pages and pages of similar output - as if the data from the console was being sent but incorrectly displayed. That only happened once and I have not been able to reproduce it. I don’t know what that might signify. This adapter has 4 Dupont connectors and testing with a meter determined one to be 5V above GND (so did not use it) and RXD being 2.5V and TXD 3.3V.

I have removed the R3 board from the box and examined it with nothing to report. It is also easier to ensure the pins are clearly attached. I have reversed polarity to check I’m correct, to no avail.

I am encouraged that the random string software characters once appeared on the screen, leading me to think there’s just a simple issue not right. But I don’t know what it is. I have adjusted the baud rate to screen from 115200 to 115000 and 9600 but not tried every option.

The only other info I can provide I believe is the following. With the R3 off the resistance between the uART pins are GND/TXD 100 ohms, GND/RXD 280 ohms, TXD/RXD 500 ohms. With the R3 powered on GND/TXD is 1.5V, GND/RXD 2.3V, TXD/RXD 1.5V

The FTDI 232RL adapter connected to the USB port has GND/TXD 3.3V, GND/RXD 2.5V.

The CP2102 adapter has measurements GND/TXD 3.2V, GND/RXD 1.9V

My original adapter, also a CP2102 chip (which worked on day one as soon as connected but stopped for no apparent reason) has measurements GND/RXD 2.5V, GND/TXD 3.3V

If you can provide any guidance for next steps to troubleshoot it would be much appreciated. Based on the above I think it is reasonable to assume the R3 is still ok.

Many thanks.

I understand you want to use ‘screen’ for your communication.

Did you try ‘minicom’ with the recommended settings, just to see if this works? Maybe the settings for handshake are not set correctly using ‘screen’.

Is there enough power available on your usb port? I saw gibberish sometimes and found there were to many devices on the usb-hub.

Are the dupond cables very long?

The 3.3v GPIO pins can only take -0.5 to +3.8V, so it is not wise to reverse polarity. For the same reason, it is also important to keep the GND connected at all times. Specially during powerup of the board and/or the usb-host.

Thank you. I have tried minicom just now. Same issues. Minicom config shows serial port set to /dev/ttyUSB0 and I see that in /dev on the raspberry Pi. Other setting are 115200 baud and 8N1 for bits, parity and stop. Completely standard and what screen was using. Also Hardware Flow Control is ‘yes’ while software is ‘no’

There are 4 USB ports on the Raspberry Pi. Two are USB 2 and 2 are USB 3. I have tried both USB 2 ports. When the system was working these were the ports in use. There are no other USB devices connected to the Raspberry Pi.

The USB to DuPont cables are the same as used when the connection worked. I have used the hardwired cable for the FTDI adapter which adds 1.8m to the total length, and thought that significant now that you highlight it. So I removed all USB cables apart from the one as part of the FTDI adapter. So the total length is 1.8m. Makes no difference.

I appreciate your assistance.

Set it to ‘no’…

Thanks. Have done. Restart the R3. Unplugged and replugged the uART. No change at all.

When I plugged the uART in minicom displayed a few question marks and other characters briefly but nothing else.

The right setting is 115200 8n1 flow control off. Rx/tx crossed.