How to discover status of an end device ?


#1

How to discover status of an end device (switch, motion sensor, water sensor …etc) ?

An action triggered when device status is OFFLINE

3) What is happening/not happening?

It appears that WebCore/Smartthing don’t correctly sense a status of SOME end-devices. For example, device is unplugged from power or batter is removed and device status (in Smartthings) still shows ONLINE

I have tried:

IF device’s healthStatus changes status to OFFLINE

then

blah blah

But it does not work.

Are you aware of a different way of discovering status ? or perhaps a way to force devices refresh ?

Thx, Walter


#2

Device Health is rather arcane. Getting ST to cough up as to how it is meant to be working has always been largely fruitless.

The meaning of the ONLINE/OFFLINE status is rather device dependent anyway. For hub connected devices OFFLINE represents an absence of expected activity. For sleepy end devices that don’t send out regular reports the chances are the status is simply that of the hub, while if a device reports daily it may take a two days before SmartThings considers it offline. Once a device is OFFLINE it might not be considered ONLINE again until manual action is taken.

As far as I know it isn’t possible to use the healthStatus or DeviceWatch-DeviceStatus attributes to monitor hub connected devices anymore (that went several months ago). The healthStatus attribute might perhaps still work for cloud connected devices using the schema integration as that was how the status was meant to be communicated.

In webCoRE the $status attribute should reflect the same status shown in the IDE but it can’t be triggered on.

In the current environment, not the legacy environment of the IDE and webCoRE, the status is available via the REST API and can be subscribed to and that will be the area that is evolving.