From 84c5bfd799ad8b997a0d4d34c00bf9ba80cd83a4 Mon Sep 17 00:00:00 2001 From: clerie <git@clerie.de> Date: Thu, 3 Apr 2025 21:49:12 +0200 Subject: [PATCH] Add nodes/d1-mini-on-air-3f5817 --- nodes/d1-mini-on-air-3f5817/.gitignore | 5 ++ nodes/d1-mini-on-air-3f5817/firmware.yaml | 85 +++++++++++++++++++++++ 2 files changed, 90 insertions(+) create mode 100644 nodes/d1-mini-on-air-3f5817/.gitignore create mode 100644 nodes/d1-mini-on-air-3f5817/firmware.yaml diff --git a/nodes/d1-mini-on-air-3f5817/.gitignore b/nodes/d1-mini-on-air-3f5817/.gitignore new file mode 100644 index 0000000..d8b4157 --- /dev/null +++ b/nodes/d1-mini-on-air-3f5817/.gitignore @@ -0,0 +1,5 @@ +# Gitignore settings for ESPHome +# This is an example and may include too much for your use-case. +# You can modify this file to suit your needs. +/.esphome/ +/secrets.yaml diff --git a/nodes/d1-mini-on-air-3f5817/firmware.yaml b/nodes/d1-mini-on-air-3f5817/firmware.yaml new file mode 100644 index 0000000..a76e68f --- /dev/null +++ b/nodes/d1-mini-on-air-3f5817/firmware.yaml @@ -0,0 +1,85 @@ +--- + +substitutions: + macsuffix: "3f5817" + +wifi: + power_save_mode: LIGHT + +improv_serial: + +script: + - id: set_light_on_air + then: + - light.turn_on: + id: indicator + red: 1 + green: 0 + blue: 0 + effect: "None" + brightness: 70% + - id: set_light_online + then: + - light.turn_on: + id: indicator + red: 0.9 + green: 0.9 + blue: 0.9 + effect: "None" + brightness: 40% + - id: set_light_disconnected + then: + - light.turn_on: + id: indicator + red: 0 + green: 0 + blue: 0 + effect: "None" + brightness: 0% + +esphome: + name: "d1-mini-on-air-${macsuffix}" + +esp8266: + board: d1_mini + +captive_portal: + +logger: + level: DEBUG + logs: + light: INFO + +web_server: + port: 80 + +api: + reboot_timeout: 0s + +button: + - platform: template + name: "${macsuffix} Disconnected" + on_press: + - script.execute: + id: set_light_disconnected + - platform: template + name: "${macsuffix} Off-Air" + on_press: + - script.execute: + id: set_light_online + - platform: template + name: "${macsuffix} On-Air" + on_press: + - script.execute: + id: set_light_on_air + +light: + - platform: neopixelbus + id: indicator + name: "${macsuffix} Light" + type: GRB + variant: WS2812 + pin: GPIO0 + num_leds: 17 + initial_state: + state: off