Brick ref topics 02 (#283)
* Add brick button topics * Add the rest of the brick api
This commit is contained in:
committed by
Peli de Halleux
parent
8a331648d6
commit
822227eb48
@ -5,6 +5,7 @@ namespace brick {
|
||||
*/
|
||||
//% blockId=brickBatteryLevel block="battery level"
|
||||
//% group="More"
|
||||
//% help=brick/battery-level
|
||||
export function batteryLevel(): number {
|
||||
const info = sensors.internal.getBatteryInfo();
|
||||
return info.current;
|
||||
|
Reference in New Issue
Block a user