+ All Categories
Home > Documents > Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Date post: 26-Dec-2015
Category:
Upload: jeremy-skinner
View: 217 times
Download: 2 times
Share this document with a friend
Popular Tags:
19
Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.
Transcript
Page 3: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Topology

Three Device Types

Host Only one per system

Function Any device that

connects to a host

Hub Self Powered Bus Powered

Peripheral Device HUB

Peripheral Device

Peripheral Device

Peripheral Device

HUB

Peripheral Device

Peripheral Device

Peripheral Device

HUB

Peripheral Device

Peripheral Device

Peripheral Device

USB CablePort Port

USB

HUB

USB

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 4: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

On-The-GoUSB

Allows two USB devices to talk to each other

without a PC acting as host.

DRD (Dual Role Device).

Functions as both Device and Host

Limited Host capabilities

Unique mini-AB receptacle.

Common applications Cell phones MP3 players PDA

OTG

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 5: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Four kinds

Control

Interrupt

Bulk

Isochronous

Direction is from the host perspective IN: Data sent to host OUT: Data received from host

Endpoint FIFO size determines transfer rate

EndpointsUSB a uniquely addressable portion of a USB device that is

either a source or sink of info in a communications flow.

Bidirectional

Unidirectional

Unidirectional

Unidirectional

Fixed at Zero (0)

IN only

Separate Send/Receive Endpoints

Separate Send/Receive Endpoints

Direction Endpoint Notes

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 6: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Quiz1

PROPERTIES

On passing, 'Finish' button: Goes to Next SlideOn failing, 'Finish' button: Goes to SlideAllow user to leave quiz: At any timeUser may view slides after quiz: After passing quizUser may attempt quiz: Unlimited times

Page 7: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Control Transfers

Intended to support configuration, command and

status operations between the software on the host

and the device

Required for all USB function devices

Bidirectional

Interrupt Transfers

Intended for devices that send and receive small

amounts of data infrequently or in an asynchronous

time frame

Full speed up to 64 bytes/packet

Data is ACK’ed (error correcting)

Transfer TypesUSB

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 8: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Transfer TypesUSB Bulk Transfers

Transfer large amounts of non-time sensitive data,

and that can use any available bandwidth

Data is ACK’ed (error correcting)

Not Guaranteed for latency

Transfer time dependent on Bus activity

Isochronous transfers

Transfer data at guaranteed time intervals

Example – Audio/video streaming

Guaranteed bus bandwidth

Data is not ACK’ed (not error correcting)

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 9: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Defined by USB Implementers Forum

Group of devices or interfaces with similar

attributes or services

Examples of commonly used classes

MSC (Mass Storage Class)

HID (Human Interface Device)

Other important classes

Audio, Video

Vendor Specific

ClassesUSB

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 10: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

EnumerationUSB

Control Endpoint

Endpoint 0(EP0)

Endpoint 3(EP3)

Interrupt IN Endpoint

HIDDriver

Request forDevice Descriptor

Request for Interface Descriptor

Request for Configuration Descriptor

Request for Report Descriptor

Reply with Configuration Descriptor

Reply with Interface Descriptor

Reply with Endpoint Descriptor

Reply with Report Descriptor

CONTROL pipe

Reply with Device Descriptor

Request for Endpoint Descriptor

INTERRUPT-IN pipe

© 2010 Renesas Electronics America Inc. All rights reserved.

* 6th Descriptor = String Descriptor

Page 11: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Quiz2

PROPERTIES

On passing, 'Finish' button: Goes to Next SlideOn failing, 'Finish' button: Goes to SlideAllow user to leave quiz: At any timeUser may view slides after quiz: After passing quizUser may attempt quiz: Unlimited times

Page 12: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Start of Frame Keyboard Mouse

USBSpeakers

Bus Management Printer, Scanner and bulk transfers

ControlInterruptand/orcontrol Isochronous

ControlBulk

FrameUSB

1 ms or 0.125 ms

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 13: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

USB Transfer on the protocol analyzer

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 14: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Quiz3

PROPERTIES

On passing, 'Finish' button: Goes to Next SlideOn failing, 'Finish' button: Goes to SlideAllow user to leave quiz: At any timeUser may view slides after quiz: After passing quizUser may attempt quiz: Unlimited times

Page 15: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

Type a H8S2215

Type b H8S2218 H8S2212

Type c H8S2472

Type d H8SX1653 H8SX1663H8SX1658R H8SX1668R

Controller types

USB line-up

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 16: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

The H8SX1664, H8S2218/2212

Endpoint Abbrev.Transfer

typeMaximum

packet size

FIFO capacity (Bytes)

DMA transfer

Endpoint 0 EP0 Control 8 8 -

Endpoint 1 EP1 Bulk-IN 64 128 Possible

Endpoint 2 EP2 Bulk-OUT 64 128 Possible

Endpoint 3 EP3 Interrupt 8 8 -

Endpoint Abbrev.Transfer

typeMaximum

packet size

FIFO capacity (Bytes)

DMA transfer

Endpoint 0 EP0 Control 8 64 -

Endpoint 1 EP1 Bulk-OUT 64 128 Possible

Endpoint 2 EP2 Bulk-IN 64 128 Possible

Endpoint 3 EP3 Interrupt 64 64 -

H8SX1664

H8S2218/2212

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 17: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

The H8S/2215

Self/USB powered Can use either System clock or External Clock for USB Configurable endpoint addresses

H8S/2215

Self/USB powered Can use either System clock or External Clock for USB Configurable endpoint addresses

Endpoint Abbrev. Transfer typeMaximum

packet size

FIFO capacity (Bytes)

DMA transfer

Endpoint 0 EP0 Control 8 64 -

Endpoint n EPn Bulk-OUT (2) 64 128 Possible

Endpoint n EPn Bulk-IN (2) 64 128 Possible

Endpoint n EPnInterrupt (2)

64 64 -

Endpoint n EPnIsochronous-IN

128 256 -

Endpoint n EPnIsochronous-

OUT 128 256 -

© 2010 Renesas Electronics America Inc. All rights reserved.

Page 18: Introduction to USB © 2010 Renesas Electronics America Inc. All rights reserved.

MSD HID CDCBulk-Only

with GUI and source

H8S/2215RSK/Web RSK/Web RSK/Web RSK/Web Web

H8S/2212/2218Web Web Web Web Web

H8SX1664 / 1668 RSK/Web RSK/Web RSK/Web RSK/Web Web

H8S/2472RSK/Web RSK/Web RSK/Web RSK/Web

-

Open source USB library LibUSB-Win32. Host stack available from Renesas and third party vendors

like Micrium.

USB software

© 2010 Renesas Electronics America Inc. All rights reserved.


Recommended