USB connectivity in a battery-powered IoT world -

USB connectivity in a battery-powered IoT world


Over the last decade, the universal serial bus (USB) standard has been adopted by designers of industrial and consumer devices as their interface of choice for enabling connectivity to other applications due to its ease-of-use, plug-and-play functionality and robustness. USB has achieved its primary goal of simplifying the way consumers control peripherals and transfer data. With more than three billion USB-enabled devices shipped into the market, USB is not only the fastest growing interface in consumer applications but has also achieved significant growth in industrial markets.

However, USB’s ease-of-use, plug-and-play functionality and robustness do not come free for embedded solutions designers, especially if they are designing power-sensitive, battery-operated connected device products for the Internet of Things. For small, portable devices, adding USB as a communication interface at least doubles application current consumption and leads to devices that require much larger batteries than originally anticipated.

Upgrading from a traditional serial interface for communication to the popular USB interface often puts unfeasible restrictions on an energy budget. Often, a developer will have to choose between doubling the battery size and increasing device cost, which makes it less appealing, or cutting back on much-needed differentiating features. Let’s take a look at how the USB standard has evolved from the dream of standardizing all PC connections to a state-of-the-art technology that allows even small battery-powered devices for the IoT to communicate with anything.

A Short History of USB
If you have ever examined the back of a desktop PC manufactured in the late 1990s, you would instantly recognize the proliferation of standards for connecting different types of hardware to your computer. Connectivity options included a 5-pin DIN, PS/2, serial port, parallel port, and maybe an SCSI (“scuzzy”) port or two, and if you were a gamer, you would also have a game port on your soundcard.

The original developers of USB recognized this fragmented connectivity situation, and in 1995, they started to create one common machine-to-machine (M2M) standard that would supersede all others. In the late 1990s, when USB was first being adopted, it was initially added to PCs as just another connector to the mix. However, during the 2000s, USB really started to proliferate, and, after a series of updates, it is now one of the most widely adopted M2M interfaces. The success of the USB standard is evident by looking at your laptop or phone. Your smart phone has just one connector: USB. If you purchased your laptop after 2010, it probably has only USB connectors in addition to the display and network connectors. In addition, touchpads, keyboards and other peripherals used in today’s laptops and tablets communicate with the main processor over USB.

The USB standard separates connectivity topology into devices and hosts . The host is the machine that initiates the communication and provides the power; on your desk, this is generally your laptop or desktop PC. The device is the downstream device that is connected to the host and simply replies to whatever the host asks for. On your desk, the mouse and keyboard are examples of USB devices.

The cool thing about a USB connector is that it also supplies power to the attached device, so there is no need for an external power supply to your mouse or external hard drive. The USB standard specifies that the host deliver at least 100 mA of current to the device, and, if the device is lucky, it will have 500 mA available. These power capabilities come from the original USB standard: PCs were always the host, and they were always powered through a wall socket. This USB standard requirement effectively stopped development of USB for low-power applications, as abundant mains power supplies have always been available for PC applications.

But what happens when this proven M2M interface meets today’s abattery-powered world for the IoT? What is the impact when the host isalso a portable device?

Impacts for Today’s USB Hardware
Intoday’s portable device applications, a much-used term is “powerbudget.” The power budget dictates how much energy the device canconsume and is based on battery size and the required battery life. Forexample, an application that has a 250 mA battery and needs abattery-life of two days (48 hours) has a power budget of approximately 5mA. This power budget must be distributed across everything a developerwants the device to do, from sensor acquisition and processing tocommunication and driving displays.

As MCUs grew smaller and batteries improved over the last two orthree decades, we saw an explosion of portable electronic devicesranging from handheld wind meters and oscilloscopes to digitalbreathalyzers and remote controls. However, with the introduction ofsmart phones with quad-core gigahertz processors, we now see moreportable devices being introduced as additions to smart phones sincemanufacturers no longer have to worry about processing power or userinterfaces. This market trend is driving the proliferation ofinexpensive add-ons. Examples include the Kickstarter-backed Vaavud windmeter for smart phones and a breathalyzer that plugs into your iPhone.Both applications use the HiJack interface, an ad-hoc interface thatworks on low-end devices but is far from optimal.

To design a portable device that is truly universal and userfriendly, you would opt for a more suitable M2M-interface like USB.Choosing USB also allows the gadgets you design to be host-agnostic,meaning that it no longer matters if you are connecting to a Mac, aWindows phone or an Android tablet. Therefore, when you want to connectall of these extra gadgets via USB to your battery-powered everydaycompanions, what was never a concern in the original USB specification –power consumption – suddenly becomes a top priority when choosing aUSB-based solution. You don’t want to waste the precious battery life ofa tablet or laptop just to communicate with the onboard peripherals.And you wouldn’t want to design a simple add-on application for a smartphone that quickly drained its battery.

By choosing the right USB-enabled hardware, you will be able todevelop your device with a much smaller energy footprint since auniversal M2M interface allows you to exclude almost all externalcomponents.

USB Technology for the Battery-Powered World
Tounderstand how USB technology can be improved in terms of powerconsumption while retaining its ease of use and plug-and-playfunctionality, we first need to take a quick look at how USBcommunication works. In general, only the host can initiate transfers.Even if there is no communication, the host sends keep-alive messages tothe device every millisecond. If the device has data available, it willreply. In this active mode, the device has up to 100 mA of power, andthe host expects the device to provide an immediate response to anyrequest. When the host stops sending these keep-alive messages for 3 ms,the device should enter a suspend state and immediately reduce itscurrent draw below 3 mA.

In the suspend state, most of the device can be switched off, andusually we can switch off the most power-hungry parts of the PHY. Infact, modern MCUs automatically provide this capability. Even though a 3mA suspend current should be easily achievable by any modern MCU, thereis no reason to keep it that high. MCUs with well-thought-out energymodes should be able to achieve less than 3 µA in this mode, includingthe current draw of the PHY.

In active mode, when inspecting the USB communication of aregular keyboard device, active mode is not very active; most of thetime, the device is just waiting for the host to send data. However,whenever the host requests a response from the device, the response mustbe immediate; that is why most implementations keep the USB peripheralrunning at 48 MHz at all times to allow sufficient response time. Inthis particular example, the lines are idle for 97 percent of the time,even though we are enumerated and active.

A USB implementation optimized for battery-powered applications takesthese power management considerations into account and determinesexactly when the clock is needed and for how long, and what other partsof the USB can be shut off. In Silicon Labs' patent-pending designapproach, energy-efficient communications — even in active mode — areenabled by using crystal-less USB oscillators and by automaticallydisabling the power-hungry part of USB connectivity between packets asshown in Figure 1. This innovation greatly reduces system-level powerconsumption and creates a universal M2M interface offering the degreeof energy efficiency required for battery-powered designs such as IoTdevices.

Figure1. Overview of bus traffic for a keyboard with the low-energy mode(LEM) active signal indicating when the power-hungry parts of the USBinterface are disabled.

Of course, low-energy USB should be implemented in a way that it isinvisible to both developers and end users. What will be noticeable issignificantly reduced power consumption through low-energy modes (LEM),as shown in Figure 2. When this technology is combined with other space-and cost-saving features such as crystal-less USB implementations andclock recovery, developers can realize an ultra-low-power universal M2Minterface without the need for additional external components.

Figure2: A typical USB transceiver stays in “receive” mode when idle, wasting3–5 mA. With LEM techniques, the transceiver is kept in a low currentmode similar to suspend.

The USB interface has evolved from asimple desire to reduce the cable clutter of the traditional desktop PCto becoming the de-facto standard for interfacing consumer devices. Theproliferation of USB-enabled, portable devices has forced new designrequirements for integrated USB peripherals.

New, intelligent USB hardware enables cost and power reduction andextended battery-life. When combined with crystal-less USB technology,the widely used USB standard enables all connected devices to be smart,connected, and energy friendly.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.