2
\$\begingroup\$

I am designing a development board for STM32F103 microcontroller. I plan to implement an on-board USB for interfacing with the uC. I referred a few designs online and have always found some pull up logic on the D+ line.

Can someone please explain me the use of the pull-up logic and also tell me whether the 22R resistors are necessary or not.

This is the image I am using as a reference. STM32 USB Circuit

\$\endgroup\$
2
  • \$\begingroup\$ You need pull-up to tell computer that device is connected. When you reboot your MCU, pullup from D+ removes & computer will reconnect on its appearance. \$\endgroup\$
    – Eddy_Em
    Jan 19 '16 at 13:50
  • \$\begingroup\$ Lose the pull-up circuitry. The USB peripheral should be handling that unless specifically stated. Lose the 47pF caps. Keep the 22 Ohm resistors. Add a dual pack sterring diode+TVS combo that was designed for USB. \$\endgroup\$
    – Matt Young
    Jan 19 '16 at 13:50
5
\$\begingroup\$

A USB device must indicate its speed by pulling either the D+ or D- line high to 3.3 volts. A full speed device, pictured below will use a pull up resistor attached to D+ to specify itself as a full speed device. These pull up resistors at the device end will also be used by the host or hub to detect the presence of a device connected to its port. Without a pull up resistor, USB assumes there is nothing connected to the bus. Some devices have this resistor built into its silicon, which can be turned on and off under firmware control, others require an external resistor.

http://www.beyondlogic.org/usbnutshell/usb2.shtml

The series resistance are for line termination

The Universal Serial Bus (USB) line termintation is specified in the USB 1.1 specification to insure proper terminations so that signal integrity is maintained. The termination requirement varies depending on what driver chipset is used, whether the port is upstream or downstream, and if the transceiver operates in full or low speed.

When the USB 1.1 specification was written, a series resistor between the range of 28Ω to 44Ω was required. Most USB drivers will require a termination resistor of 16 - 33Ω.

http://www.semtech.com/images/datasheet/usb%20line%20termination%20_ag.pdf

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.