Closed Segath closed 5 years ago
For database connection, there is no persistent connection, whenever data is stored, a connection is opened, the query is executed and then the connection is closed, if it fails to do this we can just print the exception message to the log for ex, and maybe change some icon, and if it successfully executes another, change icon to greenish, or just use logger?
As for communication between rover and control station, the rover could send a heartbeat to the multicast address? And we simply update a timer, if the rover sends no packet in X sec we display a fault indication?
The rover most likely will send updates about the same interval, I hope, so we can then use your idea to put a timer in the connection thread to check if the timer runs out. If it runs out, then send a signal to the status board and logger about the error.
Yeah, hopefully!
The reason for the database connection part was because of a problem I encountered with the project in programvareutvikling where the Azure MySql database dropped my connection after two minutes of inactivity. But it sounds like we won't face that problem.
Create a widget that displays the status in text or image (for example: red light, green light) of modules on the control station. These may be for:
Gamepad status, check if the gamepad is active/connected
Database, check if there is a connection to the database, do we have a reconnect method?.
Communication, from control station to rover would be difficult, but can have for rover to control station.
How and when should we check for these statuses and update the widget? Data from rover could update them, but we need something else to update if the data from the rover stops.