** Function name: getBattery() ** location: display.cpp ** Description: Delivers the battery value from 1-100 ***************************************************************************************/
| 18 | ** Description: Delivers the battery value from 1-100 |
| 19 | ***************************************************************************************/ |
| 20 | int getBattery() { |
| 21 | int percent = 0; |
| 22 | percent = M5.Power.getBatteryLevel(); |
| 23 | return (percent < 0) ? 0 : (percent >= 100) ? 100 : percent; |
| 24 | } |
| 25 | |
| 26 | /********************************************************************* |
| 27 | ** Function: setBrightness |
nothing calls this directly
no outgoing calls
no test coverage detected