Esphome Binary Sensor

Hi did anybody have this problem before or know the solution/problem?

image

esphome:
  name: regensensor-dach
  platform: ESP32
  board: esp32dev

# Enable logging
logger:

# Enable Home Assistant API
api:

ota:
  password: "xxx"

wifi:
  ssid: "xxx"
  password: "xxx"

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Regensensor-Dach"
    password: "xxx"

captive_portal:

binary_sensor:
  – platform: homeassistant
    name: "sensor 1"
    entity_id: input_boolean.prevent_deep_sleep

deep_sleep:
  run_duration: 10s
  sleep_duration: 30min
  wakeup_pin: GPIO0
  id: deep_sleep_1

Remove the quotation marks: sensor 1

1 Like

Considering the example is shown with the name in quotes I doubt that is the issue.

You are using the wrong sort of dash:

Good -
Bad – (longer)
1 Like

How do you see something like this??? :slight_smile: I didn’t see it, even with code colouring…

1 Like

The colour was the give-away. I just copied and pasted it next to a dash I new was correct to check.

2 Likes