add check for restoring almanac, and clear like suggested in the datasheet (#23153)

Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: bb7208f4c34fe70682f24a3e637b03aeaa4f719c
This commit is contained in:
Robbe Derks
2021-12-08 14:13:56 +01:00
committed by GitHub
parent 37985cb592
commit c9ef5b176e
4 changed files with 56 additions and 5 deletions
+7
View File
@@ -61,6 +61,13 @@ def configure_ublox(dev):
dev.configure_message_rate(ublox.CLASS_MON, ublox.MSG_MON_HW, 1)
dev.configure_message_rate(ublox.CLASS_MON, ublox.MSG_MON_HW2, 1)
# Query the backup restore status
print("backup restore polling message (implement custom response handler!):")
dev.configure_poll(0x09, 0x14)
print("if succesfull, send this to clear the flash:")
dev.send_message(0x09, 0x14, b"\x01\x00\x00\x00")
print("send on stop:")
# Save on shutdown