diff --git a/Control/ref/command.cpp b/Control/ref/command.cpp index 3a014df..570c8aa 100644 --- a/Control/ref/command.cpp +++ b/Control/ref/command.cpp @@ -5,7 +5,7 @@ #define WebSocket 0 int state, totalTripDistance, currentHeading, current_x, current_y, signal_strength, lastCompletedCommand_id; // Info Control ==> Command float batteryVoltage, batteryLevel, batteryCycles; // Info Control ==> Command -int command_id, mode, reqHeading, reqDistance, reqCharge; // Info Command ==> Control +int command_id, mode, reqHeading, reqDistance, reqCharge, reqTime; // Info Command ==> Control float reqSpeed; // Info Command ==> Control void setup() {} @@ -36,9 +36,11 @@ void loop() // 0 = Stop immediately, clear command cache // 1 = Normal movement command, added to end of command cache // 2 = Normal charge command, results in no motion, added to end of command cache + // 3 = Pause command, wait for defined time in seconds, added to end of command cache tdoc["rH"] = reqHeading; tdoc["rD"] = reqDistance; tdoc["rS"] = reqSpeed; tdoc["rC"] = reqCharge; + tdoc["pSt"] = reqTime; serializeJson(tdoc, WebSocket, WebSocket); // Build JSON and send on UART1 }