WebOS (LG) TV, Command payload syntax (service vs node-red)

Sorry to revive this but does anyone know how to use the response from a command? I am trying to duplicate the functionality of the “screen” switch from the homebridge webos tv plugin and so far I can come close but not quite.

I have a switch that calls the command service to turn the screen on & off useing com.webos.service.tvpower/power/turnOffScreen (or turnOnScreen) and that all works fine, I just cannot figure out how to get live status.

I would think I would create an automation that fires every minute or so & calls the LG command com.webos.service.tvpower/power/getPowerState and uses the response to parse the status of the screen (since it is not exposed as an attribute to HA), but I cannot figure out how to view the response to see what I need from it.

Since I cannot get even that far I have not yet had to figure out how to use the response, so I will need to figure that out also, if this is even possible.

Does anyone have any idea?

1 Like