Esp32 turn on led

I’m trying to turn on a led with a esp32 on the new homey pro 2023. i now have my esp32 connected to my Homey with Homeyduino. But now i am searching for a script to turn on and turn off the led but i cant find it and everything i found is not working. is their maybe something wrong with te connection to the Homey.

To me, the ESPhome app is easier to use. You might want to check it out.

1 Like

alright do you have a script for that?

Did you read the fine manual?

I am looking at that now but i dont know how to connect it to my homey

The ESPHome app for Homey was already linked to.

I have that app already but i cant get it connected to my homey

You have to be a bit more forthcoming if you want help, nobody here has any idea why you can’t get it working if you don’t provide more information, like the YAML file that you’re using for your ESPHome project, if you’re getting any errors, etc.

Most app have its own app topic here, often with manuals, howto, FAQ.
These links can be found at the app page at store

While I checked it already,
here you go

This app developer wrote an outstanding fine manual, but take your time to read it I’d like to say.

peter thank you i took a look at it now but i dont have the software i think to get the esp connected. what sofware should i get?

You’re welcome, Niels.

Robert linked to it already, but here you go

i have downloaded the python and installed the esphome but do you need the home assistant app and is it possible to connect a canbus this way or not.

No, you need the ESPHome app for Homey.

I feel that most of your questions can easily be answered by just doing a basic search with Google or on the ESPHome website.

sorry but i am still new and i trie to figure it out. I have never heard of a yaml file and a command promt and i have no idea how to get a code on a esp32 using that. I have configured the esphome wizard and got it connected to the wifi. and found it on the esphome app but when i leave the esphome wizard on homey it is gone.


Perhaps ask a specific question in the ESPHome app thread.

Hello again,

i now have dowloaded esphome and it all works with my homey. I now try to turn on a led with a canbus signal i have search on the esphome site and i can read a massage and send one. but i cant figure out how to read a massage and then toggle the led everytime i read the massage this is my yaml script

  name: led

  board: nodemcu-32s
    type: arduino

# Enable logging

# Enable Home Assistant API
  password: "0641312666"

  password: "0641312666"

  ssid: "SewerRobotics"
  password: "0641312666"

  # Enable fallback hotspot (captive portal) in case wifi connection fails
    ssid: "Led Fallback Hotspot"
    password: "UHa6BfRFXMQy"


  - platform: esp32_can
    tx_pin: GPIO23
    rx_pin: GPIO22
    can_id: 4
    bit_rate: 125kbps
    - can_id: 43 # the received can_id
        - if:
              lambda: 'return (x.size() > 0) ? x[0] == 0x11 : false;'
              light.toggle: led1

  sda: GPIO26
  scl: GPIO27

# Example configuration entry
  - platform: ultrasonic
    trigger_pin: GPIO5  # Verbind met de Trig-pin van de HC-SR04
    echo_pin: GPIO4  
    name: "Ultrasonic Sensor"
    update_interval: 2s

  - platform: dht
    pin: GPIO25
      name: "Living Room Temperature"
      name: "Living Room Humidity"
    update_interval: 60s

  - platform: gpio
    pin: GPIO12
    id: my_output
  - platform: gpio
    pin: GPIO14
    id: my_output1

  - platform: binary
    name: "My Monochromatic Light"
    output: my_output
    id: led1
  - platform: binary
    name: "My Monochromatic Light1"
    output: my_output1

do anyone see what i am doing wrong?

1 Like

i have find it i was sending the wrong id with the canbus signal

1 Like