dancol90 / ESP8266Ping

Ping library for ESP8266 Arduino core
GNU Lesser General Public License v2.1
261 stars 134 forks source link

[Feature Request] Timeout for ping #28

Open pranjal-joshi opened 4 years ago

pranjal-joshi commented 4 years ago

@dancol90 Hello, Is there any method to set timeout while pinging? If the ping is not received within the timeout, return as HOST_UNREACHABLE. I really need the timeout feature for my application where ESP needs to figure whether the network is connected to the internet or not. Something like following will be nicer to have:

Ping.setTimeout(ms);
bool status = Ping.ping(HOST);