Lecture 04 - Hong Kong Baptist University

Download Report

Transcript Lecture 04 - Hong Kong Baptist University

Lecture 04
Making Connection
1
Introduction
• Connection concept
– Interface concept and standard (Level 1)
(to p3)
• EIA-232F
• USB
• Data Link Connections (Level 2)
(to p35)
(to p48)
• Terminal-to-mainframe computer connections
• Application examples
(to p52)
2
Connection concept
(to p4)
• How computer networks are connected?
3
Connection concept
• Recalled: OSI model – level 1
– Physical level, which requires peripheral
devices to connect two different computers or
devices together
– Termed as “interface” (to p7)
• Two types of standards
• Modes of data flow
• Connection to systems
(to p8)
(to p9)
(to p14)
(to p5)
4
Connection (cont.)
(to p18)
• Characteristics of interface standards
• Two important interface standards
(to p20)
– EIA-232F
– USB (Universal Serial Bus)
• Other interfacing standards
(to p27)
(to p6)
5
Other interfacing standards
• Other peripheral interfacing standards that
provide power, flexibility and ease-of-installation
include:
(to p32)
– FireWire (low cost device for digital)
– SCSI, iSCSC(mainly for permanent storage,
CD/DVD)
– InfiniBand, Fibre Channel (high speed connection)
(to p33)
(to p34)
(to p2)
6
Level 2
Level 1
Data terminating equipment
Data communicating equipment
(to p4)
7
Characteristics of Interface
Standards
• There are essentially two types of standards
– Official standards
• Created by standards-making organizations such as
ITU (International Telecommunications Union), IEEE
(Institute for Electrical and Electronics Engineers), EIA
(Electronic Industries Association), ISO (International
Organization for Standardization), and ANSI (American
National Standards Institute)
• CSA (Canadian standard), UL (USA for computer hardware)
– De facto standards
• Created by other groups that are not official standards
but because of their widespread use, become “almost”
standards
(to p4)
8
data flow
There are 3 types of data flow:
i) simplex transmission
ii) half-duplex transmission
iii) full duplex transmission
(to p10)
(to p12)
(to p13)
(to p4)
9
simplex transmission
• i) simplex transmission
– data is transmitted in one direction only
– ie no data transmission on opposite direction
is allowed
(to p11)
• see Figure 8-2
– Application examples?
(to p9)
10
(to p10)
(to p12)
(to p13)
11
half-duplex transmission
• ii) half-duplex transmission
– transmission in either direction on a circuit but
(to p11)
only one direction at a time
– eg an inquiry is sent to the computer and then
a response is sent back on the same circuit to
the terminal
– Application examples?
(to p9)
12
full duplex transmission
• iii) full duplex transmission
– data transmission in both directions
(to p11)
simultaneously on the circuit
– machine needs to be intelligence at both ends
(why?)
– Application examples?
(to p9)
13
connection to the system
• two types of physical connection in the
system
– i) Parallel data transmission
– ii) Series data transmission
(to p15)
(to p17)
(to p4)
14
Parallel data transmission
• i) Parallel data transmission
– connected via direct cable that has one wire
for each bit in a character of data code being
used by the terminal
(to p16)
» See Figure 8.3
– with multiple wires, all the bits of a characters
can be transmitted between the terminals and
computer at once
– Disadv: very expensive & no practice over
long distance (why?)
(to p14)
15
FIGURE 8-3
Parallel and serial transmission.
(to p15)
(to p17)
16
• ii) Series data transmission
– bits of each character are sent down to a line
one after another
– complicated process because machine needs
to know how to decompose and to reconstruct
(to p16)
of bits at each respective end
– Adv or Disadv?
(to p14)
17
Characteristics of Interface
Standards (continued)
• There are four possible components to an
interface standard:
– Electrical component
– Mechanical component
– Functional component
– Procedural component
(to p19)
Explanations
(to p5)
18
Characteristics of Interface
Standards (continued)
• Four components
– Electrical component – deals with voltages, line
capacitance, and other electrical characteristics
– Mechanical component – deals with items such
as the connector or plug description
– Functional component – describes the function of
each pin or circuit that is used in a particular
interface
– Procedural component – describes how the
particular circuits are used to perform an
(to p18)
operation
19
EIA-232F
• EIA-232F – an older standard originally
designed to connect a modem to a computer
• Originally named RS-232 but has gone through
many revisions
• The electrical component is defined by another
standard: V.28
• The mechanical component is often defined by
(to p21)
(to p23)
ISO 2110, the DB-25 connector. The DB-9
connector is now more common than the DB-25.
(to p24)
20
Worked as full duplex (why?)
Its functions
(to p22)
(to p20)
21
(to p21)
22
EIA-232F (continued)
(to p20)
23
EIA-232F (continued)
• The functional and procedural components are
defined by the V.24 standard
• For example, V.24 defines the function of each
of the pins on the DB-9 connector, as shown on
the Table 4.1 (to p25)
(to p26)
• Table 4.2 shows an example of the procedural
dialog that can be used to create a connection
between two endpoints
– Note the level of complexity needed to establish a fullduplex connection
•
(to p5)
24
EIA-232F (continued)
(to p24)
25
EIA-232F (continued)
(to p24)
26
Universal Serial Bus (USB)
• a newer standard that is much more powerful
than EIA-232F
• The USB interface is a modern standard for
interconnecting a wide range of peripheral
devices to computers
• Supports plug and play
• Can daisy-chain multiple devices
• USB 2.0 can support 480 Mbps (USB 1.0 is only
12 Mbps); USB 3.0
(to p28)
27
Universal Serial Bus (USB)
(continued)
• The USB interface defines all four
components
– The electrical component defines two wires
VBUS and Ground to carry a 5-volt signal,
while the D+ and D- wires carry the data and
signaling information
– The mechanical component precisely defines
the size of four different connectors and uses
only four wires (the metal shell counts as one
more connector)
(to p29)
28
Universal Serial Bus (USB)
(continued)
(to p30)
• Four types of USB connectors
• The functional and procedural components
are fairly complex but are based on the
(to p31)
polled bus
• The computer takes turns asking each
peripheral if it has anything to send
• More on polling near the end of this
chapter
(to p5)
29
Universal Serial Bus (USB)
(continued)
(to p29)
30
Universal Serial Bus (USB)
(continued)
• The functional and procedural components
are fairly complex but are based on the
polled bus
• The computer takes turns asking each
peripheral if it has anything to send
• More on polling near the end of this
chapter
(to p29)
31
FireWire
• Low-cost digital interface
•
(real time connection for PC)
A FireWire connection lets you send data to and from high-bandwidth digital devices such as digital camcorders,
and it's faster than USB
• Capable of supporting transfer speeds of
up to 400 Mbps
• Hot pluggable
• Supports two types of data connections:
– Asynchronous connection
– Isochronous connection
(to p6)
32
SCSI and iSCSI
• SCSI (Small Computer System Interface)
– A technique for interfacing a computer to highspeed devices such as hard disk drives, tape
drives, CDs, and DVDs
– Designed to support devices of a more
permanent nature
• SCSI is a systems interface
– Need SCSI adapter
• iSCSI (Internet SCSI)
– A technique for interfacing
disk storage to a computer via
the Internet
(to p6)
33
InfiniBand and Fibre Channel
• InfiniBand – a serial connection or bus that can
carry multiple channels of data at the same time
– Can support data transfer speeds of 2.5 billion bits
(2.5 gigabits) per second and address thousands of
devices, using both copper wire and fiber-optic cables
– A network of high-speed links and switches
• Fibre Channel – also a serial, high-speed
network that connects a computer to multiple
input/output devices
– Supports data transfer rates up to billions of bits per
second, but can support the interconnection of up to
126 devices only
(to p6)
34
Data Link Connections
– Take place at level 2
– technique used to transmit data on a comm
line
– two methods could be used to transmit data:
• i) Asynchronous transmission (Asych)
• ii) Synchronous transmission (Synch)
• Iii) Isochronous Connections (Isoch)
(to p36)
(to p42)
(to p47)
(to p2)
35
Asynchronous transmission
i) Asynchronous transmission (Asych)
Pattern of data presentation:
– data transmission is sent preceded by an
extra bit, called a start bit, and followed by
one more extra bit called stop bit (start/stop
transmission)
(to p37)
36
Asynchronous transmission
– Eg:
–
110000010
represent a
start bit or
mark bit
A character
representation of
a code system
Stop bit
or space bit
(to p38)
Alternative presentation
(to p40)
37
Asynchronous Connections
(continued)
(to p39)
More example
38
Asynchronous Connections
(continued)
Send the word “ H E L L O”
(to p37)
39
Asynchronous transmission
– Penalty term is used to measure the efficiency
of a code system
– known as transmission efficiency
Eg.
Code No. of bits start/stop total bite Eff.
Baudot
5
2
7
5/7=71.5
ASCII
7
2
9
7/9=77
EBCDIC 8
2
10 8/10=80
(to p41)
40
Asynchronous transmission
– Asyn has a function of character
synchronization, which allows when a start bit
is sensed, the receiver knows that the next n
bits on the line make up a characters
– Without Char Syn, receiver cannot rocog the
first bit of charc, and thus character could not
be interpreted.
– Adv.
Equipment cost is low
– Disadv.
Slow speed, less than 300bps
(to p35)
41
Synchronous transmission
• ii) Synchronous transmission (Synch)
– design for line speed that cannot handle by
Asyn
– its function is that bit Synch is maintained by
clock circuitry in the transmitter and in the
receiver
(to p43)
42
Synchronous transmission
– that is timing generated by the transmitter’s
clock is sent along with data so that the
receiver can keep its clock synchronized with
that of the transmitter throughout a long
transmission
– data is usually sent in a block oriented,
contains special synch character with a
unique bit pattern
– similar the Asych, synch char performs a
function similar to that of start bit
(to p44)
43
Synchronous transmission
– It has 1 to 4 synchronizing “characters” for
each “block” of data; whereas Asych has 2
bits for each character
– Semantic view
– efficiency
(to p45)
(to p46)
44
Synchronous Connections
(continued)
(to p44)
45
Synchronous transmission
– Example: consider a character consists of
0100101
Asynch: 250 char x (7 data + 2 start/stop) = 2250
Synch: (250 + 4 synch char) x 7 bits) = 1778
Thus, Synch is 21% more efficient than Aysnch
– Note: Mostly, host computers adopt Synch
transmission.
(to p35)
46
Isochronous Connections
• A third type of connection defined at the data link
layer used to support real-time applications
• Data must be delivered at just the right speed
(real-time) – not too fast and not too slow
• Typically an isochronous connection must
allocate resources on both ends to maintain
real-time
• USB and Firewire can both support isochronous
• (provide data transmission in a regular period of
time)
(to p35)
47
Terminal-to-Mainframe
Computer Connections
• Two main ways for connections:
(to p49)
– Point-to-point connection – a direct, unshared
connection between a terminal and a
mainframe computer
(to p49)
– Multipoint connection – a shared connection
between multiple terminals and a mainframe
computer
• The mainframe is the primary and the terminals
are the secondaries (how do you draw them
semantically?)
(to p50)
48
Terminal-to-Mainframe
Computer Connections
(continued)
(to p48)
(to p48)
49
Terminal-to-Mainframe
Computer Connections (continued)
•
•
To allow a terminal to transmit data to a
mainframe, the mainframe must poll the
terminal
Two basic forms of polling: roll-call polling and
hub polling (to p51)
1. In roll-call polling, the mainframe polls each terminal
in a round-robin fashion
2. In hub polling, the mainframe polls the first terminal,
and this terminal passes the poll onto the next
terminal (how it works, semantically?)
(to p2)
50
Terminal-to-Mainframe
Computer Connections (continued)
Roll-call pulling
(to p50)
51
Making Computer Connections In
Action
• The back panel of a personal computer
has many different types of connectors, or
connections:
– RS-232 connectors
– USB connectors
– Parallel printer connectors
– Serial port connectors
Layout
(to p53)
52
Making Computer Connections
In Action (continued)
(to p54)
53
Making Computer Connections
In Action (continued)
• 1 and 2 – DIN connectors for keyboard
and mouse
• 3 – USB connectors
• 4 and 6 – DB-9 connectors
• 5 – Parallel port connector (Centronics)
• 7, 8, and 9 – audio connectors
• Will Bluetooth replace these someday?
(to p55)
Solution!
54
Making Computer Connections
In Action (continued)
• A company wants to transfer files that are
typically 700K chars in size
• If an asynchronous connection is used,
each character will have a start bit, a stop
bit, and maybe a parity bit
• 700,000 chars * 11 bits/char (8 bits data +
start + stop + parity) = 7,700,000 bits
(to p56)
55
Making Computer Connections
In Action (continued)
• If a synchronous connection is used,
assume maximum payload size – 1500
bytes
• To transfer a 700K char file requires 467
1500-character (byte) frames
• Each frame will also contain 1-byte
header, 1-byte address, 1-byte control,
and 2-byte checksum, thus 5 bytes
(to p57)
overhead
56
Making Computer Connections
In Action (continued)
• 1500 bytes payload + 5 byte overhead =
1505 byte frames
• 467 frames * 1505 bytes/frame = 716,380
bytes, or 5,731,040 bits
• Significantly less data using synchronous
connection
57