SPIKE-RT C API Reference [English]
An RTOS-based software platform for LEGO® Education SPIKE™.
Loading...
Searching...
No Matches
Battery

APIs for battery. More...

Functions

uint16_t hub_battery_get_voltage (void)
 Retrieve the battery voltage.
 
uint16_t hub_battery_get_current (void)
 Retrieve the battery current.
 

Detailed Description

APIs for battery.

Function Documentation

◆ hub_battery_get_current()

uint16_t hub_battery_get_current ( void )

Retrieve the battery current.

Returns
Current in mA..

◆ hub_battery_get_voltage()

uint16_t hub_battery_get_voltage ( void )

Retrieve the battery voltage.

Returns
Voltage in mV..