Tuesday, December 22, 2009

RS232 is a asynchronous serial communication protocol widely used in computers and digital systems. It is called asynchronous because there is no separate synchronizing clock signal as there are in other serial protocols like SPI and I2C.In RS232 there are two data lines RX and TX. TX is the wire in which data is sent out to other device. RX is the line in which other device put the data it need to sent to the device.Voltage levels in RS232 are HIGH=-12V and LOW=+12V.

RS232 Data Transmission :Transmission 1. When there is no transmission the TX line sits HIGH (STOP CONDITION). 2. When the device needs to send data it pulls the TX line low for 104uS (This is the start bit which is always 0). 3. Then it sends each bit with duration of = 104uS. 4. Finally it sets TX lines to HIGH for at least 104uS (This is stop bit and is always 1).Reception : 1. The receiving device is waiting for the start bit i.e. the RX line to go LOW. 2. When it gets start bit it waits for half bit time i.e. 104/2 = 51uS, i.e.it is in middle of start bit, it reads it again to make sure it is a valid start bit and not a spike. 3. Then it waits for 104uS and now it is in middle of first bit. It then reads the value of RX line. 4. In the same way it reads all the 8 bits. 5. Now the receiver has the data.

Limitations of RS232 Standard :* The large voltage swings and requirement for positive and negative supplies increases power consumption of the interface and complicates power supply design. The voltage swing requirement also limits the upper speed of a compatible interface.* Single-ended signaling referred to a common signal ground limits the noise immunity and transmission distance.* Multi-drop connection among more than two devices is not defined. While multi-drop "work-arounds" have been devised, they have limitations in speed and compatibility.* Asymmetrical definitions of the two ends of the link make the assignment of the role of a newly developed device problematic; the designer must decide on either a DTE-like or DCE-like interface and which connector pin assignments to use.* The handshaking and control lines of the interface are intended for the setup and takedown of a dial-up communication circuit; in particular, the use of handshake lines for flow control is not reliably implemented in many devices.* No method is specified for sending power to a device. While a small amount of current can be extracted from the DTR and RTS lines, this is only suitable for low power devices such as mice.* The 25-way connector recommended in the standard is large compared to current practice.