-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Description
Hello,
Maybe the feature is already available, if so tell me.
I'm using sensors (GPS) that give info not every time step (usually every 1s). However, at each timestep I get the value of the last update, and I've no way of telling if it's the old value or if I'm simply standing still. So I have to implement another timer with the same period that warn me when my value are new. It's very inconvenient, and add synchronisation issue.
Use case : I have a simple GPS receiver that, IRL give me a message every 1sec. The rest of the time, I have no value, and my process know is should 'fill the gap", instead of relying on a steady value.
Would it be possible to know when the data is new ? Without breaking existing behaviour (return last value), I would simply add a new API targeting devices (bool wb_is_updated(WbDevice)), which say True at the timestep during which the value have been updated, and False otherwise.
What do you think ?
Cheers