Wyświetlanie zmiany ładowania po podpięciu kabla
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
#include "SD.h"
|
||||
#include "SPI.h"
|
||||
|
||||
#define Version "0.28"
|
||||
#define Version "0.29"
|
||||
#define WIRE Wire
|
||||
#define DHTTYPE DHT22
|
||||
#define DHTPIN 4
|
||||
@@ -440,6 +440,11 @@ void loop() {
|
||||
|
||||
// Log napiećia docelowoe procent baterii
|
||||
// kiedy zaden przycisk nie jest wcisniety
|
||||
if (abs (batteryVoltage - currentBatteryVoltage) >= 0.2 && digitalRead(BTN_DOWN) == LOW && digitalRead(BTN_UP) == LOW && digitalRead(BTN_ENTER) == LOW ) {
|
||||
lastBatteryVoltage = currentBatteryVoltage;
|
||||
currentBatteryVoltage = batteryVoltage;
|
||||
}
|
||||
|
||||
if (secs % 15 == 0) {
|
||||
lastBatteryVoltage = currentBatteryVoltage;
|
||||
currentBatteryVoltage = batteryVoltage;
|
||||
|
||||
Reference in New Issue
Block a user