Professional Documents
Culture Documents
Lecture 13
What is RS-232?
• Back in the 1950s …
D-Type-25 D-Type-9
Pin # Pin # Abbreviation Full Name
2 3 TD / TxD Transmit Data
3 2 RD / RxD Receive Data
4 7 RTS Request To Send
5 8 CTS Clear To Send
6 6 DSR Data Set Ready
7 5 SG / GND Signal Ground
8 1 CD / DCD Data Carrier Detect
20 4 DTR Data Terminal Ready
22 9 RI Ring Indicator
Wirings – Full handshaking
For full handshaking to support flow control
PIN 1: CD
PIN 2: TxD
PIN 3: RxD
PIN 4: DTR
PIN 5: GND
PIN 6: DSR
PIN 7: RTS
PIN 8: CTS
PIN 9: RI
Image source: http://www.cepd.com/calculators/serial.htm
Handshaking
DTE (PC with COM port) DCE (modem)
i.e. connected to telephone line
Turned on and ready
DTR Turned on and ready
DSR
CTS
Note:
If DCE does not activate CTS, the DTE (PC) will deactivate DTR and try again.
Wirings – Null Modem
• Allows two DTEs to communicate directly.
• Typical for connecting between microcontroller and PC.
PIN 1: CD
PIN 2: TxD
PIN 3: RxD
PIN 4: DTR
PIN 5: GND
PIN 6: DSR
PIN 7: RTS
PIN 8: CTS
PIN 9: RI
Image source: http://www.cepd.com/calculators/serial.htm
Transmitter and Receiver
• There is a parallel I/O interface that transfers data
from the source to the transmit data buffer and from
the received data buffer to the destination.
Data framing
• Asynchronous serial data transmission is widely used for a
character-oriented transmission.
To micro-
controller
With Baud rate of 9600 bit per second (bps), the time it takes to
transfer 5 pages is:
___________ seconds
Exercise 2
Given that 7-E-1 protocol and Baud rate of 57600 bps is used,
find total number of bits and time it takes to transfer 5 pages of data
and each page has 8025 characters.
With Baud rate of 57600 bit per second (bps), the time it takes to
transfer 5 pages is:
___________ seconds