Efficient embedding of Single Board Computer in custom hardware

Developers today often face customer specifications setting stringent requirements concerning the devices to develop. Such requirements may be multimedia capabilities, complex mad-device connectivity, real time management of file systems, larger volumes of data and databases and connection to various encrypted networks.

In addition, a further requirement can be keeping development and manufacturing costs low. In such cases, applying an SBC (single board computer) can be a good solution. The best known range of SBCs is RaspberryPI, but lots of other alternatives are also used in the sector (e.g. KARO, NI Single Board RIO, TORADEX).

Application of SBCs and the necessity if vegetative systems

SBCs are module formatted, yet high-performance computers, designed to be as compact as possible, in spite of being equipped with all important components of CPUs (memory of adequate size, back office, local power supply units, I/O connectors, high-speed connectivity, and preferably, wireless connection).

By applying these commercially available off-the-shelf products, the developer may save some very serious circuitry development work and operating system porting as well as the risks associated with organising production. Practically, one only needs to design one task-specific motherboard around the SBC, allowing the latter’s proper operation, implementing the appropriate functions in the simplest possible way. Therefore, the specific task in addition to selecting the SBC is reduced to designing the motherboard receiving it (which is of far lower complexity) and writing the application running on downloadable operating system.

Although these modules contain important components for all processors, they only contain these for the sake of flexibility. Therefore, appropriate power supply and the necessary set of peripherals are designed on the motherboard. The block scheme of one feasible system is shown in Figure 1.

single board1
1. Figure: Block Scheme


Figure 1 Block Scheme

Power supply and operation of the SBC is performed by the lowest layer in the figure, which is known as the vegetative system. This system can be generally found in modern electronic devices and is also regularly applied on our proprietary boards.

The vegetative system does not participate in the main functionality; its presence is impossible to notice in most cases. In the back office, it however executes and monitors correct progress of the power on and off processes, for example. It is also revealed in the course of this communication whether the operating system has successfully booted or the power off process has been completed. In a less than fortunate case, the interruption of these processes can damage the files in the processor’s back office of the file system, leading to the device requiring servicing. The Watchdog function assists in appropriately running the operating system and the application, and restarts the processor in case of crashes.

Power supply management

In addition to monitoring the state of the operating system, the vegetative system manages power supply, ensuring the appropriate and continuous supply of energy. Supply voltage management is a complex task especially in case of battery-powered devices, going beyond simply monitoring the battery’s momentary voltage level. For example, Li-ion batteries in widespread use today must not be charged or discharged outside certain temperature ranges; the maximum value of the charging current and discharge must be restricted, preventing the batteries from deep discharge. The vegetative system supplies data for tracking the battery pack’s model-based state, providing the basis for data requiring complex calculations such as the remaining number of working hours.

The detailed block scheme of a vegetative system of a portable device is shown in Figure 2.

single board2
 2. Figure: Detailed Scheme


Figure 2: Detailed Scheme

The heart of the system is a low power and low consumption 8 bit microcontroller, and the software running on is designed to perform the following tasks:

Monitoring the condition of the SBC. This means periodic communication between the SBC and the vegetative controller, by the method described above. This connection is responsible for “exchanging” all important information between the two units (charge, temperatures, commands, statuses, emergencies) and therefore the watchdog function is also realised.

Execution of the power on and off processes, detection of the user command via the usual push button or the graphical user interface. Upon executing the command, the current state must be taken into consideration, and also the fact that no procedure underway can be interrupted.

Monitoring power supply and the battery’s condition. As the momentary state of the battery depends on temperature, load, age and number of charge and discharge cycles, and the precise extent of the level of charge cannot be precisely determined from the terminal voltage. The low-consumption component named fuel gauge, continuously connected to the battery’s terminals is particularly suitable for this, which measures the battery’s terminal voltage and the magnitude and direction of the current passing through it with the appropriate periodicity.

In addition to measurement, storage of historical data is likewise realised because of this component. With the help of this device, the mathematical model running on the vegetative system will be capable of giving a highly precise estimation of the state of charge. A further important task is controlling the charging of the battery. When adjusting the charging current, the load capacity of the external source (USB port or charger) and the temperature of the battery must be taken into consideration.

Power on/off function

The hardware of the vegetative system also performs certain important functions. The state of the power on/off button is monitored by a special circuit called ON/Off controller. This is a current of very low consumption, continuously supplied from the battery.

This circuit, sensing the button’s pushing, starts the power supply of the vegetative system, thereby operating the vegetative controlled as well. If the vegetative senses that the command is of adequate length, i.e. the product of a conscious decision, it acknowledges the activated state using the HOLD signal for the On/Off controller.

Watchdog function

The balancer is in charge of the appropriate charging and protection of the batteries. As all battery cells are different and age differently, the state of charge of the cells becomes asymmetrical as the number of cycles increases. Some may charge faster, and therefore may even become overcharged during a full charging cycle.

 This component, in the course of the charging process, bypasses or partially discharges the cell more ahead in charging so that at the end of the charging cycle, all cells will be nearly in the same state of charge. The same component is responsible to protect the cells against overcharging, overcurrent and deep discharge. If any of the problems exists, the protection will interrupt the cell’s circuit, thereby terminating the charging or discharging current.

If the external and internal energy sources are available, i.e. the internal battery and the external USB charger are simultaneously available, the power OR-ing component will select from them according to the predetermined priority.

As the external power supply may be disconnected from the device by the user freely and asynchronously, it is an expectation that this event’s detection and switching to battery power should take place as fast as possible and without interruption.

The vegetative system includes a number of different power supply units. The specifications of these may also change significantly with the number of battery cells.

For a cell battery, the On/Off controller can be directly connected to the battery, but the vegetative system and the SBC are supplied in this case with the help of buck-boost converters, as the required 3.3 V of voltage must be possible to be generated at even the widest range of the terminal voltage of the cell (4.2 V-2.8 V).

If the battery contains several cells connected in series, the buck-boost property is negligible.

Components used by the author:

Battery protection IC: BQ29700DSET
Fuel gauge IC: MAX17048G+T10
Li-ion charger and power path controller programmable on I2C bus: BQ25601DRTWR
On/Off controller: STM6600DA55DM6F 
Buck-Boost power supply unit: TPS63001DRCT

Written by:
István Bogár,
Chief Hardware Architect

Blog

Validation of Product Line Tester Measurement Systems

Several methods have been used in the industry, and we present here the statistical validation methods.

Read more …

The basics of safe manufacturing

The importance of using standards - with case studies

Read more …

Creating well-being at work

As the world has developed and welfare societies have emerged, attitudes to work have changed.

Read more …