Compare commits

..

No commits in common. "5aa502ea98b1f7d6836d8de1ea3dd0c14d1fd3b2" and "e224044de38f902812243ce41746f006d59956cd" have entirely different histories.

View File

@ -36,13 +36,9 @@ esphome:
id(pir_presence).publish_state(false); id(pir_presence).publish_state(false);
id(light_presence).publish_state(false); id(light_presence).publish_state(false);
id(radar_presence).publish_state(false); id(radar_presence).publish_state(false);
- priority: -100 - light.turn_on:
then: id: output_led
- if: effect: flash_white
condition:
- switch.is_on: enable_voice_support
then:
- micro_wake_word.start:
preferences: preferences:
flash_write_interval: 15sec flash_write_interval: 15sec
@ -278,32 +274,32 @@ logger:
api: api:
reboot_timeout: 15min reboot_timeout: 15min
# on_client_connected: on_client_connected:
# - logger.log: - logger.log:
# format: "Client %s (IP %s) connected to API" format: "Client %s (IP %s) connected to API"
# args: ["client_info.c_str()", "client_address.c_str()"] args: ["client_info.c_str()", "client_address.c_str()"]
# - script.execute: light_off - script.execute: light_off
# - if: - if:
# condition: condition:
# lambda: |- lambda: |-
# return id(enable_voice_support).state && return id(enable_voice_support).state &&
# !id(mww).is_running(); !id(mww).is_running();
# then: then:
# - micro_wake_word.start: - micro_wake_word.start:
# on_client_disconnected: on_client_disconnected:
# - logger.log: - logger.log:
# format: "Client %s (IP %s) disconnected from API" format: "Client %s (IP %s) disconnected from API"
# args: ["client_info.c_str()", "client_address.c_str()"] args: ["client_info.c_str()", "client_address.c_str()"]
# - if: - if:
# condition: condition:
# lambda: |- lambda: |-
# return id(enable_voice_support).state && return id(enable_voice_support).state &&
# id(mww).is_running(); id(mww).is_running();
# then: then:
# - micro_wake_word.stop: - micro_wake_word.stop:
# - light.turn_on: - light.turn_on:
# id: output_led id: output_led
# effect: flash_white effect: flash_white
ota: ota:
platform: esphome platform: esphome
@ -364,7 +360,7 @@ micro_wake_word:
id: mww id: mww
microphone: microphone:
microphone: mic microphone: mic
gain_factor: 4 gain_factor: 31
stop_after_detection: false stop_after_detection: false
models: models:
- model: github://esphome/micro-wake-word-models/models/v2/hey_jarvis.json - model: github://esphome/micro-wake-word-models/models/v2/hey_jarvis.json
@ -392,7 +388,7 @@ voice_assistant:
micro_wake_word: mww micro_wake_word: mww
use_wake_word: false use_wake_word: false
noise_suppression_level: 3 noise_suppression_level: 3
auto_gain: 4 dbfs auto_gain: 31 dbfs
volume_multiplier: 8 volume_multiplier: 8
on_wake_word_detected: on_wake_word_detected:
- logger.log: "Wake word detected in VA pipeline" - logger.log: "Wake word detected in VA pipeline"
@ -552,7 +548,7 @@ sensor:
filters: filters:
- offset: !lambda return id(temperature_offset); - offset: !lambda return id(temperature_offset);
- sliding_window_moving_average: - sliding_window_moving_average:
window_size: 20 window_size: 4
send_every: 1 send_every: 1
humidity: humidity:
name: "SHT45 Relative Humidity" name: "SHT45 Relative Humidity"
@ -586,18 +582,18 @@ sensor:
return (b * alpha) / (a - alpha); return (b * alpha) / (a - alpha);
update_interval: 15s update_interval: 15s
# IAQ Index (1-5, 5=Great)) # IAQ Index (1-5, 5=Excellent)
- platform: template - platform: template
name: "IAQ Index" name: "IAQ Index"
id: iaq_index id: iaq_index
lambda: |- lambda: |-
int tvoc = id(sgp30_tvoc).state; int tvoc = id(sgp30_tvoc).state;
int eco2 = id(sgp30_eco2).state; int eco2 = id(sgp30_eco2).state;
if (tvoc > 2200 || eco2 > 2000) return 1; // Bad if (tvoc > 2200 || eco2 > 2000) return 1; // Unhealthy
if (tvoc > 660 || eco2 > 1200) return 2; // Poor if (tvoc > 660 || eco2 > 1200) return 2; // Poor
if (tvoc > 220 || eco2 > 800) return 3; / Fair if (tvoc > 220 || eco2 > 800) return 3; // Moderate
if (tvoc > 65 || eco2 > 500) return 4; // Good if (tvoc > 65 || eco2 > 500) return 4; // Good
return 5; // Great return 5; // Excellent
update_interval: 15s update_interval: 15s
# Room Health Score (1-4, 4=Optimal) # Room Health Score (1-4, 4=Optimal)
@ -752,11 +748,11 @@ text_sensor:
name: "VOC Level" name: "VOC Level"
lambda: |- lambda: |-
int tvoc = id(sgp30_tvoc).state; int tvoc = id(sgp30_tvoc).state;
if (tvoc < 65) return {"Great"}; if (tvoc < 65) return {"Excellent"};
if (tvoc < 220) return {"Good"}; if (tvoc < 220) return {"Good"};
if (tvoc < 660) return {"Fair"}; if (tvoc < 660) return {"Moderate"};
if (tvoc < 2200) return {"Poor"}; if (tvoc < 2200) return {"Poor"};
return {"Bad"}; return {"Unhealthy"};
update_interval: 15s update_interval: 15s
# CO2 Level # CO2 Level
@ -764,11 +760,11 @@ text_sensor:
name: "CO2 Level" name: "CO2 Level"
lambda: |- lambda: |-
int eco2 = id(sgp30_eco2).state; int eco2 = id(sgp30_eco2).state;
if (eco2 < 500) return {"Great"}; if (eco2 < 500) return {"Excellent"};
if (eco2 < 800) return {"Good"}; if (eco2 < 800) return {"Good"};
if (eco2 < 1200) return {"Fair"}; if (eco2 < 1200) return {"Moderate"};
if (eco2 < 2000) return {"Poor"}; if (eco2 < 2000) return {"Poor"};
return {"Bad"}; return {"Unhealthy"};
update_interval: 15s update_interval: 15s
# IAQ Classification # IAQ Classification
@ -776,11 +772,11 @@ text_sensor:
name: "IAQ Classification" name: "IAQ Classification"
lambda: |- lambda: |-
int iaq = id(iaq_index).state; int iaq = id(iaq_index).state;
if (iaq == 5) return {"Great"}; if (iaq == 5) return {"Excellent"};
if (iaq == 4) return {"Good"}; if (iaq == 4) return {"Good"};
if (iaq == 3) return {"Fair"}; if (iaq == 3) return {"Moderate"};
if (iaq == 2) return {"Poor"}; if (iaq == 2) return {"Poor"};
return {"Bad"}; return {"Unhealthy"};
update_interval: 15s update_interval: 15s
# Room Health # Room Health