#pragma once namespace kvida { // Creates the sandboxed Lua state and loads the default script (see // src/default_script.h). The script only *defines* the on_tick() // function -- call lua_runtime_tick() to actually run it. Call once at // boot. void lua_runtime_init(); // Calls the script's on_tick() global function -- one "wake, execute // Lua, publish changes, sleep" cycle, per AGENTS.md's power philosophy. // A Lua runtime error is logged, not fatal: a script bug shouldn't take // down the device. void lua_runtime_tick(); } // namespace kvida