Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 106202

Command Line Sensor Slow To Update

$
0
0

I’m working with an older Onkyo AVR (vsx-lx102) that I have in a closet in my garage.
The Onkyo AVR Media Player integration doesn’t really fit my need so my I’m building a page with my own controls for input, volume, power, etc. I’ll focus on Volume for the purpose of this question.

I’ve successfully built the controls utilizing eiscp shell commands to the device. I can control the volume up and down, and can retrieve the current volume from the device as well.

I use this shell command to control the volume:

shell_command:
     onkyo_volume_up: onkyo --host 192.168.2.67 volume=level-up-1db-step

I execute the command via script:

 alias: scrpt_Onkyo_Volume_Up
 sequence:
   - service: shell_command.onkyo_volume_up
     target:
       entity_id: sensor.onkyo_current_volume

The volume_up shell command returns a value of “unknown-model: master-volume = 46” showing the now current volume. I use template sensor to format the output to just “46”.

I’m then displaying the current volume template sensor on my dashboard.

The problem is that when I press the volume up, there can be as much as a 10 second delay in the template volume sensor updating. The response is instant from the volume up command, so I’m not sure why there is such a delay in updating the sensor.

Is there a more efficient way of accomplishing this?

EDIT:
It just dawned on me that it’s possible that the firing of the script is the slow part, and not the return of the data. Is there an easy way to troubleshoot this?

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 106202

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>