Node-Red >> Nvidia shield only shows "state" (playing, paused of, etc) when casting, NOT on apps!

Hi everybody.

I am running into a problem with my Nvidia shield state in Node-Red.
I want to run some automation in Node-Red, during a specific state (playing, paused, off, etc) but it only shows those states during casting, not while playing something on Netflix, Youtube, or another app.

I tried the following in the hope it would fix it, but nothing yet:

  • Rebooted my Nvidia shield
  • Rebooted Node-Red
  • Rebooted the Home assistant server
  • Turned on USB debugging on the Nvidia shield.

I really don’t know what else to do to find the problem.
Does anyone have a solution to find the problem and to fix the “off” state for apps?

Here is a screenshot, and I know it is playing at this moment, so it should give met the “playing” state. But instead, it gives me the “off” state.

And these are some states when casting:

I don’t believe this is actually an issue with nodered. Your sensor is not reporting correctly, so check the setup. If i remember correctly, for my AndroidTV sensors I had to check the most common apps and add to the configuration to reliably detect the state. Look here for reference:

Custom State Detection:

I followed the beginning of this tutorial, and I think turning on the “Network Debugging” did the trick.
But I also did put the piece of code in the Yaml file:


  • platform: androidtv