merdok / homebridge-webos-tv

Homebridge plugin for LG webOS TVs
MIT License
664 stars 89 forks source link

Volume slider doesn’t work with eARC/CEC #369

Closed luigi-lauro closed 3 years ago

luigi-lauro commented 3 years ago

I have a setup with a LG OLED connected to a Denon amplifier, with sound mode on the TV set to ARC. I have also another LG OLED with a Lg sound bar connected with eARC. Both for TV native apps and sources going through Denon or Soundbar, volume changing through TV remote or through native HomeKit integration (remote from iOS control center, with physical iPhone buttons) correctly changes the Denon/Soundbar volume using HDMI-CEC integration, since the TV volume is disabled (sound mode is only ARC, so integrated speakers are disabled). With plug-in instead TV volume slider doesn't change anything at all, my guess is that it changes the TV internal speakers volume, but it's completely useless in my setup since they are disabled for both TVs. The plug-in should change the Denon volume through HDMI-CEC to be useful and also to be consistent with the behavior of the TV own remote (when sound mode set to ARC it changes the connected amplifier/sound bar through HDMI-CEC).

merdok commented 3 years ago

This is a known issue and is also documented in the tv configurations section here: https://github.com/merdok/homebridge-webos-tv#tv-configuration-fields Unfortunately this is an issue with the TV itself, the TV just does not allow to set a custom volume level when ARC is used. Although you can use the volume buttons as a workaround for that, but they only allow incremental volume increase or decrease.

luigi-lauro commented 3 years ago

Thank you Merdok, clear now. I guess it's because HDMI-CEC implementation doesn't support absolute volume but just UP/DOWN. I don't think it's stated very clearly in the documentation you referenced though. My suggestion is to add it in the known issues explicitly to avoid further questions on the topic. Thanks! :-)

luigi-lauro commented 3 years ago

One small suggestion as a software engineer myself: I think it would it be possible to add in configuration options for the TV which bulb/fan already present in HomeKit/Homebridge (if any) represent eARC volume. This way it sound mode set uses internal speaker the volume of the slider changes the normal TV volume, if instead the sound mode is set to ARC or similar which you cannot control directly, it will read and write the other HomeKit bulb/fan slider if set in configuration options optionally. I have also my Denon in HomeKit and this would allow me to have a consistent setup (turn on TV and change volume directly from there instead of switching to other accessory for that). Considering my setup may be not so uncommon, I think could be worth the trouble. Your take, just a suggestion :-)