[Revised] Disabling HAOS HDMI Output on Pi 4 without killing CEC

Background:
I am running HAOS on a Raspberry Pi 4. By default, Home Assistant outputs a CLI interface/banner to the HDMI port. Since I use the HDMI connection for CEC control (TV automations), this default video output causes my TV to auto-switch to the Pi’s input whenever the system restarts, which is highly disruptive.

Current Situation:
I am looking for a way to stop this display behavior without breaking CEC. I have been trying to solve this by modifying config.txt and cmdline.txt on the MicroSD card, but I am also open to any software-level adjustments within HAOS.

What I’ve Tested:

  • No Effect (Blue CLI banner still visible):
    • cmdline.txt: console=null, quiet, loglevel=0, console=serial0,115200.
    • config.txt: hdmi_blanking=1, disable_splash=1.
  • Killed Video BUT also Killed CEC (Unusable):
    • config.txt: hdmi_ignore_hotplug=1 and hdmi_enable_4kp60=0.
    • Result: This successfully stopped the video signal, but it also disabled the CEC bus, making TV control via Home Assistant impossible.

The Goal:
I need to “silence” the video signal or stop the CLI from occupying the HDMI port so the TV doesn’t detect an active input, while keeping the physical HDMI-CEC link alive for automations.

Questions:

  1. Is there a way to disable the framebuffer or “blank” the output on HAOS without the Pi 4 thinking the HDMI is completely disconnected?
  2. Are there any internal HAOS services (like getty) that can be disabled to prevent the CLI from drawing to the screen?

I don’t think you can separate the HDMI display from CEC. You might check to see if there is a setting on your HDMI switcher (the TV, AVR, or whatever it is your using to switch ports) for auto switching to the “active” HDMI port. If you can disable that, then the device won’t keep switching HDMI inputs. The drawback is that you may have to tell the switcher when to change (either with CEC commands or some other control mechanism).