avr-chat
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-chat] UART: 9600 baud limit


From: Blake Leverett
Subject: Re: [avr-chat] UART: 9600 baud limit
Date: Thu, 17 Apr 2008 12:58:45 -0600
User-agent: KMail/1.9.7

On Thursday 17 April 2008, address@hidden wrote:
> Hey guys,
>
> I'm working with an ATmega32 on an STK500, and also on a breadboard which
> is the eventual target. I've been struggling to get UART to work, and now
> that I did succeed, I can't get a baud of more than 9600. Now, with the
> STK500 and the software clock, I get get 38400 - 115200, but with the
> external oscillator plugged into the STK500 board I simply cannot achieve
> more than 9600.
>
> Anything more than 9600 results in garbage. Yes, I'm setting my terminal
> emulator accordingly.
>
> I *am* using an external oscillator, running at 8.0 Mhz.
>
> I did set the fuse bits accordingly, does anyone have any ideas? I moved
> the OSCEL jumper and left the XTAL1 jumper mounted.
>
> I know the external oscillator is working because when I put it on the
> breadboard the chip works, but when I remove it from the breadboard the
> chip freezes up.
>
> Any ideas? Anyone else ever struggled to achieve more than 9600 baud?

Do you have an oscilloscope?  Can you look at the serial signals coming out of 
the chip and verify that the bit times are correct?  Chances are that you 
will see what is going wrong by looking at the signals directly.  If the 
signal looks OK, be sure to measure the timing carefully.

It's probably a slight error that's causing your output signal to be slightly 
slow or fast.  To test this, try running at 19200 baud, and adjust the baud 
rate divisor by one or two (plus and minus) from its nominal setting and see 
if you get a working signal.  If you do, then there is a timing accuracy 
problem.  Note that the error could be on the terminal end.

Blake




reply via email to

[Prev in Thread] Current Thread [Next in Thread]