small param adjustment+fix
This commit is contained in:
parent
b977159efd
commit
fce4d74efe
|
|
@ -120,7 +120,6 @@ void loop() {
|
||||||
DEBUGln(BATstr);
|
DEBUGln(BATstr);
|
||||||
|
|
||||||
radio.sleep();
|
radio.sleep();
|
||||||
motionDetected=false;
|
|
||||||
digitalWrite(EXTLED, LOW);
|
digitalWrite(EXTLED, LOW);
|
||||||
}
|
}
|
||||||
else if (batteryReportCycles == BATT_CYCLES)
|
else if (batteryReportCycles == BATT_CYCLES)
|
||||||
|
|
@ -131,6 +130,7 @@ void loop() {
|
||||||
radio.sleep();
|
radio.sleep();
|
||||||
batteryReportCycles=0;
|
batteryReportCycles=0;
|
||||||
}
|
}
|
||||||
|
motionDetected=false; //do NOT move this after the SLEEP line below or motion will never be detected
|
||||||
LowPower.powerDown(SLEEP_8S, ADC_OFF, BOD_OFF);
|
LowPower.powerDown(SLEEP_8S, ADC_OFF, BOD_OFF);
|
||||||
batteryReportCycles++;
|
batteryReportCycles++;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue