Skip to content
Snippets Groups Projects
Commit 10cfb0cc authored by norpol's avatar norpol
Browse files

Add closing of sensor on KeyboardInterrupt to avoid spamming console

parent f1818479
Branches
Tags
No related merge requests found
......@@ -384,4 +384,8 @@ def main():
if __name__ == "__main__":
main()
try:
main()
except KeyboardInterrupt as e:
sensor.close()
raise e
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment