SlideShare a Scribd company logo
Communication Hardware &
Protocols
Prof. Anish Goel
Embedded Systems
Communications
Embedded Systems Prof.Anish Goel2
Serial Communications
Embedded Systems Prof.Anish Goel3
Asynchronous Serial (RS‐232)
Embedded Systems Prof.Anish Goel4
RS232 Voltage levels
Embedded Systems Prof.Anish Goel5
RS232 – Handshaking
Embedded Systems Prof.Anish Goel6
Serial Peripheral Interface
Embedded Systems Prof.Anish Goel7
SPI and the clock
Embedded Systems Prof.Anish Goel8
SPI and the clock
Embedded Systems Prof.Anish Goel9
I2C
Embedded Systems Prof.Anish Goel10
I2C Write a Single Byte
Embedded Systems Prof.Anish Goel11
Other Features
Embedded Systems Prof.Anish Goel12
RS-485
Embedded Systems Prof.Anish Goel13
RS232 is an interface to connect one DTE, data terminal equipment to one DCE, data
communication equipment at a maximum speed of 20 kbps with a maximum cable
length of 50 feet.
This was sufficient in the old days where almost all computer equipment were
connected using modems, but soon after people started to look for interfaces capable
of one or more of the following:
•Connect DTE's directly without the need of modems
•Connect several DTE's in a network structure
•Ability to communicate over longer distances
•Ability to communicate at faster communication rates
RS485 is the most versatile communication standard in the standard series defined by the
EIA, as it performs well on all four points.That is why RS485 is currently a widely used
communication interface in data acquisition and control applications where multiple
nodes communicate with each other.
Differential signals with RS485:
Longer distances and higher bit rates
Embedded Systems Prof.Anish Goel14
•Main problems with RS232 is the lack of immunity for noise on the signal lines.
•The transmitter and receiver compare the voltages of the data- and handshake lines
with one common zero line.
•Shifts in the ground level can have disastrous effects.
•Therefore the trigger level of the RS232 interface is set relatively high at ±3Volt.
•Noise is easily picked up and limits both the maximum distance and communication
speed.
•With RS485 on the contrary there is no such thing as a common zero as a signal
reference.
•Several volts difference in the ground level of the RS485 transmitter and receiver
does not cause any problems.
•The RS485 signals are floating and each signal is transmitted over a Sig+ line and a Sig-
line.
•The RS485 receiver compares the voltage difference between both lines, instead of
the absolute voltage level on a signal line.
•This works well and prevents the existence of ground loops, a common source of
communication problems.
•The best results are achieved if the Sig+ and Sig- lines are twisted.
Noise in straight and twisted pair cables
Embedded Systems Prof.Anish Goel15
•Noise is generated by magnetic fields from the
environment.
•The picture shows the magnetic field lines and
the noise current in the RS485 data lines that is
the result of that magnetic field.
•In the straight cable, all noise current is flowing in
the same direction, practically generating a looping
current just like in an ordinary transformer.
•When the cable is twisted, we see that in some
parts of the signal lines the direction of the noise
current is the opposite from the current in other
parts of the cable.
•Because of this, the resulting noise current is
many factors lower than with an ordinary straight
cable. Shielding—which is a common method to
prevent noise in RS232 lines—tries to keep hostile
magnetic fields away from the signal lines.
Embedded Systems Prof.Anish Goel16
RS 485 Advantages
•Twisted pairs in RS485 communication however adds immunity which is a much
better way to fight noise.
•The magnetic fields are allowed to pass, but do no harm.
•If high noise immunity is needed, often a combination of twisting and shielding is
used as for example in STP, shielded twisted pair and FTP, foiled twisted pair
networking cables.
•Differential signals and twisting allows RS485 to communicate over much longer
communication distances than achievable with RS232. With RS485 communication
distances of 1200 m are possible.
•Differential signal lines also allow higher bit rates than possible with non-differential
connections. Therefore RS485 can overcome the practical communication speed limit
of RS232. Currently RS485 drivers are produced that can achieve a bit rate of
35 mbps.
Embedded Systems Prof.Anish Goel17
Characteristics of RS232, RS422, RS423
and RS485
Embedded Systems Prof.Anish Goel18
CAN
A Controller Area Network (CAN) bus is a high-integrity serial bus system for
networking intelligent devices. CAN busses and devices are common components
in automotive and industrial systems.
Automotive Applications
Embedded Systems Prof.Anish Goel19
Benefits of CAN
• Lower cost from reduced wiring compared to two wire, point-to-point
wiring
• Highly robust protocol
– Built-in determinism
– Fault tolerance
– Reliable—More than a decade of use in the automotive industry
CAN Specifications
• CAN data (up to 8 bytes in a frame)
• Maximum 1 Mbaud/s
• 40 Meters at 1 Mbaud/s
• 6 km at 10 kbaud/s
•Theoretical maximum of 2,032 nodes per bus
– Practical limit is approximately 100 nodes due to transceiver
– Most buses use 3–10 nodes
• Data fields—Arbitration ID (11 bit or 29 bit)
– Indicates message priority
Embedded Systems Prof.Anish Goel20
CAN Frame
•CAN devices send data across the CAN Network on packets called frames.
•A typical CAN frame contains an arbitration ID, a data field, a remote frame, an
error frame, and an overload frame.
Embedded Systems Prof.Anish Goel21
CAN Arbitration
The arbitration ID determines the priority of the messages on the bus. If
multiple nodes try to transmit a message onto the CAN bus at the same time,
the node with the highest priority (lowest arbitration ID) automatically gets
bus access. Nodes with a lower priority must wait until the bus becomes
available before trying to transmit again.The waiting devices wait until the
end of the frame section is detected.
Embedded Systems Prof.Anish Goel22
Data Field
•The data field contains the actual data being transmitted.
•The CAN protocol supports two data field formats as defined in the Bosch Version
2.0 specifications, the essential difference being in the length of the arbitration
•ID.
•In the standard frame format (also known as 2.0A), the length of the ID is 11 bits.
•In the extended frame format (also known as 2.0B), the length of the ID is 29 bits.
Embedded Systems Prof.Anish Goel23
Introduction to USB
General Introduction
The Universal Serial Bus (USB) is a specification
developed by Compaq, Intel, Microsoft and NEC,
joined later by Hewlett-Packard, Lucent and Philips.
These companies formed the USB Implementers
Forum, Inc as a non-profit corporation to publish the
specifications and organise further development in
USB.
The aim of the USB-IF was to find a solution to the
mixture of connection methods to the PC, in use
at the time. We had serial ports, parallel ports,
keyboard and mouse connections, joystick ports,
midi ports and so on. And none of these satisfied
the basic requirements of plug-and-play.
Additionally many of these ports made use of a
limited pool of PC resources, such as Hardware
Interrupts,and DMA channels.
Embedded Systems Prof.Anish Goel24
Data Speeds
The USB specification defines three data
speeds, shown to the right. These speeds are
the fundamental clocking rates of the system,
and as such do not represent possible
throughput, which will always be lower as the
result of the protocol overheads.
Low Speed
This was intended for cheap, low data rate devices like mice. The low speed
captive cable is thinner and more flexible than that required for full and high
speed.
Full Speed
This was originally specified for all other devices.
High Speed
The high speed additions to the specification were introduced in USB 2.0 as a
response to the higher speed of Firewire.
Embedded Systems Prof.Anish Goel25
Architecture
The USB is based on a so-called 'tiered star topology' in which there is a single host
controller and up to 127 'slave' devices.
The host controller is connected to a hub, integrated within the PC, which allows a
number of attachment points (often loosely referred to as ports).
A further hub may be plugged into each of these attachment points, and so on.
However there are limitations on this expansion.
As stated above a maximum of 127 devices (including hubs) may be connected.
This is because the address field in a packet is 7 bits long, and the address 0 cannot be
used as it has special significance. (In most systems the bus would be running out of
bandwidth, or other resources, long before the 127 devices was reached.)
A device can be plugged into a hub, and that hub can be plugged into another hub and
so on. However the maximum number of tiers permitted is six.
The length of any cable is limited to 5 metres.This limitation is expressed in the
specification in terms of cable delays etc, but 5 metres can be taken as the practical
consequence of the specification.
Embedded Systems Prof.Anish Goel26
USB
This means that a device cannot be further
than 30 metres from the PC, and even to
achieve that will involve 5 external hubs, of
which at least 2 will need to be self-powered.
So the USB is intended as a bus for devices
near to the PC. For applications requiring
distance from the PC, another form of
connection is needed, such as Ethernet.
Embedded Systems Prof.Anish Goel27
Host is Master
•All communications on this bus are initiated by the host.
•This means, for example, that there can be no communication directly between USB
devices.
•A device cannot initiate a transfer, but must wait to be asked to transfer data by the host.
The only exception to this is when a device has been put into 'suspend' (a low power
state) by the host then the device can signal a 'remote wakeup'.

More Related Content

PPTX
Embedded System
PPTX
Embedded networking
PDF
I2C-SPI-UART Basics || Embedded System || Hariharan K
PPT
8051 microcontroller lecture ppt by Tarun Khaneja ( 9034406598 )
PPTX
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I Core of Embedded Systems
PPTX
EC8791 UML-model train controller
PDF
lesson2 - Nodemcu course - NodeMCU dev Board
PPTX
Introducion to MSP430 Microcontroller.pptx
Embedded System
Embedded networking
I2C-SPI-UART Basics || Embedded System || Hariharan K
8051 microcontroller lecture ppt by Tarun Khaneja ( 9034406598 )
SYBSC IT SEM IV EMBEDDED SYSTEMS UNIT I Core of Embedded Systems
EC8791 UML-model train controller
lesson2 - Nodemcu course - NodeMCU dev Board
Introducion to MSP430 Microcontroller.pptx

What's hot (20)

PPTX
ARM Processors
DOCX
Lambda design rule
PDF
ARM CORTEX M3 PPT
DOCX
Hardware-Software Codesign
PPT
Memory & I/O interfacing
PPTX
Xilinx 4000 series
PPTX
Microcontroller 8096
PDF
Arduino- Serial communication
PDF
DAC Interfacing with 8051.pdf
PPT
Mobile Radio Propagations
PPTX
Serial Communication in 8051
PDF
Multiple Access
PPTX
8255 PPI
PDF
Introduction to Embedded Architecture
PDF
Keypad Interfacing with 8051 Microcontroller
PPTX
Ec8791 arm 9 processor
PPT
Spread spectrum modulation
PPTX
Chapter 3 Charateristics and Quality Attributes of Embedded System
PPTX
Ethernet Computer network
ARM Processors
Lambda design rule
ARM CORTEX M3 PPT
Hardware-Software Codesign
Memory & I/O interfacing
Xilinx 4000 series
Microcontroller 8096
Arduino- Serial communication
DAC Interfacing with 8051.pdf
Mobile Radio Propagations
Serial Communication in 8051
Multiple Access
8255 PPI
Introduction to Embedded Architecture
Keypad Interfacing with 8051 Microcontroller
Ec8791 arm 9 processor
Spread spectrum modulation
Chapter 3 Charateristics and Quality Attributes of Embedded System
Ethernet Computer network
Ad

Viewers also liked (20)

PPT
Serial Communication
DOCX
8086 MICROPROCESSOR
PPTX
Flag registers, addressing modes, instruction set
PPTX
Operand and Opcode | Computer Science
PPTX
Flags registor of 8086 processor
PPTX
Serial data transfer
PPTX
PDF
Embedded Systems in Automotive
PPTX
Controller Area Network (Basic Level Presentation)
PPT
CAN (Controller Area Network) Bus Protocol
PPTX
DC GENERATOR CHARACTERISTICS
PPTX
Automotive lighting - Led road lighting
PDF
PLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
PPT
Tower crane Basics
PPT
Ppt local tracking and gps
DOCX
Plc & scada report 6
PPTX
Electro magnetic interference and compatibility(ECM,ECI)
PPTX
DC GENERATOR
PDF
Emi emc-pdf
Serial Communication
8086 MICROPROCESSOR
Flag registers, addressing modes, instruction set
Operand and Opcode | Computer Science
Flags registor of 8086 processor
Serial data transfer
Embedded Systems in Automotive
Controller Area Network (Basic Level Presentation)
CAN (Controller Area Network) Bus Protocol
DC GENERATOR CHARACTERISTICS
Automotive lighting - Led road lighting
PLC, DCS and PLC vs DCS Presentation by Jitender Singh Shekhawat
Tower crane Basics
Ppt local tracking and gps
Plc & scada report 6
Electro magnetic interference and compatibility(ECM,ECI)
DC GENERATOR
Emi emc-pdf
Ad

Similar to Serial Communication Interfaces (20)

PPTX
Serial buses
PDF
Communication protocols - Embedded Systems
PDF
RS 232 Notes for Embedded systems and IOT
PPTX
Chapter 3 esy
PDF
Industrial Automation notes_unit2_part3_.pdf
PPT
Communication Interface of The Embedded Systems
PDF
Asynchronous Serial Communication and standards
PPT
serial.ppt
PPT
serial.ppt
PDF
3. Arduino Wired Communication Protocols.pdf
PDF
Serial port in an embedded system types and uses
PPT
Serial and parallel bus standars RS232C and IEEE488.ppt
PPTX
Serial Busses.pptx
PPT
Usb Overview
DOCX
Project_intership
PPTX
Usb protocol
PDF
uart protocol about universal asynchronous transmission
PPT
menjelaskan tentang hubungan kabel Rs232-485
PDF
EJ5I Embedded system chapter 2 of diploma Chapter 3.pdf
PPTX
Universal serial bus
Serial buses
Communication protocols - Embedded Systems
RS 232 Notes for Embedded systems and IOT
Chapter 3 esy
Industrial Automation notes_unit2_part3_.pdf
Communication Interface of The Embedded Systems
Asynchronous Serial Communication and standards
serial.ppt
serial.ppt
3. Arduino Wired Communication Protocols.pdf
Serial port in an embedded system types and uses
Serial and parallel bus standars RS232C and IEEE488.ppt
Serial Busses.pptx
Usb Overview
Project_intership
Usb protocol
uart protocol about universal asynchronous transmission
menjelaskan tentang hubungan kabel Rs232-485
EJ5I Embedded system chapter 2 of diploma Chapter 3.pdf
Universal serial bus

More from anishgoel (20)

PDF
Computer Organization
PDF
Learning vhdl by examples
PDF
Dot matrix module interface wit Raspberry Pi
PDF
Input interface with Raspberry pi
PDF
Learning Python for Raspberry Pi
PDF
Raspberry Pi
PDF
learning vhdl by examples
PDF
Digital System Design Basics
PPTX
digital design of communication systems
PPTX
Rtos concepts
PDF
8051 Microcontroller Timer
PDF
8051 Microcontroller I/O ports
PDF
Embedded systems ppt iv part d
PDF
Embedded systems ppt iv part c
PDF
Embedded systems ppt iv part b
PDF
Embedded systems ppt ii
PDF
Embedded systems ppt iii
PDF
Embedded systems ppt iv part a
PDF
Embedded systems ppt i
PDF
Cpld fpga
Computer Organization
Learning vhdl by examples
Dot matrix module interface wit Raspberry Pi
Input interface with Raspberry pi
Learning Python for Raspberry Pi
Raspberry Pi
learning vhdl by examples
Digital System Design Basics
digital design of communication systems
Rtos concepts
8051 Microcontroller Timer
8051 Microcontroller I/O ports
Embedded systems ppt iv part d
Embedded systems ppt iv part c
Embedded systems ppt iv part b
Embedded systems ppt ii
Embedded systems ppt iii
Embedded systems ppt iv part a
Embedded systems ppt i
Cpld fpga

Recently uploaded (20)

PDF
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
PPTX
Foundation to blockchain - A guide to Blockchain Tech
PPTX
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
PPTX
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
PDF
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
DOCX
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
PDF
Structs to JSON How Go Powers REST APIs.pdf
PDF
Operating System & Kernel Study Guide-1 - converted.pdf
PDF
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PPTX
OOP with Java - Java Introduction (Basics)
PPTX
Lecture Notes Electrical Wiring System Components
PDF
Model Code of Practice - Construction Work - 21102022 .pdf
PPTX
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
PPTX
Strings in CPP - Strings in C++ are sequences of characters used to store and...
PDF
composite construction of structures.pdf
PPTX
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
PPTX
additive manufacturing of ss316l using mig welding
PPTX
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
SM_6th-Sem__Cse_Internet-of-Things.pdf IOT
Foundation to blockchain - A guide to Blockchain Tech
CARTOGRAPHY AND GEOINFORMATION VISUALIZATION chapter1 NPTE (2).pptx
KTU 2019 -S7-MCN 401 MODULE 2-VINAY.pptx
July 2025 - Top 10 Read Articles in International Journal of Software Enginee...
ASol_English-Language-Literature-Set-1-27-02-2023-converted.docx
Structs to JSON How Go Powers REST APIs.pdf
Operating System & Kernel Study Guide-1 - converted.pdf
Mohammad Mahdi Farshadian CV - Prospective PhD Student 2026
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
OOP with Java - Java Introduction (Basics)
Lecture Notes Electrical Wiring System Components
Model Code of Practice - Construction Work - 21102022 .pdf
M Tech Sem 1 Civil Engineering Environmental Sciences.pptx
Strings in CPP - Strings in C++ are sequences of characters used to store and...
composite construction of structures.pdf
Recipes for Real Time Voice AI WebRTC, SLMs and Open Source Software.pptx
additive manufacturing of ss316l using mig welding
Engineering Ethics, Safety and Environment [Autosaved] (1).pptx
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...

Serial Communication Interfaces

  • 1. Communication Hardware & Protocols Prof. Anish Goel Embedded Systems
  • 4. Asynchronous Serial (RS‐232) Embedded Systems Prof.Anish Goel4
  • 5. RS232 Voltage levels Embedded Systems Prof.Anish Goel5
  • 6. RS232 – Handshaking Embedded Systems Prof.Anish Goel6
  • 7. Serial Peripheral Interface Embedded Systems Prof.Anish Goel7
  • 8. SPI and the clock Embedded Systems Prof.Anish Goel8
  • 9. SPI and the clock Embedded Systems Prof.Anish Goel9
  • 11. I2C Write a Single Byte Embedded Systems Prof.Anish Goel11
  • 12. Other Features Embedded Systems Prof.Anish Goel12
  • 13. RS-485 Embedded Systems Prof.Anish Goel13 RS232 is an interface to connect one DTE, data terminal equipment to one DCE, data communication equipment at a maximum speed of 20 kbps with a maximum cable length of 50 feet. This was sufficient in the old days where almost all computer equipment were connected using modems, but soon after people started to look for interfaces capable of one or more of the following: •Connect DTE's directly without the need of modems •Connect several DTE's in a network structure •Ability to communicate over longer distances •Ability to communicate at faster communication rates RS485 is the most versatile communication standard in the standard series defined by the EIA, as it performs well on all four points.That is why RS485 is currently a widely used communication interface in data acquisition and control applications where multiple nodes communicate with each other.
  • 14. Differential signals with RS485: Longer distances and higher bit rates Embedded Systems Prof.Anish Goel14 •Main problems with RS232 is the lack of immunity for noise on the signal lines. •The transmitter and receiver compare the voltages of the data- and handshake lines with one common zero line. •Shifts in the ground level can have disastrous effects. •Therefore the trigger level of the RS232 interface is set relatively high at ±3Volt. •Noise is easily picked up and limits both the maximum distance and communication speed. •With RS485 on the contrary there is no such thing as a common zero as a signal reference. •Several volts difference in the ground level of the RS485 transmitter and receiver does not cause any problems. •The RS485 signals are floating and each signal is transmitted over a Sig+ line and a Sig- line. •The RS485 receiver compares the voltage difference between both lines, instead of the absolute voltage level on a signal line. •This works well and prevents the existence of ground loops, a common source of communication problems. •The best results are achieved if the Sig+ and Sig- lines are twisted.
  • 15. Noise in straight and twisted pair cables Embedded Systems Prof.Anish Goel15 •Noise is generated by magnetic fields from the environment. •The picture shows the magnetic field lines and the noise current in the RS485 data lines that is the result of that magnetic field. •In the straight cable, all noise current is flowing in the same direction, practically generating a looping current just like in an ordinary transformer. •When the cable is twisted, we see that in some parts of the signal lines the direction of the noise current is the opposite from the current in other parts of the cable. •Because of this, the resulting noise current is many factors lower than with an ordinary straight cable. Shielding—which is a common method to prevent noise in RS232 lines—tries to keep hostile magnetic fields away from the signal lines.
  • 16. Embedded Systems Prof.Anish Goel16 RS 485 Advantages •Twisted pairs in RS485 communication however adds immunity which is a much better way to fight noise. •The magnetic fields are allowed to pass, but do no harm. •If high noise immunity is needed, often a combination of twisting and shielding is used as for example in STP, shielded twisted pair and FTP, foiled twisted pair networking cables. •Differential signals and twisting allows RS485 to communicate over much longer communication distances than achievable with RS232. With RS485 communication distances of 1200 m are possible. •Differential signal lines also allow higher bit rates than possible with non-differential connections. Therefore RS485 can overcome the practical communication speed limit of RS232. Currently RS485 drivers are produced that can achieve a bit rate of 35 mbps.
  • 17. Embedded Systems Prof.Anish Goel17 Characteristics of RS232, RS422, RS423 and RS485
  • 18. Embedded Systems Prof.Anish Goel18 CAN A Controller Area Network (CAN) bus is a high-integrity serial bus system for networking intelligent devices. CAN busses and devices are common components in automotive and industrial systems. Automotive Applications
  • 19. Embedded Systems Prof.Anish Goel19 Benefits of CAN • Lower cost from reduced wiring compared to two wire, point-to-point wiring • Highly robust protocol – Built-in determinism – Fault tolerance – Reliable—More than a decade of use in the automotive industry CAN Specifications • CAN data (up to 8 bytes in a frame) • Maximum 1 Mbaud/s • 40 Meters at 1 Mbaud/s • 6 km at 10 kbaud/s •Theoretical maximum of 2,032 nodes per bus – Practical limit is approximately 100 nodes due to transceiver – Most buses use 3–10 nodes • Data fields—Arbitration ID (11 bit or 29 bit) – Indicates message priority
  • 20. Embedded Systems Prof.Anish Goel20 CAN Frame •CAN devices send data across the CAN Network on packets called frames. •A typical CAN frame contains an arbitration ID, a data field, a remote frame, an error frame, and an overload frame.
  • 21. Embedded Systems Prof.Anish Goel21 CAN Arbitration The arbitration ID determines the priority of the messages on the bus. If multiple nodes try to transmit a message onto the CAN bus at the same time, the node with the highest priority (lowest arbitration ID) automatically gets bus access. Nodes with a lower priority must wait until the bus becomes available before trying to transmit again.The waiting devices wait until the end of the frame section is detected.
  • 22. Embedded Systems Prof.Anish Goel22 Data Field •The data field contains the actual data being transmitted. •The CAN protocol supports two data field formats as defined in the Bosch Version 2.0 specifications, the essential difference being in the length of the arbitration •ID. •In the standard frame format (also known as 2.0A), the length of the ID is 11 bits. •In the extended frame format (also known as 2.0B), the length of the ID is 29 bits.
  • 23. Embedded Systems Prof.Anish Goel23 Introduction to USB General Introduction The Universal Serial Bus (USB) is a specification developed by Compaq, Intel, Microsoft and NEC, joined later by Hewlett-Packard, Lucent and Philips. These companies formed the USB Implementers Forum, Inc as a non-profit corporation to publish the specifications and organise further development in USB. The aim of the USB-IF was to find a solution to the mixture of connection methods to the PC, in use at the time. We had serial ports, parallel ports, keyboard and mouse connections, joystick ports, midi ports and so on. And none of these satisfied the basic requirements of plug-and-play. Additionally many of these ports made use of a limited pool of PC resources, such as Hardware Interrupts,and DMA channels.
  • 24. Embedded Systems Prof.Anish Goel24 Data Speeds The USB specification defines three data speeds, shown to the right. These speeds are the fundamental clocking rates of the system, and as such do not represent possible throughput, which will always be lower as the result of the protocol overheads. Low Speed This was intended for cheap, low data rate devices like mice. The low speed captive cable is thinner and more flexible than that required for full and high speed. Full Speed This was originally specified for all other devices. High Speed The high speed additions to the specification were introduced in USB 2.0 as a response to the higher speed of Firewire.
  • 25. Embedded Systems Prof.Anish Goel25 Architecture The USB is based on a so-called 'tiered star topology' in which there is a single host controller and up to 127 'slave' devices. The host controller is connected to a hub, integrated within the PC, which allows a number of attachment points (often loosely referred to as ports). A further hub may be plugged into each of these attachment points, and so on. However there are limitations on this expansion. As stated above a maximum of 127 devices (including hubs) may be connected. This is because the address field in a packet is 7 bits long, and the address 0 cannot be used as it has special significance. (In most systems the bus would be running out of bandwidth, or other resources, long before the 127 devices was reached.) A device can be plugged into a hub, and that hub can be plugged into another hub and so on. However the maximum number of tiers permitted is six. The length of any cable is limited to 5 metres.This limitation is expressed in the specification in terms of cable delays etc, but 5 metres can be taken as the practical consequence of the specification.
  • 26. Embedded Systems Prof.Anish Goel26 USB This means that a device cannot be further than 30 metres from the PC, and even to achieve that will involve 5 external hubs, of which at least 2 will need to be self-powered. So the USB is intended as a bus for devices near to the PC. For applications requiring distance from the PC, another form of connection is needed, such as Ethernet.
  • 27. Embedded Systems Prof.Anish Goel27 Host is Master •All communications on this bus are initiated by the host. •This means, for example, that there can be no communication directly between USB devices. •A device cannot initiate a transfer, but must wait to be asked to transfer data by the host. The only exception to this is when a device has been put into 'suspend' (a low power state) by the host then the device can signal a 'remote wakeup'.