Microsoft and Tesla Define Software-Defined Batteries

October 04, 2015 by Jeff Shepard

The concept of Software Defined Batteries (SDBs) is described in a paper that a team of researchers from Microsoft Corp, Tesla Motors, University of Massachusetts Amherst, and Columbia University will present at the ACM Symposium on Operating Systems Principles this week. Different battery chemistries perform better on different axes, such as energy density, cost, peak power, recharge time, longevity, and efficiency. Mobile system designers are constrained by existing technology, and are forced to select a single chemistry that best meets their diverse needs, thereby compromising other desirable features. In this paper, the authors present a new hardware-software system, called Software Defined Battery, which allows system designers to integrate batteries of different chemistries.

SDB exposes APIs to the operating system to control the amount of charge flowing in and out of each battery, enabling it to dynamically trade one battery property for another depending on application and/or user needs. Using microbenchmarks from the prototype SDB implementation, and through detailed simulations, the authors’ demonstrate that it is possible to combine batteries which individually excel along different axes to deliver an enhanced collective performance when compared to traditional battery packs. SDB allows a device to use diverse batteries through fine-grained control of the amount of charge flowing in and out of each battery. SDB provides APIs to the OS to change the power values based on user workload.

"No single battery type can deliver the ever-growing list of requirements of modern devices: fast charging, high capacity, low cost, less volume, light in weight, less heating, better longevity, and high peak discharge rates. A growing range of battery chemistries are under development, each of which delivers a different set of benefits in terms of performance. It is our position that combining multiple of these heterogeneous batteries instead of using a single battery chemistry can allow a mobile system to dynamically trade between their capabilities and thereby offer attractive tradeoffs," commented Ranveer Chandra, Principal Researcher at Microsoft and leader of the battery research project.

However, traditional methods of integrating multiple batteries are not suitable for heterogeneous batteries. Simply connecting them in series or parallel chains does not provide enough control over the flow of energy: batteries connected in series can only supply the same amount of current; batteries connected in parallel must operate at the same voltage and can only supply currents that are inversely proportional to their internal resistances.

The new system proposed allows heterogeneous batteries with different chemistries to be integrated in a mobile system. SDB consists of hardware and software components. The hardware enables fine-grained control of the amount of power passing in and out of each battery using smart switching circuitry. The charging and discharging hardware is designed to be low-cost, and hence the algorithmic complexity of computing how much power to draw from each battery, and how to recharge each battery, is placed in the SDB software that resides in the OS.

Deciding how much power to draw from each battery, and how to charge each battery is non-trivial. It depends on the efficiency of each battery under different workloads, the age of each battery, and also the user’s workload and usage profile. For example, if a high power workload is anticipated in the future, then it could be worthwhile conserving charge on the battery that is more capable of handling such a workload in an efficient manner.

The SDB software component that resides in the OS implements a set of policies and APIs. The SDB software uses simple APIs to communicate with the SDB hardware. The algorithms implemented by this software use various metrics for increasing the single charge-discharge duration of the device, and the longevity of the batteries, and thereby decide the ratios in which to discharge each battery, and the ratios in which to charge them.

The SDB design is cross-layer and involves new chemistries, additional hardware, and new OS components. Although an alternative SDB implementation can be hardcoded in firmware, the authors' claim that the cross layer approach has two main benefits.

First, it opens up new battery parameters, previously unavailable to OS designers, for resource optimization. In existing mobile devices, the battery is usually treated as a black box, and is simply assumed as a reservoir of charge. OS techniques yield substantial gains in battery usage.

Second, this design allows a system designer to select any combination of batteries for an optimal design, including new chemistries as they are invented, and developed. All of these can be enabled through a software update.

Even with existing batteries, SDB enables several new scenarios, such as: Bendable batteries for long-lived wearable devices: Bendable batteries are appealing for wearable form factor devices. For example, thin, bendable batteries can be installed in the straps of a smart watch to augment a traditional Li-ion battery in the body, and significantly improve battery life. However, these batteries are much less efficient than traditional Li-ion batteries because their rubber-like electrolyte increases internal resistance. Using SDB, the authors’ develop a prototype hybrid battery system using a bendable battery and a Li-ion battery, and develop an algorithm that a smart-watch OS can use to minimize the inefficiency in such a system based on user workload.

Supporting high power workloads: SDB enables two such scenarios. First, SDB enables a fast charging battery to be used in combination with a high energy density battery. A device can then gain a good percentage of its charge in just a few minutes, without losing out on total battery capacity or the longevity of the battery back. Second, SDB supports higher turbo modes for the CPU using a high power density battery in combination with a high energy density battery. SDB helps the OS decide when to enable higher turbo modes based on workload requirements, and also to intelligently manage the batteries.

Battery management for 2-in-1s: In 2-in-1 laptops that have a detachable keyboard, external battery packs under the keyboard are typically used to charge the main internal battery. This however, reduces the efficiency and effective energy capacity because of the losses involved in charging one battery from another. With SDB it is possible to reduce this inefficiency and improve effective energy capacity by up to 22%.

Moving forward, the authors’ are taking the SDB work in two main directions: First, they are tying personal assistants like Siri, Cortana, and Google Now with SDB. These assistants understand user behavior and the user’s schedule and by using this information, an OS can perform better parameter selection. For example, if the user’s profile suggests that the user plays video games in the evening, then it SDB could preserve a higher power density battery for that workload.

Second, they are working on additional devices that would benefit from this technology, such as drones, smart glasses, and electric vehicles (EV). Each would require a different combination of battery chemistries, and the SDB logic might be different too. For example, an EV’s NAV system could provide the vehicle’s route as a hint to the SDB Runtime, which could then decide the appropriate batteries based on traffic, hills, temperature, and other factors. Preliminary analysis shows that SDB might help these systems achieve tradeoffs that until now were considered to be at odds with each other.