102Views5Replies

Author Options:

What would be a suitable serial protocol? Answered

I'm currently working on programming a serial interface to put onto I/O devices (number pad, LCD, sensors, secondary microcontroller...) in order to reduce the amount of I/O pins and external connections needed.

The only requirements are that it needs to use only two wires (excluding power), and it needs to be bidirectional. Ideally, I'd like to avoid anything that needs too much processing of data before transmission (like adding extra bits to prevent a string of '1's from setting off the error protection).

Hopefully, this project will end up as an instructable at some point, so what would be a suitable protocol that would be compatible with common microcontrollers?

Thanks in advance.

Comments

The forums are retiring in 2021 and are now closed for new topics and comments.
0
steveastrouk
steveastrouk

Best Answer 8 years ago

The industry standards are SPI and I2C. What are you trying to do ?

Steve

0
The Skinnerz
The Skinnerz

Answer 8 years ago

I'm planning to add a board with a small microcontroller on it between the parallel input of an alphanumeric LCD and whatever is sending data to it. This is to greatly reduce the number of I/O pins required and to take most of the load of running the display off of the microcontroller sending the data.

Thanks for the suggestions, I'll look into those.

0
steveastrouk
steveastrouk

Answer 8 years ago

You CAN buy SPI driveable LCDs, and I2C is available too.

NEITHER bus is designed for much more than "on board" distances though, and you'll start to look at CAN buses instead for rock solid data transfer.

0
The Skinnerz
The Skinnerz

Answer 8 years ago

I already have an LCD using the standard Hitachi driver, and was doing this as a programming/technical exercise. I also want to add extra functions on top of just decoding serial data such as providing a buffer and initiating the display.

Thanks for the help, I2C looks good so far.

0
steveastrouk
steveastrouk

Answer 8 years ago

I prefer SPI personally. Its not speed limited like I2C