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
The timeval structure already allows specifying timeouts in both seconds and microseconds.
This means that if the default values of the timeout (PING_DEFAULT_TIMEOUT) or interval(PING_DEFAULT_INTERVAL) are overriden, they would not have any issue in running in another unit of time with some obvious code changes.
The downside is that it will not be backward compatible with whoever is already overriding the default values. This means that upgrading to the latest version with a default of 2 seconds of timeout, will be transformed in a default of 2 milliseconds of timeout.
Proposed solution is to bring another definition to switch between seconds and milliseconds with a default to seconds, to keep current functionality untouched.
The text was updated successfully, but these errors were encountered:
Hi, is there an update to this? I have exactly the same issue. I'd like to specify a much shorter timeout value.
This particular library has it https://github.com/bluemurder/esp8266-ping which I believe this one for the ESP32 was built off it.
Thank you.
As mentioned in discussions of issue #25 (Setting timeout or interval lower than 1 second is not possible)
The
timeval
structure already allows specifying timeouts in both seconds and microseconds.This means that if the default values of the timeout (
PING_DEFAULT_TIMEOUT
) or interval(PING_DEFAULT_INTERVAL
) are overriden, they would not have any issue in running in another unit of time with some obvious code changes.The downside is that it will not be backward compatible with whoever is already overriding the default values. This means that upgrading to the latest version with a default of 2 seconds of timeout, will be transformed in a default of 2 milliseconds of timeout.
Proposed solution is to bring another definition to switch between seconds and milliseconds with a default to seconds, to keep current functionality untouched.
The text was updated successfully, but these errors were encountered: