Edit esp-bedside-panel.yaml
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
# https://home.fox.co.nz/gitea/zorruno/zorruno-homeassistant/src/branch/master/esphome/esp-bedside-panel.yaml
|
||||
#:########################################################################################:#
|
||||
# VERSIONS:
|
||||
# V1.31 2026-07-19 Added TEMT6000 ambient-light voltage and illuminance sensors
|
||||
# V1.30 2026-07-18 Made Downstairs Guests red when occupied and removed duplicate OTA config
|
||||
# V1.29 2026-07-18 Perfected Atto charging alignment and expanded Security states
|
||||
# V1.28 2026-07-18 Restyled Atto Charging as top-row data with active red background
|
||||
@@ -89,6 +90,7 @@
|
||||
# - Touch I2C address: 0x5D
|
||||
# - Battery-backed RTC: RX8130
|
||||
# - RTC I2C address: 0x32
|
||||
# - TEMT6000 ambient-light sensor signal: GPIO20 / ADC1
|
||||
#:########################################################################################:#
|
||||
# OPERATION NOTES:
|
||||
# - This build returns to the proven V0.8a structure.
|
||||
@@ -113,6 +115,8 @@
|
||||
# - The Climate page contains heat-pump, ceiling-fan, air-filter and Night Power controls.
|
||||
# - Sleep: 2 hrs starts a local 120-minute countdown and turns the heat pump off.
|
||||
# - Pressing the active Sleep button again cancels the countdown.
|
||||
# - TEMT6000 voltage and approximate lux are exposed for initial calibration.
|
||||
# - Automatic backlight adjustment is not enabled in this revision.
|
||||
#:########################################################################################:#
|
||||
# OFFLINE NOTES:
|
||||
# - LVGL, the clock, touch and backlight operate locally.
|
||||
@@ -131,12 +135,12 @@ substitutions:
|
||||
# Device Naming
|
||||
device_name: "esp-bedside-panel"
|
||||
friendly_name: "ESP Bedside Panel"
|
||||
description_comment: "Guition JC1060P470C_I_W_Y ESP32-P4 bedside control panel. Red occupied guest state, green-bordered inactive state and OTA configuration cleanup. (Layout V1.1)"
|
||||
description_comment: "Guition JC1060P470C_I_W_Y ESP32-P4 bedside control panel. TEMT6000 ambient-light sensing added for calibration and future automatic backlight control. (Layout V1.1)"
|
||||
device_area: "Bedroom"
|
||||
|
||||
# Project Naming
|
||||
project_name: "Guition.JC1060P470C_I_W_Y"
|
||||
project_version: "v1.30"
|
||||
project_version: "v1.31"
|
||||
|
||||
# Passwords & Secrets
|
||||
api_key: !secret esp-api_key
|
||||
@@ -151,6 +155,11 @@ substitutions:
|
||||
backlight_pin: "GPIO23"
|
||||
backlight_frequency: "1220Hz"
|
||||
|
||||
# Ambient Light Sensor Settings
|
||||
# TEMT6000: VCC=3V3, GND=GND, SIG/OUT=GPIO20.
|
||||
ambient_light_pin: "GPIO20"
|
||||
ambient_light_update_interval: "1s"
|
||||
|
||||
# Touchscreen Settings
|
||||
touch_sda_pin: "GPIO7"
|
||||
touch_scl_pin: "GPIO8"
|
||||
@@ -699,6 +708,50 @@ sensor:
|
||||
id: wifi_signal_sensor
|
||||
update_interval: "${update_interval}"
|
||||
|
||||
#:######################################################################################:#
|
||||
# TEMT6000 AMBIENT LIGHT SENSOR
|
||||
#:######################################################################################:#
|
||||
#
|
||||
# The ADC sensor exposes the measured SIG/OUT voltage for calibration.
|
||||
# The illuminance sensor uses the standard TEMT6000 breakout approximation:
|
||||
#
|
||||
# lux = voltage x 200
|
||||
#
|
||||
# Automatic display-brightness control is intentionally not enabled yet.
|
||||
# First record representative readings in darkness and normal room lighting.
|
||||
|
||||
- platform: adc
|
||||
id: ambient_light_voltage
|
||||
name: "${friendly_name} Ambient Light Voltage"
|
||||
pin: "${ambient_light_pin}"
|
||||
attenuation: auto
|
||||
update_interval: "${ambient_light_update_interval}"
|
||||
accuracy_decimals: 3
|
||||
icon: mdi:sine-wave
|
||||
filters:
|
||||
- median:
|
||||
window_size: 7
|
||||
send_every: 3
|
||||
send_first_at: 1
|
||||
|
||||
- platform: template
|
||||
id: ambient_light_illuminance
|
||||
name: "${friendly_name} Ambient Light"
|
||||
device_class: illuminance
|
||||
state_class: measurement
|
||||
unit_of_measurement: "lx"
|
||||
accuracy_decimals: 0
|
||||
icon: mdi:brightness-6
|
||||
update_interval: 3s
|
||||
lambda: |-
|
||||
const float voltage = id(ambient_light_voltage).state;
|
||||
|
||||
if (isnan(voltage)) {
|
||||
return NAN;
|
||||
}
|
||||
|
||||
return voltage * 200.0f;
|
||||
|
||||
- platform: homeassistant
|
||||
id: moon_phase
|
||||
entity_id: "${moon_phase_entity}"
|
||||
|
||||
Reference in New Issue
Block a user