File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -92,6 +92,11 @@ void menuSystem()
9292
9393 Serial.println (F (" r) Reset all settings to default" ));
9494
95+ // Support mode switching
96+ Serial.println (F (" B) Switch to Base mode" ));
97+ Serial.println (F (" R) Switch to Rover mode" ));
98+ Serial.println (F (" W) Switch to WiFi Config mode" ));
99+
95100 Serial.println (F (" x) Exit" ));
96101
97102 byte incoming = getByteChoice (menuTimeout); // Timeout after x seconds
@@ -120,6 +125,19 @@ void menuSystem()
120125 xSemaphoreGive (xFATSemaphore);
121126 }
122127 }
128+ // Support mode switching
129+ else if (incoming == ' B' ) {
130+ forceSystemStateUpdate = true ; // Imediately go to this new state
131+ changeState (STATE_BASE_NOT_STARTED);
132+ }
133+ else if (incoming == ' R' ) {
134+ forceSystemStateUpdate = true ; // Imediately go to this new state
135+ changeState (STATE_ROVER_NOT_STARTED);
136+ }
137+ else if (incoming == ' W' ) {
138+ forceSystemStateUpdate = true ; // Imediately go to this new state
139+ changeState (STATE_WIFI_CONFIG_NOT_STARTED);
140+ }
123141 else if (incoming == ' x' )
124142 break ;
125143 else if (incoming == STATUS_GETBYTE_TIMEOUT)
You can’t perform that action at this time.
0 commit comments