I’m using the new remote function that came in HA 2023.5 to control my Mibox 3 (Android TV with built-in chromecast). Since the box can switch on the TV over HDMI-CEC I suppose it must be possible to send that same command using the HA remote to switch on and of the TV (not the box). So I added a button with this code:
Indeed. Another integration that only works if the device is powered on all the time.
To use Android TV Remote with my JVC I found I needed a smart socket to turn on the power, an IR device to get it out of standby and an automation with lots of delays to allow the TV to pull itself together. Much more trouble than picking up the physical remote.
As far as I understand if HA is on a Raspberry Pi this is all possible. In my case I don’t use a Raspberry Pi but an i5 server. It is connected to the TV using a HDMI cable, but the motherboard of the PC doesn’t support CEC over HDMI.
An alternative could be just to add a Raspberry Pi to switch the TV on/off and adjust the volume of the TV instead of the volume of the box. But that seems a bit overkill.