How could I check whether device is online using Qt?
-
Is there any effective way to check whether a certain device is online, the device may vary from desktop to mobile devices.
By the way, I used QNetworkConfigurationManager::isOnline( ) to do this task, but unfortunately, when I closed my desktop connection ( Ubuntu 15.04 Enable network unchecked ), this function returned true as always, I bet because there was a lo ( loopback ) adapter is always active within my desktop, so it always returned true. -
I woulden't know actually. I think there will be one but why not make it yourself? It's not really complicated.
The slaves emit a certain data string to the master indicating them being alive once every 5 minutes for instance. The master keeps track of the slaves and knows when it doesn't receive anything from a slave after 5 mins its offline and perhaps could try to request its status in case the packet got lost or something similar.