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 data between two 8051

I would like to have my two 89C51RD2 communicate with each other via UART. They are connected such that one TX pin is connected to the other's RX pin and vice versa.

I tried sending byte by byte and it is working. However, when I tried to transmit larger amount of data at one go, the receiving end isnt able to read the data.

I feel that I am missing something silly. Is the microcontroller able to store the incoming data while I poll and get them byte by byte?

Would somebody please advise. Thank you.

Cheers

Parents
  • In that case if I call data_poll() periodically by placing it in an infinite loop, then the problem would not exist isnt it? As the char_poll() will still come in the next time round to read the data.

    Am I right to say that, a potential problem would be that transmit side is too fast such that before the reciever can retrieve the previous data sent from SBUF, another byte is written to it and hence data is lost?

Reply
  • In that case if I call data_poll() periodically by placing it in an infinite loop, then the problem would not exist isnt it? As the char_poll() will still come in the next time round to read the data.

    Am I right to say that, a potential problem would be that transmit side is too fast such that before the reciever can retrieve the previous data sent from SBUF, another byte is written to it and hence data is lost?

Children
No data