You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the Sedani serial reading is handled unsafely and could potentially end up with lost data from serial. This may happen because we only check for the first '$' character, not that the whole message is there. Serial does not guarantee our whole message shows up at once.
This can safely happen with having an terminating character (like a ';' or newline) and then knowing you have a full command. This is the thing to definitely implement.
We may also want to update to a non-blocking method, where we read each character individually to a buffer, but this may be bad as we may be late reading the whole message while other code runs. This may be something to investigate usefulness.
Currently the Sedani serial reading is handled unsafely and could potentially end up with lost data from serial. This may happen because we only check for the first '$' character, not that the whole message is there. Serial does not guarantee our whole message shows up at once.
This can safely happen with having an terminating character (like a ';' or newline) and then knowing you have a full command. This is the thing to definitely implement.
We may also want to update to a non-blocking method, where we read each character individually to a buffer, but this may be bad as we may be late reading the whole message while other code runs. This may be something to investigate usefulness.
A medium google search says see this link for code: http://forum.arduino.cc/index.php?topic=288234.0
The text was updated successfully, but these errors were encountered: