Page 1 of 1

Garbage output USB to Serial cable

Posted: Tue Jan 27, 2015 9:04 pm
by smooth_jamie
Hi All,

I've sucessfully used a USB to Serial cable before using SSH through Putty to send commands to my raspberry Pi. However this week I decided to start a new project and I have found a problem that I haven't come across before. When I start Putty and turn on the Pi I get the standard boot up messages but the whole thing stalls and spews garbage nonsense characters (I've noticed it spews them out just before the boot up sequence too) see screenshots via dropbox link below;

Pictures
https://www.dropbox.com/sh/kegrwnsy5oek ... 1Jmoa?dl=0

I've googled the problem and the closest problem seems to be the following link --> http://www.raspberrypi.org/forums/viewt ... 3&p=564260

I am using Adafruit's Occidentalis for the SD card image and I have the correct work around drivers through Windows 8.1. I have connected the USB cable to the GPIO pins GND, TX, RX. Powering the Pi from a power supply or by connecting the 5v GPIO pin or 3.3v Pin yields the same results. At Baud rate 115200 I get no output whatsoever, but I can edit the cmd.txt on the SD card to use 9600 Baud which gives me something, other than that I'm still stuck. Can anyone help?

Re: Garbage output USB to Serial cable

Posted: Wed Jan 28, 2015 1:09 pm
by smooth_jamie
BUMP!

Re: Garbage output USB to Serial cable

Posted: Thu Jan 29, 2015 2:58 pm
by smooth_jamie
BUMP! Can anyone help?......

Re: Garbage output USB to Serial cable

Posted: Thu Jan 29, 2015 3:43 pm
by FTrevorGowen
What happens if you perform a loopback test (ie. connect Rx and Tx together and try something like hyperterminal on your Windows m/c)? Personally, I only use PuTTy for SSH connection via the network on the rare occasions when I boot my netbook into Windows (XP) instead of Ubuntu. FWIW, there are some (brief) notes about various USB-to-serial (TTL @ 3.3V) adapters I tried here:
http://www.cpmspectrepi.webspace.virgin ... pters.html
http://www.cpmspectrepi.webspace.virgin ... rtRep.html
http://www.cpmspectrepi.webspace.virgin ... ector.html
NB: The above have all been used with "mainstream" Raspbian.
Trev.

Re: Garbage output USB to Serial cable

Posted: Fri Jan 30, 2015 8:06 am
by smooth_jamie
Thanks for your reply. I am just researching how to do a loopback test, since I understand this from reading posts from users with similar problems. Unfortunetly I don't know where to start.

I will try google and see if there are any useful guides for loopback testing and will post the results once I'm finished.

With regards to putty, I did try and SSH using the IP address instead of the serial port and I can log in without any problems there. Another clue is, sometimes I will get the error "MULTIPLE_IRC_CONNECT_REQUESTS" and my Windows 8 PC will automatically rebooot after displaying BSoD after trying to use USB to Serial to login.

Re: Garbage output USB to Serial cable

Posted: Fri Jan 30, 2015 8:30 am
by FTrevorGowen
smooth_jamie wrote:Thanks for your reply. I am just researching how to do a loopback test, since I understand this from reading posts from users with similar problems. Unfortunetly I don't know where to start.
I will try google and see if there are any useful guides for loopback testing and will post the results once I'm finished.
...
In it's simplest form just connect Rx & Tx together (and not to the Pi), open a terminal with the required transmission protocol, speed etc., with auto-echo on - every character typed should be duplicated.
Trev.

Re: Garbage output USB to Serial cable

Posted: Sat Jan 31, 2015 3:15 pm
by smooth_jamie
Hi All,

Thanks for the help so far! I found the solution to the issue in the following post whilst googling how to do the loopback test;

http://www.raspberrypi.org/forums/viewt ... p?p=139945

Everything is working as intended now. For anyone else reading this post in the future the solution was;
Install PySerial

Code: Select all

sudo apt-get install python-serial
add the pi user to the dialout group with

Code: Select all

sudo usermod -a -G dialout pi
Edit cmdline.txt on the SD card, and remove references to ttyAMA0
Disable getty on serial port in /etc/inittab

Code: Select all

#2:23:respawn:/sbin/getty -L ttyAMA0 115200 vt100
Then reboot.

I will mark the thread as solved now. Thanks guys.