Broadcast a statusmessage when device is on?

by joq3

Hi,

I have a Mi Box Android TV, and I want to track the state of this device to integrate it to my home automation system.

What I want to acheive is to see whether the device is ON or OFF/Sleep. I have tried pinging the device, which doesn't work because the device comes online even when it is sleeping.

My next idea was to find an app which would broadcast a message somehow. Like an app that always runs in the background, and when you sleep the device the broadcasted message will disappear.

Is there an app like this?

Thank you!

HumanGoogleAssistant

Easier thing will be to connect the Mi Box to a connected socket (Say Mi Plug). You exactly know the ON/OFF status in that case. On App - Kodi can be useful provided your viewing in entirely on Kodi.