3

EDIT: Finally got it to work, see answer below for a complete guide on how to make this thing work starting from scratch

I have a PL2303HX cable connected to the GPIO on 5V GND RXD TXD and it IS working but not completely.

When I boot the Pi I can see the boot messages on the screen right up until it displays the following line:

[   20.973184] IPv6: ADDRCONFink becomes ready

After that the console goes silent. I am able to login via SSH over the network so the Pi did boot properly. If I issue a reboot command it takes a few seconds and the TTL console eventually shows up a bunch of shutdown messages and then it displays the boot up process until the same IPv6 line again.

So what is going after the network is brought up that could cause this problem?

There was some customization done to this raspbian install but nothing special, a few packages, some sshd configuration, allowed tt1 login to root only.

But I dont even get to the login screen so I dont think that is the issue.

EDIT: I added the following line to /etc/inittab

2:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100

And it started working a little more but its not yet usable. I get past the IPv6 line and end up to what appears to be a login prompt but a lot of characters are missing. When I type only 2 or 3 letters will appear then i cant type anything. I press enter, nothing. Then, half the login prompt appears again.

TCZ8
  • 171
  • 1
  • 6

2 Answers2

4

How to get the TTL console working on the Raspberry Pi

STEP 1
Edit /boot/cmdline.txt and make sure you have the following:

dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 elevator=deadline root=/dev/mmcblk0p2 rootfstype=ext4 rootwait

The important part here is to have console=ttyAMA0,115200 and kgdboc=ttyAMA0,115200

STEP 2
Edit /etc/inittab make sure you have at least one and only one of the following lines addressing the ttyAMA0 device:

T0:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100
2:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100

Several on-line sources suggest 2:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100 is what should be in there but I used the other line which is how the comments in inittab advise to do it for a serial console. I'm sure they both lines work.

STEP 3
If you still can't get it working or have characters missing or corrupted try lowering the port speed.
The default speed is 115200 but that didn't play ball with my cheapbay USB-TTL cable.
To fix this, edit the previous files and replace all occurrences of 115200 by a lower port speed.

Make sure you use a valid port speed!
Stick to the following:

1200, 2400, 4800, 9600, 19200, 38400, 57600 and 115200

I used 9600 and saved the day. Faster should work but I dare you to type faster than 9600 bits per seconds :)

edit.: Just tested 57600 and it's working fine, not many difference though.

TCZ8
  • 171
  • 1
  • 6
  • While it's hard to type at a rate of 9600 bits per seconds, such rate is more than modest for output: try running top and see how slow the screen update is. – Dmitry Grigoryev Mar 18 '19 at 13:04
0

As suggested in this link, just execute the following

   sudo raspi-config

after this from the UI navigate to --> Interface Options --> P6 Serial --> ON

That's it

This should help in enabling your ttl