Skip to content

Commit 24930dd

Browse files
committed
fixed the wrong placement of resetting the variable tried_reset
1 parent 7e2f5e6 commit 24930dd

3 files changed

Lines changed: 3 additions & 4 deletions

File tree

firmware/ATTinyDaemon/ATTinyDaemon.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
*/
2020
static const uint32_t MAJOR = 2;
2121
static const uint32_t MINOR = 14;
22-
static const uint32_t PATCH = 0;
22+
static const uint32_t PATCH = 2;
2323

2424
/*
2525
Flash size definition

firmware/ATTinyDaemon/ATTinyDaemon.ino

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -192,8 +192,6 @@ void handle_sleep() {
192192
Safe means that it is safe to use anywhere.
193193
*/
194194
void inline reset_counter_Int() {
195-
// the RPi is alive
196-
tried_reset = false;
197195
seconds = 0;
198196
}
199197

firmware/ATTinyDaemon/handleState.ino

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ void handle_state() {
5050
if (!(should_shutdown & Shutdown_Cause::rpi_initiated)) {
5151
if (should_shutdown > Shutdown_Cause::rpi_initiated && (seconds_safe < timeout)) {
5252
// RPi should take action, possibly shut down. Signal by blinking 5 times
53-
blink_led(5, BLINK_TIME);
53+
blink_led(3, BLINK_TIME);
5454
}
5555
}
5656
}
@@ -221,4 +221,5 @@ void i2c_triggered_state_change() {
221221
if (state == State::unclear_state) {
222222
state = State::running_state;
223223
}
224+
tried_reset = false;
224225
}

0 commit comments

Comments
 (0)