Comando que detecta fuera de linea en el IDE

Good morning.
I have a finished and functional project that I have found a small fault but that can be important if it stops working for a while. It is the following:
It is a centralized security system, which informs me of the status of events in all areas that are being protected through notifications.
The problem: If I turn off and turn on the home modem, the device is offline, so I must restart the device so that it stays online again.
The question: is there a routine within the Arduio IDE code that detects me if the device goes offline and does not see the server? something like BLYNK_CONNECTED () but I do not know how to tell you how long it has been on offline.
The idea is that if it takes 2 minutes without a line, an automatic reboot will be done and the device will be back online without having to manually restart it.

Thanks and regards.

There are lots of threads on this subject here on the forum, with example code. Here’s one:

and here’s another:

Pete.

Thank you.
I must confess that I did an exhaustive search on the blynk page, but obviously I did not find the results I wanted and that’s why I asked for help.
Next time, I will try to improve the search before asking.
Thanks to the indications you gave me, I have the problem solved.

1 Like

No problem. Sometimes it’s about knowing which keywords to put in the search criteria to get to results that mean something.
I’ve been hanging around the forum for about a year and a half and according to the stats I’ve read almost 35,000 posts, so it’s easier for me to recognise subject some that crop up frequently.

Glad you resolved the problem, and thanks to @Gunner for the effort he puts into his tutorials and code examples that make it easier for folks like me to point you in the right direction.

Pete.