communication model
TRANSCRIPT
General Communications: face-to-face conversation, write a letter, etc.
Electronic Communications: telephone, wireless phone, TV, radar, etc.
Concept and Model of Communications
Concept and Model of Communications
Our Focus Computer Communication
General Communication Model
Source TransmitterTransmission
SystemReceiver Destination
S(t) T(t) Tr(t) Sd(t)
MicrophoneTelephoneComputerScanner
TransformerEncoderCompressModulator
Line/CableFiber/AirSatelliteNetwork
TransformerDecoderUncompressDemodulator
SpeakerEarphoneComputerPrinter
Basic Communication Criteria: Performance, Reliability, Security
Simplified Communications Model (2)
Sourcegenerates data to be transmitted
Transmitterconverts data into transmittable signals
Transmission Systemcarries data
Receiverconverts received signal into data
Destinationtakes incoming data from the receiver
Components of a data communications system
l. Message The message is the information (data) to be communicated. Popular forms of information include text, numbers, pictures, audio, and video.2. Sender The sender is the device that sends the data message. It can be a computer, workstation, telephone handset, video camera. 3. Receiver The receiver is the device that receives the message. It can be a computer, workstation, telephone handset, television.4. Transmission medium The transmission medium is the physical path by which a message travels from sender to receiver. Some examples of transmission media include twisted-pair wire, coaxial cable, fiber-optic cable, and radio waves.
5. Protocol A protocol is a set of rules that govern data communications. It represents an agreement between the communicating devices. Without a protocol, two devices may be connected but not communicating, just as a person speaking French cannot be understood by a person who speaks only Japanese
Transmission MediaTransmission Media
A transmission medium: - a connection between a sender and a receiver - a signal can pass but with attenuation/distortion - a special system with a transmission bandwidth
Guided (Wired) Media (lines) - Twisted pair (0~10MHz) - Coaxial cable (100K~500MHz) - Optical fiber (180~370THz)
Unguided (Wireless) Media (air, vacuum, water, etc.) - LF (30~300KHz, Navigation) - MF/HF (300~3000KHz, AM/SW radio) - VHF (30~300MHz, TV & FM radio) - UHF (0.3~3GHz, TV, mobile phone) - SHF (3~30GHz, satellite, microwave) - EHF (30~300GHz, experimental com) - Infrared (no frequency allocation)
What is Data Communications?Exchange of digital information between
two digital devices is data communication
Data TransmissionData transmission is the transfer of data
from point-to-point often represented as an electromagnetic signal over a physical point-to-point or point-to-multipoint communication channel
A communication channel refers to the medium used to convey information from a sender (or transmitter) to a receiver, and it can use fully or partially the medium.
Examples of channels: copper wires, optical fibbers or wireless communication channels.
Requirements of Data Communications At least Two Devices ready to communicate A Transmission Medium A set of Rules & Procedure for proper
communication (Protocol) Standard Data Representation Transmission of bits either Serial or
Parallel
case of Asynchronous TransmissionBit synchronisation using Start/stop bits inIn Synchronous Transmission the agreed
pattern of FlagSignal encoding rules viz. NRZ or RZAnd other higher layer protocol
Data RepresentationsA group of bits are used to represent a
character/number/special symbol/Control Characters
5-bit code can represent 32 symbols (25=32)
7-bit code can represent 128 symbols (27=128)
8-bit code can represent 256 symbols (28=256)
Code SetA code set is the set of codes representing
the symbolsVery common code sets are :
– ASCII : this is ANSI’s 7-bit AmericanStandard Code for Information Interchange
ASCII code(7-bit) is often used with an 8th bit known as parity bit used for detecting errors during Data Transmission
Parity bit is added to the Most Significant bit (MSB)– EBCDIC : this is IBM’s 8-bit ExtendedBinary Coded Decimal Interchange Code
ASCII CodeASCII is defined in ANSI X3.4
– Corresponding CCITT recommendation isIA5 (International Alphabet No.5)– ISO specification is ISO 646
Total 128 codes– 96 codes are graphic symbols (in row. 2~7 in code chart).
94 codes are printable
And 2 codes viz. SPACE & DEL characters are non printable
– 32 codes control symbols (row. 0 & 1 in code chart)
All are non printable
Parallel Transmission and Serial Transmission
Parallel Transmission and Serial Transmission
Sender Receiver
…011000110111010111…?
Sender Receiver
0110001
7 (N) bits are sent together7 (N) lines are needed
Parallel Transmission
Sender Receiver0 1 1 0 0 0 1
7 (N) bits are sent one after anotherOnly 1 line is needed
Serial Transmission
0110001
0110001
P/S converter S/P converter
… 01…00 01…10 11…10 10…11 …N N N N
Segment the 0/1 stream into N bits groups
Parallel Transmission Parallel transmission allows transfers of multiple data bits at
the same time over separate media
In general, parallel transmission is used with a wired medium that uses multiple, independent wires
Furthermore, the signals on all wires are synchronized so that a bit travels across each of the wires at precisely the same time
Engineers use the term parallel to characterize the wiring
17
Parallel Transmission The figure omits two important details:
(1) In addition to the parallel wires that each carry data, a parallel interface usually contains other wires that allow the sender and receiver to coordinate
(2) To make installation and troubleshooting easy, the wires for a parallel transmission system are placed in a single physical cable
A parallel mode of transmission has two chief advantages:
(1) High speed: it can send N bits at the same time a parallel interface can operate N times faster than an
equivalent serial interface
(2) Match to underlying hardware: Internally, computer and communication hardware uses parallel circuitry
a parallel interface matches the internal hardware well
Serial Transmission Serial transmission
sends one bit at a time
It may seem that anyone would choose parallel transmission for high speedsHowever, most communication systems use serial mode
There are two main reasons
(1)serial networks can be extended over long distances at less cost
(2)using only one physical wire means that there is never a timing problem caused by one wire being slightly longer than another
Sender and receiver must contain a hardware that converts data from the parallel form used in the device to the serial form used on the wire
Serial Transmission The hardware needed to convert data between
an internal parallel form and a serial form can be straightforward or complex
In the simplest case, a single chip that is known as a Universal Asynchronous Receiver and Transmitter (UART) performs the conversion
A related chip, Universal Synchronous-Asynchronous Receiver and Transmitter (USART) handles conversion for synchronous networks
21
Timing of Serial Transmission Serial transmission mechanisms can be divided into
three broad categories (depending on how transmissions are spaced in time):
Asynchronous transmission can occur at any timewith an arbitrary delay between the transmission of two
data items
Synchronous transmission occurs continuously with no gap between the transmission of two data items
Isochronous transmission occurs at regular intervals with a fixed gap between the transmission of two data
items
Asynchronous Transmission It is asynchronous if the system allows the physical medium to
be idle for an arbitrary time between two transmissions
The asynchronous style of communication is well-suited to applications that generate data at random (e.g., a user typing on a keyboard or a user that clicks on a link)
The disadvantage of asynchrony arises from the lack of coordination between sender and receiver While the medium is idle, a receiver cannot know how long the
medium will remain idle before more data arrives
Asynchronous technologies usually arrange for a sender to transmit a few extra bits before each data item to inform the receiver that a data transfer is starting
extra bits allow the receiver to synchronize with the incoming signal
the extra bits are known as a preamble or start bits
25
Synchronous Transmission A synchronous mechanism transmits bits of data
continually with no idle time between bits after transmitting the final bit of one data byte, the sender
transmits a bit of the next data byte
The sender and receiver constantly remain synchronized which means less synchronization overhead
On a synchronous system each character is sent without start or stop bits
Synchronous transmission: A bit stream is segmented into relative large groups/blocks many characters or bytes Add control bits at the beginning and end of each block Frame = H_control_bits + characters (data_bits) + T_control_bits No gap between two characters in a data block
Asynchronous and Synchronous Transmission
Asynchronous and Synchronous Transmission
Sender Receiver011000101 100110001 001110101
Sender Receiver0110001Con_bits 10011000011101 Con_bits
101110001
1011100. . .0110001
Stopwtch.ani Stopwtch.ani
Stopwtch.aniStopwtch.ani
independent
synchronized
Asynchronous Serial Transmission
(RS232 Example) Because no signal lines are used to convey clock (timing) information, this method
groups data together into a sequence of bits (five to eight), then prefixes them with a start bit and a stop bit. This is the method most widely used for PC or simple terminal serial communications.
In asynchronous serial communication, the electrical interface is held in the mark position between characters. The start of transmission of a character is signaled by a drop in signal level to the space level. At this point, the receiver starts its clock. After one bit time (the start bit) come 8 bits of true data followed by one or more stop bits at the mark level.
The receiver tries to sample the signal in the middle of each bit time. The byte will be read correctly if the line is still in the intended state when the last stop bit is read.
Thus the transmitter and receiver only have to have approximately the same clock rate. A little arithmetic will show that for a 10 bit sequence, the last bit will be interpreted correctly even if the sender and receiver clocks differ by as much as 5%.
It is relatively simple, and therefore inexpensive. However, it has a high overhead, in that each byte carries at least two extra bits: a 20% loss of line bandwidth.
Synchronous Serial Transmission (PS2 Example) The PS/2 mouse and keyboard implement a bidirectional synchronous serial
protocol. The bus is "idle" when both lines are high (open-collector). This is the only state
where the keyboard/mouse is allowed begin transmitting data. The host has ultimate control over the bus and may inhibit communication at any time by pulling the Clock line low.
The device (slave) always generates the clock signal. If the host wants to send data, it must first inhibit communication from the device by pulling Clock low. The host then pulls Data low and releases Clock. This is the "Request-to-Send" state and signals the device to start generating clock pulses.
Summary: Bus StatesData = high, Clock = high: Idle state.Data = high, Clock = low: Communication Inhibited.Data = low, Clock = high: Host Request-to-Send
Data is transmited 1 byte at a time:•1 start bit. This is always 0. •8 data bits, least significant bit first. •1 parity bit (odd parity - The number of 1's in the data bits plus the parity bit always add up to an odd number. This is used for error detection.). •1 stop bit. This is always 1. •1 acknowledge bit (host-to-device communication only)
Simplex Transmission and Duplex Transmission
Simplex Transmission and Duplex Transmission
Device A Device BSimplexTransmission
Direction of data
Device A Device BHalf DuplexTransmission
Direction of data at time 1
Device A Device BFull DuplexTransmission
Direction of data all the time
Direction of data at time 2
One can send and the other can receive
Both can send and receive but in different time
Both can send and receive simultaneously
Simplex
In simplex mode, the communication is unidirectional.
Only one of the two devices on a link can transmit; the other can only receive
Keyboards and traditional monitors are examples of simplex deviceskey board can only introduce input; the monitor can only accept output.The simplex mode can use the entire capacity of the channel to send data in one direction
Half-duplex
In half-duplex mode, each station can both transmit and receive, but not at the same time.When one device is sending, the other can only receive, and vice versa
ln a half-duplex transmission, the entire capacity of a channel is taken over by whichever of the two devices is transmitting at the time. In half-duplex, the entire capacity of the channel is taken over by the transmitting (sending).
Walkie-talkies and CB (citizens band) radios are both half-duplex systems
Full-duplex
In full-duplex mode both stations can transmit and receive simultaneously
In full-duplex mode, signals going in one direction share the capacity of the link with signals going in the other direction.
This sharing can occur in two ways: either the link must contain two physically separate transmission paths, one for sending and the other for receiving; or the capacity of the channel is divided between signals traveling in both directions.
One common example of full-duplex communication is the telephone network. When two people are communicating by a telephone line, both can talk and listen at the same time
Communication Standards and Related Organizations
Communication Standards and Related Organizations
Communications need standards for inter-operations of different devices
Standard Organizations: - ISO (International Standards Organization): ISO number - ITU (International Telecommunication Union): V.num & X.num - EIA (Electronic Industries Association): EIA-num - IEEE (Institute of Electronics Engineers): IEEE.num - ANSI (American National Standards Institute): ASCII, etc. - IETF (Internet Society and Internet Engineering Task Force): RFC num - W3C (World Wide Web Consortium): HTTP, HTML, XML, … - WAP Forum (Wireless Application Protocol): WAP-num