| ??? 02/08/04 05:13 Read: times |
#64218 - Parallel Async Communication Protocol |
I was looking for a Parallel Async Communication Protocol for 8051 but I couldn't find any( if you know some please refer me to that) so I developed one
I want to ask for your technical criticisms and ideas. because I was so much preoccupied with developing a usb firmware and driver you may see some similarities :). in brief it follows : 1- The communication path is a nine bit bus connected to two nine bit fifos for two ways transmission. 2-A communication always begin with a command I/O Packet(IP) in which 9th bit is 1. Remaining bits are CRC for the command + the data that follows it and the command itself. Depending on the command some data bytes may follow the command that their 9th bits are zero. 3-After each IP, the receiver sends an Acknowledged (ACK) if CRC is OK and a not acknowledged(NAK) if CRC is wrong. If the packet is important sender 8051 may waits for an ACK message and resend if it receives a NAK(in the case of glitch). In the ACK and NAK frame they may exchange some status data too. 3-Each 8051 has a variable (Queued IPs) that increments when it sends an IP and decrements when it receives an ACK or NAK message. 4-The beauty of this protocol is that there is no need for a supervisor chip because 8051s cross check each other and if Queued IPs exceed MAX_ALLOWD_QUEUED_IPS then the sender 8051 sends an interrupt and warns the other to complete Queued IPs soon or face consequences (reset). as I said I welcome your technical criticisms and ideas. regards, Ebrahim Vakilpour |



