# HDMI-CEC Gateway Project – Testing Invitation

:loudspeaker: New Project Available for Testing

We have created a complete HDMI-CEC Gateway solution for Home Assistant that enables you to control your TV and HDMI-connected devices directly from Home Assistant.

:bullseye: What is it?

A cost-effective setup using a SMLIGHT SLWF-08 adapter (~$10-15) that acts as an HDMI-CEC gateway. It captures all CEC signals from your television and other HDMI devices, forwarding them to Home Assistant for full automation and remote control capabilities.

Repository: HDMI-CEC-Gateway-with-SMLIGHT-SLWF-08-for-HomeAssistant

:sparkles: Features

  • :white_check_mark: Full TV Control – Power on/off, volume, HDMI input switching, navigation
  • :white_check_mark: ESPHome Firmware – Pre-configured and ready to flash
  • :white_check_mark: Home Assistant Package – Scripts, automations, and event handlers included
  • :white_check_mark: Ready-to-Use Dashboard – Visual remote control interface
  • :white_check_mark: Event Integration – Trigger automations based on TV events (e.g., dim lights when TV turns on)
  • :white_check_mark: Multi-Brand Support – Philips (EasyLink) fully tested, Samsung (Anynet+) supported
  • :white_check_mark: Open Source – MIT License

:package: Project Contents

esphome/
β”œβ”€β”€ hdmi-cec-gateway.yaml       # Firmware for SLWF-08
└── secrets.yaml.example        # WiFi credentials template

homeassistant/
β”œβ”€β”€ packages/cec.yaml           # HA scripts, automations & event handlers
└── dashboards/cec_dashboard.yaml  # Pre-built remote control UI

docs/
└── cec-opcodes.md              # CEC opcode reference for customization

:rocket: Quick Start

  1. Flash the SLWF-08 with the provided ESPHome firmware
  2. Add the HA package to your Home Assistant configuration
  3. Configure your TV model (Philips/Samsung)
  4. Import the dashboard for instant remote control
  5. Done! All 30+ commands are ready to use

:test_tube: We’re Inviting Testers

This project is ready for community testing and feedback. If you have:

  • A compatible TV (Philips, Samsung, or similar CEC-enabled TV)
  • Home Assistant running
  • Basic ESPHome experience

Please consider testing this project and providing feedback!

:clipboard: Testing Checklist

  • ESPHome firmware flashing
  • Home Assistant device discovery
  • Basic commands (power, volume, navigation)
  • HDMI input switching
  • Dashboard functionality
  • Event triggering in automations
  • Compatibility with your TV model

:memo: Feedback & Support

Found an issue? Have a suggestion? Please:

  • Open an issue on GitHub
  • Share your TV model and results
  • Suggest improvements for the documentation

:light_bulb: Typical Use Cases

  • Smart Home Integration – Turn on lights when TV powers on, close blinds automatically
  • Voice Control – Combine with voice assistants via Home Assistant
  • Activity Automation – Trigger β€œMovie Time” scenes with proper settings
  • Device Synchronization – Control receivers, soundbars, and other HDMI devices
  • Remote Anywhere – Control TV from anywhere via Home Assistant

Give it a try and let the developer know how it goes! :clapper_board::television:


Project: HDMI-CEC Gateway with SMLIGHT SLWF-08 for Home Assistant
License: MIT | Platform: ESPHome 2026 | Status: Ready for Testing

My experience with CEC has been great so far. A use case was turning on the TV to display a live camera feed. Turning on the TV proved to be the most challenging. All the integrations I tried - like Android Remote, ADB Bridge, Wake-on-LAN - were unreliable in this regard (probably due to the TV going into deep sleep mode).

Then I learned about CEC and realized I could use it through my RPi5/Kodi, which I have connected to the TV. It works 100% of the time, every time :slight_smile:

Great to hear! Here’s what our SLWF-08 gateway can do for you:

:white_check_mark: What We Support

Your Use Case (TV Power-On + Camera Display):

  • Turn TV on reliably via CEC (100% success rate, even from deep sleep)
  • Switch HDMI inputs to your camera device
  • Trigger from Home Assistant automations (motion, doorbell, time-based, etc.)

Full Control:

  • Volume, mute, navigation, HDMI switching
  • Playback control (play, pause, stop, forward, rewind)
  • Numeric keypad

Automation Integration:

  • React to CEC events (TV on/off, input changes, etc.)
  • Trigger lights, blinds, or other devices based on TV activity

:clapper_board: Example: Your Use Case

script:
  camera_on_tv:
    sequence:
      - service: script.cec_tv_on        # Power on TV (CEC – reliable!)
      - delay: "00:00:02"
      - service: script.cec_hdmi1        # Switch to camera input

automation:
  - alias: "Motion β†’ Show Camera on TV"
    trigger: binary_sensor.front_door_motion
    action: script.camera_on_tv

:light_bulb: vs. Your RPi5/Kodi Setup

Feature Kodi CEC SLWF-08
Reliable TV power-on :white_check_mark: :white_check_mark:
Works without Kodi running :cross_mark: :white_check_mark:
Full HA automation triggers Limited :white_check_mark:
Lightweight/low resource :cross_mark: :white_check_mark:

Bottom line: Works as a standalone solution OR complements your existing setup with redundancy.


Try it out and let us know! β†’ GitHub - DocBig/HDMI-CEC-Gateway-with-SMLIGHT-SLWF-08-for-HomeAssistant: Control your TV and connected devices via HDMI-CEC from Home Assistant using a SMLIGHT SLWF-08 adapter – ESPHome firmware, HA package, and a ready-to-use dashboard included Β· GitHub

How about a potato? Can I connect to that?

Only if it’s a smart potato with CEC support :potato:
But seriously – any HDMI-CEC compatible device works!

Any ideas on a PoE version? I built one, but I would love an off-the-shelf solution.

I am using the device and most things work well. I am struggling with a LG tv. I can get it to work manually to turn on and turn off the TV but when I try to incorporate using my receiver and Apple TV, it turns it on Apple TV turns on and everything seems to work, but when I power it off the TV turns back on after about five seconds. I am sure it’s an issue with the TV possibly but when I go to the Manuel button to turn off the TV on the CEC settings, it turns off immediately and it does not turn on and it is consistent. I have included my YAML code for any feedback.

esphome:
name: cec-adapter
friendly_name: CEC Adapter

esp8266:
board: esp12e

wifi:
networks:
- ssid: "home Wifi"
password: "pablo123"

logger:

api:

ota:

  • platform: esphome

external_components:

  • source: github://Palakis/esphome-hdmi-cec

hdmi_cec:
id: cec
pin: GPIO14
address: 0x01
physical_address: 0x2000

button:

  • platform: template
    name: "TV On"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x04]
    • delay: 1500ms
    • hdmi_cec.send:
      destination: 0xF
      data: [0x82, 0x20, 0x00]
  • platform: template
    name: "TV Off"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x36]
  • platform: template
    name: "HDMI 2 Active Source"
    on_press:

    • hdmi_cec.send:
      destination: 0xF
      data: [0x82, 0x20, 0x00]
  • platform: template
    name: "Volume Up"
    on_press:

    • hdmi_cec.send:
      destination: 0x5
      data: [0x44, 0x41]
    • delay: 300ms
    • hdmi_cec.send:
      destination: 0x5
      data: [0x45]
  • platform: template
    name: "Volume Down"
    on_press:

    • hdmi_cec.send:
      destination: 0x5
      data: [0x44, 0x42]
    • delay: 300ms
    • hdmi_cec.send:
      destination: 0x5
      data: [0x45]
  • platform: template
    name: "Mute"
    on_press:

    • hdmi_cec.send:
      destination: 0x5
      data: [0x44, 0x43]
    • delay: 300ms
    • hdmi_cec.send:
      destination: 0x5
      data: [0x45]

=======================

:downwards_button: ADDED: Navigation / App Control

=======================

  • platform: template
    name: "CEC Home"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x44, 0x09] # Home
    • delay: 300ms
    • hdmi_cec.send:
      destination: 0x0
      data: [0x45]
  • platform: template
    name: "CEC Up"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x44, 0x01]
    • delay: 200ms
    • hdmi_cec.send:
      destination: 0x0
      data: [0x45]
  • platform: template
    name: "CEC Down"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x44, 0x02]
    • delay: 200ms
    • hdmi_cec.send:
      destination: 0x0
      data: [0x45]
  • platform: template
    name: "CEC Left"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x44, 0x03]
    • delay: 200ms
    • hdmi_cec.send:
      destination: 0x0
      data: [0x45]
  • platform: template
    name: "CEC Right"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x44, 0x04]
    • delay: 200ms
    • hdmi_cec.send:
      destination: 0x0
      data: [0x45]
  • platform: template
    name: "CEC Select"
    on_press:

    • hdmi_cec.send:
      destination: 0x0
      data: [0x44, 0x00]
    • delay: 200ms
    • hdmi_cec.send:
      destination: 0x0
      data: [0x45]