Serial Data to / from BBB

Problems uploading, serial connections, BUBs, P4, FTDI cables, etc
Post Reply
madbeing
Posts: 4
Joined: Wed Dec 24, 2008 3:50 pm

Serial Data to / from BBB

Post by madbeing » Wed Dec 24, 2008 5:07 pm

I read the post about the resonator only being off by a small percent but I'm wondering what could be the problem with my setup.
I'm using the USB -> ttl serial cable that's part of the package deal of a bbb + cable. I can download code just fine to the device.
But, when I attempt to send data from the bbb faster than 4800 baud it comes out garbled. To me, this indicates a mismatch in
the bit rates between the host computer and the bbb board. I haven't tried receiving data from the computer at speeds higher
than 4800. I'll try that if it will help diagnose the problem.

Any suggestions as to why higher speeds are garbled? This is arduino-0012 / linux with a newly purchased / assembled bbb board.

thanks,
Dan

paul
Site Admin
Posts: 735
Joined: Mon May 12, 2008 4:19 pm

Re: Serial Data to / from BBB

Post by paul » Sun Jan 04, 2009 1:59 pm

madbeing,

Sorry for the super slow reply. This fell through the cracks, amid holiday fuss. Everything has been really hectic this year.

You are correct that baud mismatch is the usual reason for garbled serial output.

Are you just sending to serial monitor in Arduino? Did you change the baud rate in the monitor?
I guess it's possible that you have an off spec resonator. Only an oscilloscope will really tell that. The fact that your board uploads correctly seems to indicate something else might be in play.
The default upload speed is 19200 so maybe something else is going on.

Describe the setup you are using for sending and receiving and I'll see if I can think of anything else. You could also reheat the rx and tx pins at the chip and at the cable header, just for good measure.

I've used a lot of BBB's at 115200 without glitches.

Paul

madbeing
Posts: 4
Joined: Wed Dec 24, 2008 3:50 pm

Re: Serial Data to / from BBB

Post by madbeing » Sun Jan 11, 2009 5:22 pm

Paul,

The fix turned out to be much easier.. It turns out the ttyUSB driver on my linux was defaulting to 4800. I'm guessing that the arduino ide download code explicitly sets the device speed to 19200 but only does it for the file handle it has for the download. Anyway, when I set the device speed at the shell prompt to the desired speed everything was fine. I'm guessing that the serial monitor just does an open on the device and doesn't explicitly set the speed. At least that's the observed behaviour. I tried it up to 38400 with no problems.

thanks,
Dan

Post Reply