add reeboot to ota command for testing purposes. This is a developer only command for now :-)

This commit is contained in:
Thomas Göttgens
2022-10-10 16:59:01 +02:00
parent c1b0e4e8d0
commit cfb8769746
2 changed files with 15 additions and 0 deletions

View File

@@ -458,6 +458,14 @@ class Node:
return self._sendAdmin(p)
def rebootOTA(self, secs: int = 10):
"""Tell the node to reboot into factory firmware."""
p = admin_pb2.AdminMessage()
p.reboot_ota_seconds = secs
logging.info(f"Telling node to reboot to OTA in {secs} seconds")
return self._sendAdmin(p)
def shutdown(self, secs: int = 10):
"""Tell the node to shutdown."""
p = admin_pb2.AdminMessage()