[ST Edge] How to check online/offline status of device in a routine?

You could try the following but it requires a constantly running PC or RPi.