UART receive is receiving wrong chars

Go To Last Post
3 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I have a simple program to receive a char from a terminal, and print something when a char is recognized. The problem is, all the ASCII coming in from the terminal (program on a PC) is weird, but consistent. I.e. the 'a' key sends 0xB1, 'b' sends 0xB2, 'c'=0xB3, 'd'=0xB4, 'e'=0xB3, '@'=0xC0, 'A'=0xA1. No rhyme of reason to it. I've tried a few UART example programs, to no avail. This is also the only AT90S8535-8PC I have with me (running at 4MHz). Any help would be greatly appreciated.

Please help me not pull out the rest of my hair :-)

Thanks in advance!

Regards,
JJ

admin's test signature
 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

what are the uart parameters of your PC ?

i use :
data bits : 8
parity : none
stop bits : 1
handshaking : none

how exact is your BaudRate ? mine has 0.16% Error in frequency

admin's test signature
 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

It does suggest baud rate John.

Can you transmit an uppercase 'U' (character 0x55) and measure the resulting transmission on an oscilloscope?

A.

admin's test signature