src.nth.io/

summaryrefslogtreecommitdiff
path: root/main/state_machine.h
diff options
context:
space:
mode:
Diffstat (limited to 'main/state_machine.h')
-rw-r--r--main/state_machine.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/main/state_machine.h b/main/state_machine.h
index 176b93e..8caf670 100644
--- a/main/state_machine.h
+++ b/main/state_machine.h
@@ -12,6 +12,12 @@ esp_err_t state_machine_init(void);
// ASLEEP -> backlight off, idle timer cancelled, framebuffer discarded
esp_err_t state_machine_set(viewport_run_state_t target);
+// Device-initiated variant (tap, idle timer expiry). Drives the same
+// transition as state_machine_set() and additionally enqueues a
+// {viewport,state} POST to <scrypted>/state via state_client.
+// Silently no-ops if the device is unconfigured.
+void state_machine_set_local(viewport_run_state_t target);
+
// Called by /frame after a successful paint. Restarts the idle timer
// while awake; no-op otherwise.
void state_machine_frame_painted(void);