Changes

Jump to navigation Jump to search

UPS3

221 bytes added, 00:16, 13 May 2021
==User Manual==
*[[UPS3 power off guide]]*The charge level indicators (RGB LED) is controlled by program, script please refer to Github: https://github.com/geekworm-com/ups3
==FAQ==
// invoke the API to get AC PSU status: connected or disconnected
int disconnected_flag = getACPSUStatus(); // please refer to the user manual to achieve getACPSUStatus function;
int battery_voltage = getBatteryVoltage(); // please refer to the user manual to achieve getBatteryVoltagefunction;
// You can make your own actions based on disconnected_flag and battery_voltage, you can only select one condition also
if (disconnected_flag ) {
// execute linux or software shutdown command
}
 
sleep(10);
}
</pre>
 
 
Q3: How to restart the pi board when AC Power supply is connected?
 
A: Please enable 'AUTO POWER ON' or 'AUTO ON' function if you want restart when the AC Power supply is reapplied.
<!--Add review function! -->

Navigation menu