Add standard main entry point (#1)
Browse files- Add standard main entry point (8ad2905cfe7d71bdded6fbf302b293ea02327d35)
red_light_green_light/main.py
CHANGED
|
@@ -192,3 +192,11 @@ class RedLightGreenLightApp(ReachyMiniApp):
|
|
| 192 |
while not stop_event.is_set():
|
| 193 |
sequence()
|
| 194 |
scan()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 192 |
while not stop_event.is_set():
|
| 193 |
sequence()
|
| 194 |
scan()
|
| 195 |
+
|
| 196 |
+
if __name__ == "__main__":
|
| 197 |
+
app = RedLightGreenLightApp()
|
| 198 |
+
try:
|
| 199 |
+
app.wrapped_run()
|
| 200 |
+
except KeyboardInterrupt:
|
| 201 |
+
app.stop()
|
| 202 |
+
|