USB learning (a)

USB learning (a)

USB specification since 1996, officially released USB1.0, USB1.0 from low-speed mode (Low Speed ​​Mode), to a USB 1.1 full-speed mode (Full Speed), then to the USB 2.0 high-speed mode (High Speed), so far as well as USB 3.0 \ 3.1 \ 3.2 and other ultra-telling mode.

Why learn to learn embedded USB? In the field of embedded in the direction of things is to walk from smart electrical, home electronics, automotive electronics and other products, without a shadow no USB, with high-speed USB transfer speeds for data transmission brings super real-time high. Because of application scenarios and cost for USB3.0 \ 3.1 \ 3.2 interface, such as basic is not used to, but there is no guarantee of future development could make it cheaper, or reasons for the large amount of data to be use them, you can learn to be together when the USB2.0 specification.

USB electrical characteristics

USB interface presentation

A typical USB Mini Interface:

Pin Number Pin Name Functional Description
1 Vbus +5V
2 D+ Data+
3 D- Data-
4 ID OTG/HOST/Slave…
5 GND GND/0V

Amazing, the USB connector, in fact, the classic is not ID this one. Although this is USB Mini, as well as USB micor, USB linght, USB type-c, etc., varied, but uphold the USB protocol is backward compatible, so more of these are certain there will be, and certain It is a public part.

Actual wiring on the computer, should be:

Vbus------------------------Vbus

D+ -------------------------D+

D- --------------------------D-

GND-------------------------GND

USB signal traces and reliability

PCB had drawn a friend, if when drawing the USB alignment, certainly knows USB traces are differential lines need to go, only to see because there are D + \ D- on the USB logo, it is a differential line. I personally feel that the surface is too understanding, in the end why D + / D- differential line on the road to go? The reason why USB easy to use, there is a reason for this is because the USB data is reliable, and that reliable support USB data behind, what is it?

  • Is one of the differential lines, USB uses a differential signal is transmitted, the differential signal can be effectively suppressed at the low level of interference. When the signal transmission at lower levels, in fact, is very susceptible to interference, and the use of differential line equal and opposite polarity, it can double the signal level, to reduce the influence of interference signals on USB signals. More importantly, if two signal lines are present noise, the subtraction of the differential signal can cancel noise, the differential signal pair has a natural immunity to signal interference.

  • The second reason, attentive friend should find, Vbus USB interface and GND, pin longer than the other, because when USB access, access to the first power supply, to avoid the dynamic Effects of current to the data line is inserted.

  • Third, the output of tri-state driver support, and connected to the signal line at the default high impedance state.

USB current and voltage

The USB, are the basis of the power Vbus USB charging, the USB2.0 specification, the voltage Vbus in the 4.4V-5.25V , to withstand the maximum current is 500mA . From the perspective of power, USB devices can be divided into two types bus-powered and self-powered.

  • Self-powered device: Vbus no need to use the USB powered, has its own power supply.

  • Bus Power: USB Vbus power supply apparatus supplies power from the host.

Each device requires a statement on the requirements of their current Vbus in their deployment descriptor to unified management by the USB host. While this is, in fact, but on each USB host, has a rated current, when the host device when too much, can not provide enough current for the device, the device will not function properly. Therefore, in practice, there will be a USB certification, this certification is to see whether the USB host gives a clear message about the USB certification can be described later.

Voltage drop budget

Because USB devices and power supply type bus topology is more complex, but to ensure USB is working properly, have a written protocol definitions:

  • USB cable defined impedance 30mΩ, passing through them pressure drop 100mV.
  • By a host or self-powered hub port voltage supply range is: 4.75-5.25V. The printer can support high-power devices such as USB power supply.
  • The voltage range of the bus-powered hub port to supply 4.4V-5.25V
  • Bus-powered hubs maximum allowed voltage drop of 350mV.
  • A maximum pressure drop between the plug and the Vbus B plug is 125mV.
  • The maximum voltage between the downlink and uplink on all cables GND reduced 125mV.
  • On the upstream end of a cable connector when a voltage as low as 4.40 V, all the hubs and devices must provide configuration information, and low-power devices at this voltage, you must be able to work properly.
  • If the USB device draws current load of more than one unit, then it must be a minimum operating voltage of 4.75V.

Inrush current limiting

Principles: a hub or device insertion and removal behavior, can not affect the normal operation of other devices on the bus.

Driving characteristics

USB compare performance of each mode:

mode speed Drive way 1.5K pullup
Vulgar 1.5Mb/s Voltage D-
full speed 12Mb/s Voltage D+
high speed 480Mb/s Electric current D+

USB signal characteristics

USB is transmitted using a differential signal, during transmission, the state presented:

  • Stationary state
  • Differential state (0/1)
  • Single end state (0/1)
  • Chirp J (high speed mode)
  • Chirp K (high speed mode)

Typical coincidence signal

Description: the composite signal is a signal plus one or more simple to obtain a specific configuration of timings.

Generating start and stop modes in different ways:

mode Packages start (SOP) End of Packet (EOP)
Low Speed Goes low from high D-, D + goes high from low 2bit time duration of the signal SE0
full speed D- goes low from the low level, D + goes high from high 2bit time duration of the signal SE0
high speed SE is switched from the state to the K / J state process Padding bit error
Published 46 original articles · won praise 56 · views 10000 +

Guess you like

Origin blog.csdn.net/qq_42312125/article/details/105049332
usb
usb