USB2.0 Spec

USB System Description

A USB system is described by three definitional areas:
• USB interconnect
• USB devices
• USB host

USB interconnect

The USB interconnect is the manner in which USB devices are connected to and communicate with the host.

USB Host

There is only one host in any USB system.
The USB interface to the host computer system is referred to as the Host Controller.
The Host Controller may be implemented in a combination of hardware, firmware, or software.
A root hub is integrated within the host system to provide one or more attachment points.

USB Devices

USB devices are one of the following:
Hubs, which provide additional attachment points to the USB
Functions, which provide capabilities to the system, such as an ISDN connection, a digital joystick, or speakers

Function <==> Device

USB devices are divided into device classes such as hub, human interface, printer, imaging, or mass storage
device.

All USB devices are accessed by a USB address that is assigned when the device is attached and
enumerated.

Electrical

The USB transfers signal and power over a four-wire cable,The signaling occurs over
two wires on each point-to-point segment.
在这里插入图片描述

Power

The cable also carries VBUS and GND wires on each segment to deliver power to devices. VBUS is
nominally +5 V at the source.

data rates

• The USB high-speed signaling bit rate is 480 Mb/s.
• The USB full-speed signaling bit rate is 12 Mb/s.
• A limited capability low-speed signaling mode is also defined at 1.5 Mb/s.

在这里插入图片描述

Clock

The clock is transmitted, encoded along with the differential data. The clock encoding scheme is NRZI
with bit stuffing to ensure adequate transitions. A SYNC field precedes each packet to allow the receiver(s)
to synchronize their bit recovery clocks.

In NRZI encoding, a “1” is represented by no change in level and a “0” is represented by a change in level.
在这里插入图片描述

Attachment of USB Devices

All USB devices attach to the USB through ports on specialized USB devices known as hubs. Hubs have
status bits that are used to report the attachment or removal of a USB device on one of its ports. The host
queries the hub to retrieve these bits. In the case of an attachment, the host enables the port and addresses
the USB device
through the device’s control pipe at the default address.
The host assigns a unique USB address to the device and then determines if the newly attached USB device
is a hub or a function.
If the attached USB device is a hub and USB devices are attached to its ports, then the above procedure is
followed for each of the attached USB devices.
If the attached USB device is a function, then attachment notifications will be handled by host software that
is appropriate for the function.

Removal of USB Devices

When a USB device has been removed from one of a hub’s ports, the hub disables the port and provides an
indication of device removal to the host. The removal indication is then handled by appropriate USB
System Software. If the removed USB device is a hub, the USB System Software must handle the removal
of both the hub and of all of the USB devices that were previously attached to the system through the hub.

Bus Enumeration

Bus enumeration is the activity that identifies and assigns unique addresses to devices attached to a bus.
Because the USB allows USB devices to attach to or detach from the USB at any time, bus enumeration is
an on-going activity for the USB System Software.

Data Flow Types

  • Control Transfers
    • Control data is used by the USB System Software to configure devices when they are first attached
  • Bulk Data Transfer
    • Bulk data typically consists of larger amounts of data, such as that used for printers or scanners.
    • Bulk data is sequential.
  • Interrupt Data Transfers
  • Isochronous Data Transfers

A pipe supports only one of the types of transfers described above for any given device configuration.

Physical Bus Topology

在这里插入图片描述
A composite device has only a single device address.
A device that has multiple interfaces controlled independently of each other is referred to as a composite device.

Logical Bus Topology

While devices physically attach to the USB in a tiered, star topology, the host communicates with each
logical device as if it were directly connected to the root port.
在这里插入图片描述

USB Communication Flow

在这里插入图片描述

Client Software-to-function Relationship

在这里插入图片描述

EndPoints

An endpoint is a uniquely identifiable portion of a USB device that is the terminus of a communication flow
between the host and device.
Each endpoint on a device is given at design time a unique device-determined identifier called the endpoint
number
.
The combination of the device address, endpoint number, and direction allows each endpoint to be uniquely referenced.
在这里插入图片描述

Pipes

A USB pipe is an association between an endpoint on a device and software on the host.
Pipes represent the ability to move data between software on the host via a memory buffer and an endpoint on a device.
There are two mutually exclusive pipe communication modes:
Stream: Data moving through a pipe has no USB-defined structure
Message: Data moving through a pipe has some USB-defined structure

Transfer Management

在这里插入图片描述

Mechanical

在这里插入图片描述
在这里插入图片描述

Icon

在这里插入图片描述

USB Connector Termination Data

在这里插入图片描述

Frame

在这里插入图片描述

USB Device States

在这里插入图片描述

  • Attached
  • Powered
    • USB devices may obtain power from an external source and/or from the USB through the hub to which they
      are attached.
  • Default
    • After the device has been powered, it must not respond to any bus transactions until it has received a reset
      from the bus.After receiving a reset, the device is then addressable at the default address.
  • Address
    • All USB devices use the default address when initially powered or after the device has been reset.
    • Each USB device is assigned a unique address by the host after attachment or after reset.
    • A USB device responds to requests on its default pipe whether the device is currently assigned a unique
      address or is using the default address.
  • Configured
    • Before a USB device’s function may be used, the device must be configured.
  • Suspended
    • In order to conserve power, USB devices automatically enter the Suspended state when the device has
      observed no bus traffic for a specified period.

USB Host

The USB System has three basic components:
• Host Controller Driver
• USB Driver
• Host Software

The Host Controller Driver (HCD) exists to more easily map the various Host Controller implementations
into the USB System, such that a client can interact with its device without knowing to which Host
Controller the device is connected.
The USB Driver (USBD) provides the basic host interface (USBDI) for clients to USB devices.
The client layer describes all the software entities that are responsible for directly interacting with USB
devices.

Device Configuration

在这里插入图片描述
When a device is attached, the hub driver receives a notification from the hub detecting the change.
The hub driver, using the information provided by the hub, requests a device identifier from the USBD.
The device is now ready to be configured for use. For each device, there are three configurations that must
be complete before that device is ready for use:

  1. Device Configuration: This includes setting up all of the device’s USB parameters and allocating all
    USB host resources that are visible to the device. This is accomplished by setting the configuration
    value on the device. A limited set of configuration changes, such as alternate settings, is allowed
    without totally reconfiguring the device. Once the device is configured, it is, from its point of view,
    ready for use.
  2. USB Configuration: In order to actually create a USBD pipe ready for use by a client, additional USB
    information, not visible to the device, must be specified by the client. This information, known as the
    Policy for the pipe, describes how the client will use the pipe. This includes such items as the
    maximum amount of data the client will transfer with one IRP, the maximum service interval the client
    will use, the client’s notification identification, and so on.
  3. Function Configuration: Once configuration types 1 and 2 have been accomplished, the pipe is
    completely ready for use from the USB’s point of view. However, additional vendor- or class-specific
    setup may be required before the client can actually use the pipe. This configuration is a private matter
    between the device and the client and is not standardized by the USBD.

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/230981.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

docker基本命令

1.docker命令图解 2. 从仓库拉取镜像 #下载最新版 docker pull nginx # 镜像名:版本名&#xff08;标签&#xff09; docker pull nginx:1.20.1docker rmi 镜像名:版本号/镜像id3. 容器启动及停止 docker run [OPTIONS] IMAGE [COMMAND] [ARG...] docker run [设置项] 镜…

maven阿里镜像华为镜像,settings.xml的mirrors

将下面这段放到settings.xml的settings标签下, mirrors标签只能有一个 <mirrors> <!-- 阿里开源镜像站maven网址 https://developer.aliyun.com/mirror/maven--><mirror><id>aliyunMavenRepositoryPublic</id><name>阿里云公共仓库2…

Flink系列之:窗口聚合

Flink系列之&#xff1a;窗口聚合 一、窗口表值函数&#xff08;TVF&#xff09;聚合二、窗口表值函数TVF三、分组集四、ROLLUP五、CUBE六、选择组窗口开始和结束时间戳七、多级窗口聚合八、分组窗口聚合九、时间属性十、选取分组窗口开始和结束时间戳 一、窗口表值函数&#x…

Linux常用命令大全(摘录整理)

1、ls命令2、cd命令3、pwd命令4、mkdir命令5、rm命令6、rmdir命令7、mv命令8、cp命令9、cat命令10、more命令11、less命令12、head命令13、tail命令14、which命令15、whereis命令16、locate命令17、find命令18、chmod命令19、tar命令20、chown命令21、df命令22、du命令23、ln命…

R语言【rgbif】——occ_search对待字符长度大于1500的WKT的特殊处理真的有必要吗?

一句话结论&#xff1a;只要有网有流量&#xff0c;直接用长WKT传递给参数【geometry】、参数【limit】配合参数【start】获取所有记录。 当我在阅读 【rgbif】 给出的用户手册时&#xff0c;注意到 【occ_search】 强调了 参数 【geometry】使用的wkt格式字符串长度。 文中如…

Linux内存管理(十七):percpu 分配器——框架实现

源码基于:Linux5.4 约定: 芯片架构:ARM64内存架构:UMACONFIG_ARM64_VA_BITS:39CONFIG_ARM64_PAGE_SHIFT:12CONFIG_PGTABLE_LEVELS :3关联博文: percpu分配器——基础概念 percpu分配器——框架实现 percpu分配器——动态分配 0. 前言 上一篇博文</

使用数组模拟栈的相关操作【栈1.1】

public class ArrayStackDemo {public static void main(String[] args) {ArrayStack arrayStack new ArrayStack(4);Scanner sc new Scanner(System.in);boolean loop true;char key ;while (loop) {System.out.println("栈操作菜单项");System.out.println(&q…

基于SpringBoot和微信小程序网上购物商城

文章目录 项目介绍主要功能截图:部分代码展示设计总结项目获取方式🍅 作者主页:超级无敌暴龙战士塔塔开 🍅 简介:Java领域优质创作者🏆、 简历模板、学习资料、面试题库【关注我,都给你】 🍅文末获取源码联系🍅 项目介绍 基于SpringBoot和微信小程序网上购物商城…

范仲淹仅存五首词作,篇篇经典

范仲淹&#xff0c;北宋时期杰出的政治家&#xff0c;文学家&#xff0c;提起他首先想到初中那篇《岳阳楼记》&#xff0c;难倒无数背诵困难户&#xff0c;它虽然难背&#xff0c;但却是一篇文字排列极美&#xff0c;意境极佳的美文。 “不以物喜&#xff0c;不以己悲&#xf…

Android hilt使用

一&#xff0c;添加依赖库 添加依赖库app build.gradle.kts implementation("com.google.dagger:hilt-android:2.49")annotationProcessor("com.google.dagger:hilt-android:2.49")annotationProcessor("com.google.dagger:hilt-compiler:2.49"…

Python顶级组件

顶级组件 Python 解释器可以从多种源获得输入&#xff1a;作为标准输入或程序参数传入的脚本&#xff0c;以交互方式键入的语句&#xff0c;导入的模块源文件等等。 这一章将给出在这些情况下所用的语法。 9.1. 完整的 Python 程序 虽然语言规范描述不必规定如何发起调用语言…

【leetcode刷题之MySQL】

175. 组合两个表 select firstName,lastName,city, state from Person left join Address on Person.personIdAddress.personId LEFT JOIN&#xff1a;保留左表内容&#xff0c;右表不存在的列使用 Null 代替 RIGHT JOIN&#xff1a;保留右表中连接字段的内容&#xff0c;左表…

【ubuntu】Linux常用截屏软件

Linux截屏软件及安装教程 截屏软件简介 在Linux系统中&#xff0c;有多种强大的截屏工具可供选择。以下是一些常用的截屏软件&#xff1a; Shutter 功能强大&#xff0c;支持全屏、窗口、选区等多种截屏方式。可以添加注释、标记和编辑截图。 Flameshot 轻量级截屏工具&…

程序人生,由“小作文”事件想到的

时势造英雄。自媒体时代&#xff0c;火出圈是靠大众的审美和爱好&#xff0c;自己能做的关键&#xff0c;其实是做好自己&#xff0c;选择向上生长&#xff0c;持续不断的读书、学习。同时保持一份好奇心&#xff0c;培养一个兴趣爱好并自得其乐。 展示自我 回想起我小时候&am…

Linux内核实现AES加密

本文涉及到编写一个内核模块&#xff0c;扩展内核密钥类型并使用该密钥实现AES加密。以下是一个简单的示例代码&#xff0c;演示如何在C语言中实现一个内核模块以及在内核中使用密钥进行AES加密。 c #include <linux/module.h> #include <linux/kernel.h> #includ…

Promise执行顺序

小编建议小伙伴们不要跳点看&#xff0c;每一点都是衔接&#xff0c;有比较的 本篇文章考查 ①promise是同步任务还是微任务 ②promise.then()什么时候执行&#xff0c;是微任务还是宏任务 ③如何控制状态变化&#xff0c;不同状态变化&#xff0c;会执行哪个回调函数 1、以下代…

进制之间的转换——n进制转换为m进制(C/C++实现,简单易懂)

目录 &#x1f308;前言&#xff1a; &#x1f4c1; 什么是进制转换&#xff1a; &#x1f4c1;其他进制转换成十进制&#xff1a; &#x1f4c2;二进制( B ) ——> 十进制( D ) &#x1f4c2;八进制( O ) ——> 十进制( D ) &#x1f4c2;十六进制( H ) ——> 十进制…

运维实践|采集MySQL数据出现many connection errors

文章目录 问题出现问题分析当前环境问题分析 解决方案1 检查调度事件任务是否开启2 开启调度事件任务3 创建一张日志表4 创建函数存储过程5 创建事件定时器6 开启事件调度任务7 检查核实是否创建 总结 问题出现 最近在做OGG结构化数据采集工作&#xff0c;在数据采集过程中&am…

抖音商品详情API接口在电商行业中的重要性及实时数据获取实现

随着移动互联网的快速发展&#xff0c;电商行业不断壮大。抖音作为一款短视频社交应用&#xff0c;近年来在电商领域取得了显著成果。本文将探讨抖音商品详情API接口在电商行业中的重要性&#xff0c;以及如何通过实时数据获取提高业务效率。我们将介绍相关的技术背景、API接口…

Linux 操作系统 004-远程连接

Linux 操作系统 004-远程连接 本节关键字&#xff1a;Linux、远程连接、XManager、Xshell、ssh 本节相关指令&#xff1a; XManager的下载 XManager官网 Xmanager的安装 1、双击下载好的安装包&#xff0c;下一步 2、接受许可&#xff0c;下一步 3、产品密钥&#xff08;试…