Fix "speed" bug
This commit is contained in:
parent
f5db4cb95d
commit
8974afab32
3
main.c
3
main.c
@ -373,13 +373,14 @@ ISR(TIMER1_OVF_vect) {
|
||||
}
|
||||
|
||||
if (exec > 0) {
|
||||
const uint8_t old_exec = exec;
|
||||
exec = -1;
|
||||
MCUCR &= ~(1 << SE);
|
||||
sei();
|
||||
read_sensors();
|
||||
// если измерений 6 (и мало ли больше), то отправляем смс
|
||||
// если под скоростью, то тоже отправляем смс
|
||||
if (exec == 2 || sensor_measurements >= MEASUREMENTS) {
|
||||
if (old_exec == 2 || sensor_measurements >= MEASUREMENTS) {
|
||||
try_to_send_telemetry();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user