Thursday, June 10, 2010

Circular Buffered UART Com Module for 8051 Microcontroller

A lot of embedded systems uses UART communication. That is why, I would like to share a circular buffered UART comm module here. I have developed the module for 8051 microcontroller but it can easily be modified for other microcontrollers as well.

Using Circular Buffered UART Com Module

You need to put the header files in the module you want to use them. In my example, I put all my header files into 'headers.h' file and I just need to include that file. Transmit and receive buffer sizes need to be defined in ComConfig.h file. And then, define a function to call on receive event. In the main function, poll the ComChkRx() function to retrieve the received data from the buffer. The source code for the example can be seen at

UART-Timer-8051 on GitHub

No comments:

Post a Comment

Comments are moderated and don't be surprised if your comment does not appear promptly.