grSim icon indicating copy to clipboard operation
grSim copied to clipboard

Stop the robots when the stop receiving packages for 1 sec

Open Bollos00 opened this issue 3 years ago • 5 comments

Identify the Bug

Closes #166

Description of the Change

  • Whenever a socket is received from blueControlSocket, the QElapsedTimer elapsedLastPackageBlue is restarted.
  • The function MainWindow::update will check every time it is called if elapsedLastPackageBlue has not been restarted for more than one second. If the condition is true, it will stop all blue robot. A similar/equivalent approach was made for the yellowControlSocket.

Alternate Designs

Nothing.

Possible Drawbacks

  • It does not turn the roller and the kick (I still did not find the proper way of doing so);
  • I am still testing it.

Verification Process

Release Notes

Stop the robots when the stop receiving packages for 1 second

Bollos00 avatar Oct 02 '21 04:10 Bollos00

@mahi97 I tested it with a match test and I think this pull request is ready for review now.

One question, should I change something on the piece of code complained bu the CodeFactor?

Bollos00 avatar Oct 03 '21 03:10 Bollos00

@g3force this pull request is open for quite some time now... do I need to change anything before the pull request is merged?

Bollos00 avatar Feb 14 '22 06:02 Bollos00

@g3force what about now?

Bollos00 avatar Feb 17 '22 02:02 Bollos00

I've fixed the pipelines on master und updated your branch to see if everything is green.

Also, please use the GitHub review functions: image

Press the cyclic arrows to rerequest review.

g3force avatar Feb 17 '22 08:02 g3force

And please fix the CodeFactor issue. One method you modified is too complex now. Move code into a new method.

g3force avatar Feb 17 '22 08:02 g3force