1 / 15

SERIAL COMMUNICATION

SERIAL COMMUNICATION. DATA TRANSFER. Two methods – serial and parallel Parallel – number of lines Used for short distance data transfer Serial – used for long distance communication One bit is transferred at a time. 8051 has serial communication capability.

patsy
Download Presentation

SERIAL COMMUNICATION

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. SERIAL COMMUNICATION

  2. DATA TRANSFER • Two methods – serial and parallel • Parallel – number of lines • Used for short distance data transfer • Serial – used for long distance communication • One bit is transferred at a time. • 8051 has serial communication capability.

  3. Asynchronous commn. And data framing • Character oriented transmission • Character is placed between start and stop bits. • This is called framing • LSB is sent out first. • I is referred to as mark • 0 is referred to as space • Start bit is send first followed by D0 • Stop bit indicated end of character. • Overhead is high about 20%

  4. Data transfer rate • Rate in serial data transfer starts in bps • Another terminology is baud rate. • Baud rate is the number of changes per second. • A single change of signal may transfer several bits of data.

  5. RS – 232 STANDARDS • To allow compatibility among data commn. Equipment. • Interfacing standard RS -232 • Set by EIA – electronic industries association • Most widely used serial I/O interfacing • This standard is used in PCs and other equipments • This standard was set before the advent of TTL logic family. • Its input and output voltage levels are not TTL compatible.

  6. In RS-232 1 is represented by -3 to -25V • 0 - +3 to +25V • -3 to +3 undefined. • To connect RS-232

  7. Basics of serial communication • Communication with outside world • Data in byte sized chunks • Parallel communication is expensive • So serial communication is used. • Serial communication provides data transfer over telephone lines. • Parallel to serial conversion is done using shift registers.

  8. Conversion is done by modem. • Modulate and demodulate. • Serial commn. – two methods • Synchronous and asynchronous. • Sinc. –transfer a block of data at a time • Async. – transfers a byte of data • Program can be done , but tedious. • So special IC chips are made for data communication.

  9. These chips are USART or UART • Universal synchronous asynchronous receiver transmitter • 8051 has a built in UART. • Half duplex, simplex and full duplex

  10. RS -232 • DB 25 connector • All the pins are not used. • IBM introduced the DB -9 version. • Used only 9 pins.

  11. Data Communication Classification • DTE - terminals and computers • DCE – modem and data transferring equipments • Simplest connection between PC and MC requires minimum three pins • TxD, RxDand GND. • RxD and TxD pins can be interchanged.

  12. RS 232 handshaking signals • For reliable txion. Data transfer must be coordinated. • Handshaking signals • They are not supported by 8051. • 1.DTR – data terminal ready. • Active low signal. • 2.DSR – data set ready • Active low signal

  13. 3 RTS – request to send. • 4.CTS – clear to send • 5DCD – data carrier detect. • 6 RI • DTR and DSR are used by PC and modem • RTS and CTS control the flow of data

  14. 8051 Connection to RS - 232 • RS232 standard is not TTL compatible. • It requires line driver MAX 232 chip to convert voltage levels. • RxD and TxD pins in 8051 • Transferring and receiving data serially • These two pins are part of port3 - P3.0 – RxD and P3.1 – TxD • These pins are TTl compatible. • To make RS 232 compatible MAX 232 is used.

  15. MAX 232 • SCON register • SBUF register • For serial communication • Data must be placed in SBUF

More Related