USB gives fast and flexible interface for connecting all kinds of peripherals. USB is playing a key role in fast growing consumer areas like digital imaging, PC telephony, and multimedia games, etc.
Interconnection Standards
AU:
Dec.-06, 07, 08, May-06, 11, 13
• USB gives fast and flexible interface
for connecting all kinds of peripherals.
• USB is playing a key role in fast
growing consumer areas like digital imaging, PC telephony, and multimedia
games, etc.
• The presence of USB in most new PCs and its plug-n-play capability, means that PCs and peripherals (such as CD ROM drives, tape and floppy drives, scanners, printers, video devices, digital cameras, digital speakers, telephones, modems, key boards, mice, digital joysticks and others) will automatically configure and work together, with high degree of reliability, in this exciting new application areas.
• USB opens the
door to new levels of innovation and its use for input devices. There are also
brand new opportunities of all types of peripherals from printers to scanners
to high speed connection such as Ethernet, DSL, cable and satellite
communications.
• USB has advantages that specifically
benefit developers, including the hardware designers who select components and
design the circuits, the PC programmers who write the software that
communicates with USB peripherals, and peripherals programmers who write the
code that resides inside USB peripherals.
USB Features
1. Simple connectivity
USB offers simple connectivity.
2. Simple cables
The USB cable connector are keyed so you
cannot plug them in wrong.
3. One interface for many devices
USB is versatile enough to be usable
with many kinds of peripherals with no need of having a different connector and
protocols for each peripheral. USB supports all kinds of data, from slow mouse
inputs to digitized audio and compresses video.
4. Automatic configuration
When a user connects a USB peripheral to
a powered system, windows automatically detects the peripheral and loads the
appropriate software driver for it. There is no need to locate and run a setup
programme or restart the system before using the peripheral.
5. No user setting
USB peripherals do not have user
selectable settings such as port address and interrupt request (IRQ) lines.
6. Frees hardware resources for other
devices
Using USB for as many peripherals as
possible frees up IRQ lines for the peripherals that do require them.
7. Hot pluggable (Plug-and play)
You can install or remove a peripheral
regardless of the power state.
8. Data transfer rates
USB supports three data transfer rates,
480 Mb/s (high-speed), 12 Mb/s (full-speed) and 1.5 Mb/s (low-speed).
9. Coexistence with IEEE 1394
USB 2.0 and IEEE 1394 offer similar data
rate primarily differ in terms of application focus.
10. Reliability
Reliability of USB results from both the
hardware design and data transfer protocols.
11. Low cost
Even though USB is more complex than earlier
interfaces, its components and cables are inexpensive. A device with a USB
interface is likely to cost the same or less than its equivalent older
interfaces.
12. Low power consumption
Power circuits and code automatically
power down USB peripherals when not in use, yet keep them ready to respond when
needed.
13. Flexibility
USB's four transfer types and three
speed make it feasible for many types of peripherals.
14. Operating system support
Windows 98 was the first Windows
operating system to reliably support USB, and its successors such as Windows
2000 support USB as well. Other computers and operating systems also have USB
support. ON apple's iMac, the only peripherals connectors are USB. Other
Macintoshes also support USB, and support is in progress for Linux, NetBSD, and
FreeBSD.
USB System
• The Fig. 8.11.1 shows the basic
components of USB system. It consists of USB host, USB device and USB cable.
The USB host is a personal computer (PC) and devices are scanner, printer etc.
There will be only one host in the USB system, however there can be 127 devices
in the USB system.
USB Connector
• The Fig. 8.11.2 shows the pin-out of
the USB connector.
• There are two types of USB connectors.
• In either case, there are four signals
as indicated in Table 8.11.1 The 5.0 V and ground signals can be used to power
the device connected on the PCI bus as long as the amount of current does not
exceed 100 mA per device.
• The data signals are biphase signals.
When + data represents 5.0 V the data represents 0 V and vice versa.
USB Data Encoding
Format
• The USB uses NRZI (non-return-to zero,
inverted) data encoding method for transmitting data packets. In this method,
the signal level does not change for the transmission of logic 1. However, it
is inverted for each change to a logic 0. This is illustrated in Fig. 8.11.3.
In this method data bits are always transmitted beginning with the least
significant bit first, followed by subsequent bits.
• To maintain the signal frequency in the
specified range i.e. to achieve synchronization we have to insert a sync bit in
the data stream, if a logic 1 is transmitted for more than six bits in a row.
The process of inserting sync bit is known as bit stuffing.
• The bit stuffing isillustrated in Fig.
8.11.4.Bit stuffing ensures that Digital data
the receiver can maintain
synchronization for long strings of logic 1s.
• The Fig. 8.11.5 shows the flowchart to
generate USB data from the raw digital serial data. (SeeFig. 8.11.5 on next
page.)
8.11.1.5 USB Commands
• USB data is transmitted to particular
receptor with the use of USB commands. •The communication begins with the
transmission of the sync byte (80H).
• It is followed by the packet
identification byte (PID). The PID contains eight bits, but only the rightmost
four bits contain the type of packet. The leftmost four bits of the PID are the
complement form of four rightmost bits.
• For example, if a command is 1001, the
actual PID byte is 0110 1001. The Table 8.11.2 shows the available 4-bit PIDs
and their 8-bit codes. The PIDs are also used as token indicators, as data
indicators, and for handshaking.
USB Packet Format
• The Fig. 8.11.6 shows the formats of
data, token, handshaking and start-of frame packets used on the USB.
• The data packet begins with PID, then
data byte and ends with CRC (cyclic redundancy check) code.
• Packets use two types of CRC codes :
one is a 5-bit CRC and the other (used for data packets) is a 16-bit CRC.
• The 5-bit CRC is generated with the X5
+ X2 +1 polynomial.
• The 16-bit CRC is generated with the X16 + X15
+ X2 + 1 polynomial.
• The USB uses the ACK (acknowledge) and
NAK (Not acknowledge) tokens to co-ordinate the transfer of data packets
between the host system (host is a PC or other computer that contain two
components: controller and a root hub). (A hub is device that contains one or
more connecters or internal connections to USB devices along with the hardware
to enable communicating with each device and the USB device.)
• Once a data packet is transferred from
the host to the USB device, the USB device either transmits and ACK or a NAK
token back to the host.
• If the data and CRC are received
without error, the ACK is sent; otherwise, the NAK is sent.
• If the host receives a NAK token, it
retransmits the data packet until the receiver receives it without error.
• This method of data transfer is known
as stop and wait flow control. In this method, the host has to wait for the
client to send an ACK or NAK before transferring additional data packets.
Data Transfer
Types
• The USB is designed to handle many
types of peripherals with varying requirements for transfer rate, response
time, and error correcting. There are four types of data transfers each handle
different needs and a peripheral can support the transfer types that are best
suited for its purpose.
1. Control transfer
• Control transfers are the only type
with functions defined by the USB specification. These transfers enable the
host to read and select configurations and other settings on the devices being
enumerated. Control transfers may also send custom requests that send and
receive blocks of data for any purpose. All USB devices must support control
transfers.
• This data transfer exchanges
configuration, setup, and command information between the device and host. CRCS
check the data and initiate retransmissions when needed to guarantee the
correctness of these packets.
• Control transfers use message pipes. In
a message pipe, each transfer begins with a Setup transaction containing a
request. To complete the transfer, the host and device may exchange data and
status information, or the device may just send status information. There is
always at least one transaction that sends information in each direction.
• If the request is one that the device
supports, it takes the requested action. A device may also respond with a code
that indicates that it does not support the request.
2. Bulk transfer
• Bulk transfers are intended for
situations where the rate of transfer isn't critical, such as sending a file to
a printer or receiving data from a scanner. In these cases quick transfers are
nice, but the data can wait if necessary. If the bus is very busy with other
transfers that have guaranteed transfer rates, bulk transfers must wait, but if
the bus is idle, bulk transfers are very fast. Only full-speed devices can do
bulk transfers. Devices are not required to support bulk transfers, but a
specific I device class might require it.
• This data transfer moves large amounts
of data when timely delivery is not critical. Typical applications include
printers and scanners. Bulk transfers are fillers, claiming unuse USB bandwidth
when nothing more important is going on. CRCs protect these packets.
3. Interrupt transfer
• Interrupt transfers are for devices
that must receive the host's or device's attention quickly. Other than control
transfers, interrupt transfers are the only way that low speed devices can
transfer data. A keyboard or mouse can use interrupt transfers to send keypress
or mouse movement data. Both full and low speed devices can do interrupt
transfers. Devices aren't required to support interrupt transfers, but a
specific device class might require it.
• This data transfers, though not
interrupt in the CPU diverting sense, poll devices to see if they need service.
Peripherals exchanging small amounts of data that need immediate attention
(such as mice and keyboards) use interrupt transfers. Error checking validates
the data.
4. Isochronous transfer (USB for audio
devices)
• Isochronous transfers are for devices
that must transfer data at a constant rate, such as audio files to be played in
real time, or other data that needs a guaranteed delivery rate or time. This is
the only transfer type that doesn't support automatic re-transmitting of data
received with errors, so occasional errors must be acceptable. Only full speed
devices can do isochronous transfers. Devices are not
required to support isochronous
transfers, but a specific device class might require
it.
• This data transfer handling trimming
data like an audio or video device. It is time sensitive information so within
limitation it has guaranteed access to a USB bus. No error checking occurs so
the system must tolerate occasional scrambled bytes. Above three transfers
namely Bulk transfer, Interrupt transfer, and Isochronous transfer use Stream
Pipes.
• In a stream pipe, the data has no
format defined by the USB specification. The receiving device just accepts
whatever arrives. The device firmware or host software can then process the
data in whatever way is appropriate for the application. Of course, even with
stream data, the sending and receiving devices will need to agree on some type
of format.
Review Questions
1. Write short note on advantages of USB over older I/O bus architectures. AU: Dec.-06, Marks 8
2. Write notes on USB. AU: Dec.-07,
Marks 8
3. Explain the protocols of USB. AU
May-11, Marks 8
4. Discuss the salient features of the
USB operation. AU May-06, Marks 6
5. What are the advantages of USB
interface? AU: Dec.-08, May-13, Marks 2
• A serial advanced technology attachment
(serial ATA, SATA or S-ATA) is a computer bus interface that connects host bus
adapters with mass storage devices like optical drives and hard drives.
• As its name implies, SATA is based on
serial signaling technology, where data is transferred as a sequence of
individual bits
• This interface is commonly used to
connect hard disk drives to a host system such as a computer motherboard.
• The first version of SATA communicated
at 150 megabytes per second (MBps). The standard was soon upgraded to 300 MBps
in 2004 and 600 MBps in 2009-estimated to be sufficient to accommodate 10 years
of advances in device throughput.
Features
• Low Voltage Requirement: SATA
operates on 500 mV (0.5 V) peak-to-peak signaling. This help in promoting a
much low interference and crosstalk between conductors.
• Hot Plugging:
This feature helps users to change or remove storage devices even when the
computer is running.
• Staggered Spin-Up: Allows
sequential hard disk drive startup, which helps even out power load
distribution during system booting.
• Native Command Queuing (NCQ):
Usually, the commands reach a disk for reading or writing from different
locations on the disk. When the commands are carried out based on the order in
which they appear, a substantial amount of mechanical overhead is generated
because of the constant repositioning of the read/write head. SATA II drives
use an algorithm to identify the most effective order to carry out commands.
This helps to reduce mechanical overhead and improve performance.
• Port Multipliers:
Allows the connection of up to 15 drives to a SATA controller. This facilitates
the building of disk enclosures.
• Port Selectors: Facilitates redundancy for two hosts connected to a single drive, allowing the second host to take over in the event of a primary host failure.
• Simplified
construction: PATA cables had 40-pin/80-wire ribbon cable. This was complex
in structure. In comparison, SATA had a single 7 pin data cable and a 15 pin
power cable. This cable resulted in a higher signaling rate, which translates
to faster throughput of data.
• Differential Signaling:
SATA uses differential signaling. Differential signaling is a technology which
uses two adjacent wires to simultaneously the in-phase and out-of-phase
signals. Thus, it is possible to transfer high-speed data with low operating
voltage and low power consumption by detecting the phase difference between the
two signals at the receiver's end.
• High data transfer rate:
SATA has a high data transfer rate of 150/300/600 MBS/second. This capability
of SATA allows for faster program loading, better picture loading and fast
document loading.
• Large Cable Length: SATA
cable can be of length up to 1 meter, whereas PATA cable can only have a length
of maximum 18 inches.
Operating Modes
• SATA operates on two modes :
• IDE mode:
IDE stands for Integrated Drive Electronics. This mode is used to provide
backward compatibility with older hardware, which runs on PATA, at low
performance.
• AHCI mode:
AHCI is an abbreviation for Advanced Host Controller Interface. AHCI is a
high-performance mode that also provides support for hot-swapping. •The Serial
ATA [SATA] bus is defined over two separate connectors, one connector for the
data lines and one for the power lines.
SATA Data pinout
SATA Power pinout
Review Questions
1. Write a short note on SATA.
2. List the features of SATA.
Digital Principles and Computer Organization: Unit V: Memory and I/O : Tag: : Memory and I/O - Digital Principles and Computer Organization - Interconnection Standards
Digital Principles and Computer Organization
CS3351 3rd Semester CSE Dept | 2021 Regulation | 3rd Semester CSE Dept 2021 Regulation