This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Serial IO problem without interrupt

Hi, I'm french so excuse me for my English.
I want to communicate with a PC and a 80c552 card made by myself, this with a serial link.
I have no INT and just an emission of an octet from the 80c552 card to the PC.
My problem is that the PC receives values but not the good one.
In fact only FF is received correctly.
I have made a communication between two PC so my program on the PC is ok.
So the problem comes from the program loaded on the 80c552 and written with keil c51.
I use the mode 1 of serial IO with SM1=1 and I have tried several speed from 2400 to 20000 bauds but nothing changed.
I have no parity and just an octet with a start bit and a stop bit.
Thanks for your help, please answer in english (your french is not so good...), and tell me if there is a better forum for this kind of problem.

Florian

Parents
  • I have found my problem and everything works fine. It was a problem of speed, that's why there was a bit set to one in the octet.
    In fact 9300 or 10400 on the 80c552 wasn't close enough to 9600bds, that's why I modified the speed of the UART. For the 8052 uart of the PC you have to set the value to 0C to have a speed of 9600bds, so I modified it to 0D and it works. This value does not exist in the doc but it is closer to 9300 which is the speed of the 80c552.
    My english is not perfect so I hope everybody understood my solution.

Reply
  • I have found my problem and everything works fine. It was a problem of speed, that's why there was a bit set to one in the octet.
    In fact 9300 or 10400 on the 80c552 wasn't close enough to 9600bds, that's why I modified the speed of the UART. For the 8052 uart of the PC you have to set the value to 0C to have a speed of 9600bds, so I modified it to 0D and it works. This value does not exist in the doc but it is closer to 9300 which is the speed of the 80c552.
    My english is not perfect so I hope everybody understood my solution.

Children