Zusammenfassung der Ressource
Basics of Serial Communication
- Review Questions
- Anwers
- Ways to transfer
data
- Parallel
- Transfer 8 bits at the same
time
- - Expensive;
- - 8 or more wire
conductors;
- - Difficulty of
synchronizing the
arrival time of data
lines at longer
distance
- Serial
- - One bit at a
time;
- - Cheap;
- - One
wire;
- - Allows communication for longer
distances;
- SHIFT REGISTERS
- PARALLEL IN SERIAL OUT
- Transform data from
8-bit data bus of the
microprocessor to
serial bits.
- Located at the
sender
- SERIAL IN PARALLEL OUT
- Receives the serial data and
packs it into a byte.
- Located at the receiver
- Necessity of signal modulation
- Short distances
- NO modulation
- Ex. Keyboards
- Long distances
- Modulation is necessary
- Ex. audio tones to 0s and 1s and vice-versa
- Methods
- Synchronous
- Transfers a block of data
(characters) at a time;
- Asynchronous
- Transfers a bit at a
time;
- Characteristics
- Protocol
- Definition: it is a set of rules
on which the sender and the
receiver agree. It defines how
the data is packed, how many
bits constitute a character,
and when the data begins
and ends.
- Framing
- Each character is
packed between start
and stop bits
- When there is no data
transfer, the signal stays
1 (mark). The 0 is
referred to as space. The
transmission begins
with the start bit
followed by D0 (LSB),
then the rest of the bits
until D7 (MSB), and
finally the stop bit(s)
indicating the end of the
character.
- Start bit
- 1 bit
- Always 0
- Stop bit(s)
- 1 or 2 bits
- Modern systems may
use only 1 bit. Older
systems used 2 end
bits due to the
slowerness of the
receiving mechanical
devices.
- Always 1
- Overhead
- Assuming 1
stop bit and 1
start bit for
8-bit character
transmission,
the overhead is:
2/8 = 25%
- Parity bit
- Used to maintain data
integrity. May be even or
odd parity bit. It is a bit
that is included in the
data frame, in addition
to start and stop bits.
- For UART
- Options: odd, even, or no-parity.
- The parity bit is transmitted
after the MSB (D7) and
followed by the stop bit.
- Widely used for character oriented transmissions
- Definition
- UART (universal asynchronous receiver-transmitter)
and USART (universal synchronous-asynchronous
receiver-transmitter) are special integrated circuit
chips made for serial data communications.
- Ex. The COM port in the PC uses the UART.
- Simplex vs Duplex
- Data transfer rate
- Unit: bps (bits per second)
or Baud rate (number of
signal changes per second)
- In this book,
bps == baud
- RS232
- It is a serial I/O standard that
allow compatibility among
data communication
equipment made by various
manufacturers. It was set
long before the advent of the
TTL logic family, thus its
input and output levels are
not TTL compatible.
- MAX232: voltage converter that
allows one to connect any
RS232 to a TTL-level chip
(microprocessor or UART)
- Pins for the RS232 cable (DB-9 connector)
- Handshaking signals
- It helps to coordinate the
data transfer.
- Data communication classification
- DTE (data terminal equipment)
- Terminals and computers that
send and receive data
- DCE (data communication equipment)
- Communication equipment, such as
modem, that is responsible for
transferring the data.
- The simplest communication
between two PCs (DTE with DTE)
requires a minimum of three pins
(TxD, RxD, and ground).