mirror of
https://github.com/modelec/TCPSocketServer.git
synced 2026-01-19 00:47:36 +01:00
timeout
This commit is contained in:
@@ -427,11 +427,11 @@ void TCPServer::checkIfAllClientsReady()
|
||||
void TCPServer::startGame() {
|
||||
for (int i = whereAmI; i < stratPatterns.size(); i++) {
|
||||
|
||||
/*auto time = std::chrono::system_clock::now();
|
||||
auto time = std::chrono::system_clock::now();
|
||||
if (time - gameStart > std::chrono::seconds(82)) {
|
||||
this->goEnd();
|
||||
return;
|
||||
}*/
|
||||
}
|
||||
|
||||
switch (stratPatterns[i]) {
|
||||
case TURN_SOLAR_PANNEL_1:
|
||||
@@ -734,10 +734,10 @@ void TCPServer::awaitRobotIdle() {
|
||||
usleep(50'000);
|
||||
this->sendToClient("strat;arduino;get state;1\n", this->arduinoSocket);
|
||||
timeout++;
|
||||
/*if (timeout > 30) {
|
||||
if (timeout > 30) {
|
||||
this->broadcastMessage("strat;arduino;clear;1");
|
||||
break;
|
||||
}*/
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user