Last Updated on May 19, 2020 by admin
Raspberry Pi USB ports Depend on the model, Raspberry Pi has one to four USB ports. The USB is a universal external interface for all sorts of peripheral devices that are to be operated on Raspberry Pi. Typically keyboard, mouse, pen drives, wireless adapter and the like.
USB 2.0 has a transfer speed of up to 480MBit/s. That’s the equivalent of 60MB/s. Which is more of a theoretical value.
As a rule, you can barely reach more than 30MB/ s on a USB 2.0 port. And that only when transferring large files or a long-lasting data stream. But not when transferring a lot of small files, as is typical.
Display of all USB devices in the building structure:
The USB devices log on to the bus with the name displayed. For some devices, the name is not unique. Under certain circumstances one comes by the manufacturer name or the product name on the function of the device.
The architecture of Raspberry Pi has a small flaw that makes it not suitable for all applications. Especially where fast I/O connections are important.
The system-on-chip of Raspberry Pi has only a single internal USB port. All external USB ports and the Ethernet port are attached to this USB port. As a result, the network interface and all external devices connected to Raspberry Pi via USB have to share the total bandwidth of 480Mbps. Thus, the I/O performance of Raspberry Pi is limited to a maximum of 60MB/s, in practice to about 30MB/s. Even if the connected devices can work faster.
This limitation must always be taken into account if Raspberry Pi is to mediate between two interfaces. For example, as a router, gateway or bridge. This means you use the Ethernet port on one side and another Ethernet or wifi adapter on a USB port on the other side. Then the traffic must pass through the internal USB port twice. Once inside and a second time out. This means you reduce the I/O performance of the internal USB port by half. Regardless of how many USB ports Raspberry Pi actually has.
- When copying from a USB disk to a drive on the network, Raspberry Pi 2 reaches almost 11 MB per second. The predecessor is just under 4 MB per second.
- Booting the operating system from a USB flash drive is a good idea because the SD card is much better connected than the USB.
Power supply via the USB
On a Raspberry Pi, powering USB devices through the USB ports is a tricky business. If mouse and keyboard and maybe even one or the other USB stick is connected, then that’s no problem. But if you work with external hard drives or power-hungry Wi-Fi adapters, then the power supply of Raspberry Pi breaks down. For this reason, it is generally recommended that USB devices be connected through an active USB hub. An active USB hub has its own power supply, which can be used to power the connected devices.
From the B+ model, a parameter has also been introduced that controls how much power USB devices are allowed to pull out of the USB port. With this parameter, you can increase the current limit from 600 mA to 1200 mA.
Raspberry Pi USB Troubleshooting
Occasionally it happens that USB devices on Raspberry Pi are not working properly. This also includes the Ethernet port of Raspberry Pi due to its architecture. It hangs on the only internal USB port. As a rule, USB problems are usually network problems as well.
USB problems have nothing to do with Raspberry Pi, but with the Raspberry Pi power supply. The cause is usually always an inferior power supply or charger, that does not supply enough power and breaks down the supply voltage as a result. If the supply voltage moves below a certain limit, a Raspberry Pi tries to prevent the crash by switching off internal components. This reduces the power consumption. If the voltage values are correct, it resumes the operation of the components.
If the internal USB is switched off due to poor power supply, then the network connections via Ethernet and/or a USB wifi adapter are also lost. When the USB is put back into operation, but often the network connection is gone. In general, the Raspberry Pi needs to be restarted. If necessary, one could also reinitialize the network connections manually.
Usually, the USB problem is solved by running power-hungry USB devices through an active USB hub or replacing them with more energy-efficient devices. It is better to worry about a power supply that deserves its name and has sufficient power to ensure a stable power supply for a short time increased current drain.