EmbLogic's Blog

SERIAL COMMUNICATION

SERIAL COMMUNICATION

The serial port on your PC is a full-duplex device meaning that it can send and receive data at the same time. In order to be able to do this, it uses separate lines for transmitting and receiving data. Some types of serial devices support only one-way communications and therefore use only two wires in the cable – the transmit line and the signal ground.

 Communicating by Bits

Once the start bit has been sent, the transmitter sends the actual data bits. There may either be 5, 6, 7, or 8 data bits, depending on the number you have selected. Both receiver and the transmitter must agree on the number of data bits, as well as the baud rate. Start and stop bit is send before and after the data has send.

The Parity Bit

Besides the synchronization provided by the use of start and stop bits, an additional bit called a parity bit transmitted along with the data. A parity bit provide a small amount of error checking, to help detect data corruption that might occur during transmission. You can choose either even parity, odd parity. When even or odd parity is being used, the number of marks (logical 1 bits) in each data byte are counted, and a single bit is transmitted following the data bits to indicate whether the number of 1 bits just sent is even or odd.

RS-232 Protocol

RS-232 is the name for a standards for serial binary single-ended data and control signals connecting between data terminal equipment and data circuit-terminating equipment. It is commonly used in computer serial ports. The standard defines the electrical characteristics and signals timing, size and pin-out of connectors. This protocol defines the maximum open-circuit voltage of +/- 25 volts. Valid signals are in the range of +3 to +15 volts or the range -3 to -15 volts with respect to the ground. The range between -3 to +3 volts is not a valid RS-232 level. For data transmission lines (TxD, RxD etc.) logic one is defined as a negative voltage and the condition is called mark. Logic zero is +ve and the signal condition is termed space. Control signals have the opposite polarity: the active state is positive voltage and the inactive state is negative voltage.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>