mirror of
https://github.com/CeeWeasel/fresh-home.git
synced 2026-08-09 18:40:14 -04:00
so many freaking changes!
This commit is contained in:
@@ -0,0 +1,336 @@
|
||||
web_server:
|
||||
port: 80
|
||||
version: 3
|
||||
include_internal: true
|
||||
sorting_groups:
|
||||
- id: sorting_group_temperature_settings
|
||||
name: "Temperature Settings"
|
||||
sorting_weight: 10
|
||||
- id: sorting_group_humidity_settings
|
||||
name: "Humidity Settings"
|
||||
sorting_weight: 20
|
||||
- id: sorting_group_pressure_settings
|
||||
name: "Pressure Settings"
|
||||
sorting_weight: 30
|
||||
- id: sorting_group_quality_settings
|
||||
name: "Quality Settings"
|
||||
sorting_weight: 40
|
||||
|
||||
|
||||
bme680_bsec:
|
||||
i2c_id: ${i2c_id}
|
||||
|
||||
# i2c address
|
||||
# -----------
|
||||
# Common values are:
|
||||
# - 0x76
|
||||
# - 0x77
|
||||
# Default: 0x76
|
||||
address: 0x77
|
||||
|
||||
# Temperature offset
|
||||
# ------------------
|
||||
# Useful if device is in enclosure and reads too high
|
||||
# Default: 0
|
||||
temperature_offset: 0
|
||||
|
||||
# IAQ calculation mode
|
||||
# --------------------
|
||||
# Available options:
|
||||
# - static (for fixed position devices)
|
||||
# - mobile (for on person or other moveable devices)
|
||||
# Default: static
|
||||
iaq_mode: static
|
||||
|
||||
# Sample rate
|
||||
# -----------
|
||||
# This controls the sampling rate for gas-dependant sensors and will govern the interval
|
||||
# at which the sensor heater is operated.
|
||||
# By default this rate will also be used for temperature, pressure and humidity sensors
|
||||
# but these can be overridden on a per-sensor level if required.
|
||||
#
|
||||
# Available options:
|
||||
# - lp (low power - samples every 3 seconds)
|
||||
# - ulp (ultra low power - samples every 5 minutes)
|
||||
# Default: lp
|
||||
sample_rate: lp
|
||||
|
||||
# Interval at which to save BSEC state
|
||||
# ------------------------------------
|
||||
# Default: 6h
|
||||
state_save_interval: 6h
|
||||
|
||||
sensor:
|
||||
- platform: bme680_bsec
|
||||
temperature:
|
||||
# Temperature in °C
|
||||
id: temperature
|
||||
internal: true
|
||||
sample_rate: lp
|
||||
unit_of_measurement: "°C"
|
||||
web_server:
|
||||
sorting_weight: 11
|
||||
sorting_group_id: sorting_group_temperature_settings
|
||||
|
||||
humidity:
|
||||
# Relative humidity %
|
||||
id: humidity
|
||||
internal: true
|
||||
sample_rate: lp
|
||||
unit_of_measurement: "%"
|
||||
web_server:
|
||||
sorting_weight: 21
|
||||
sorting_group_id: sorting_group_humidity_settings
|
||||
|
||||
pressure:
|
||||
# Pressure in hPa
|
||||
id: pressure
|
||||
internal: true
|
||||
sample_rate: lp
|
||||
unit_of_measurement: "hPa"
|
||||
web_server:
|
||||
sorting_weight: 31
|
||||
sorting_group_id: sorting_group_pressure_settings
|
||||
|
||||
gas_resistance:
|
||||
# Gas resistance in Ω
|
||||
id: resistance
|
||||
internal: true
|
||||
unit_of_measurement: "Ω"
|
||||
disabled_by_default: True
|
||||
web_server:
|
||||
sorting_weight: 41
|
||||
sorting_group_id: sorting_group_pressure_settings
|
||||
|
||||
iaq:
|
||||
# Indoor air quality value
|
||||
id: iaq
|
||||
internal: true
|
||||
unit_of_measurement: "AQI"
|
||||
web_server:
|
||||
sorting_weight: 51
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
|
||||
co2_equivalent:
|
||||
# CO2 equivalent estimate in ppm
|
||||
id: co2
|
||||
internal: true
|
||||
unit_of_measurement: "ppm"
|
||||
web_server:
|
||||
sorting_weight: 61
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
|
||||
breath_voc_equivalent:
|
||||
# Volatile organic compounds equivalent estimate in ppm
|
||||
id: breath_voc
|
||||
internal: true
|
||||
unit_of_measurement: "ppm"
|
||||
web_server:
|
||||
sorting_weight: 71
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
|
||||
iaq_accuracy:
|
||||
# IAQ accuracy as a numeric value of 0, 1, 2, 3
|
||||
name: "Numeric IAQ Accuracy"
|
||||
id: iaq_accuracy
|
||||
disabled_by_default: True
|
||||
web_server:
|
||||
sorting_weight: 81
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
filters:
|
||||
- median:
|
||||
window_size: 20
|
||||
send_every: 20
|
||||
send_first_at: 1
|
||||
|
||||
# These source sensors update every 3 seconds
|
||||
# An average with a window size of 10 and send_every of 10 means that an average is pushed out every 30 seconds
|
||||
|
||||
- platform: copy
|
||||
source_id: temperature
|
||||
device_class: temperature
|
||||
unit_of_measurement: "°C"
|
||||
name: "Air Temperature"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_weight: 12
|
||||
sorting_group_id: sorting_group_temperature_settings
|
||||
|
||||
# These derivatives attempt to calculate the change per minute
|
||||
|
||||
- platform: copy
|
||||
source_id: temperature
|
||||
device_class: temperature
|
||||
unit_of_measurement: "°C/m"
|
||||
name: "Air Temperature Change"
|
||||
icon: mdi:chart-line
|
||||
disabled_by_default: true
|
||||
filters:
|
||||
- lambda: |-
|
||||
static float last_value = 0;
|
||||
static float last_time = 0;
|
||||
float time = (float) millis();
|
||||
if (last_time == 0){
|
||||
last_value = x;
|
||||
last_time = time;
|
||||
return {};
|
||||
}
|
||||
float change = ( ( x - last_value ) / ( time - last_time ) ) *1000*5;
|
||||
last_value = x;
|
||||
last_time = time;
|
||||
return change;
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_weight: 13
|
||||
sorting_group_id: sorting_group_temperature_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: humidity
|
||||
device_class: humidity
|
||||
unit_of_measurement: "%"
|
||||
name: "Relative Humidity"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_weight: 22
|
||||
sorting_group_id: sorting_group_humidity_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: humidity
|
||||
device_class: humidity
|
||||
unit_of_measurement: "%/m"
|
||||
name: "Relative Humidity Change"
|
||||
icon: mdi:chart-line
|
||||
disabled_by_default: true
|
||||
filters:
|
||||
- lambda: |-
|
||||
static float last_value = 0;
|
||||
static float last_time = 0;
|
||||
float time = (float) millis();
|
||||
if (last_time == 0){
|
||||
last_value = x;
|
||||
last_time = time;
|
||||
return {};
|
||||
}
|
||||
float change = ( ( x - last_value ) / ( time - last_time ) ) *1000*5;
|
||||
last_value = x;
|
||||
last_time = time;
|
||||
return change;
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_weight: 23
|
||||
sorting_group_id: sorting_group_humidity_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: pressure
|
||||
unit_of_measurement: "hPa"
|
||||
name: "Pressure"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_group_id: sorting_group_pressure_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: resistance
|
||||
unit_of_measurement: "Ω"
|
||||
name: "Gas Resistance"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_group_id: sorting_group_pressure_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: iaq
|
||||
unit_of_measurement: "AQI"
|
||||
name: "Air Quality Index"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: co2
|
||||
unit_of_measurement: "ppm"
|
||||
name: "CO2 Equivalent"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
|
||||
- platform: copy
|
||||
source_id: breath_voc
|
||||
unit_of_measurement: "ppm"
|
||||
name: "Breath VOC Equivalent"
|
||||
filters:
|
||||
- sliding_window_moving_average:
|
||||
window_size: 10
|
||||
send_every: 10
|
||||
send_first_at: 1
|
||||
web_server:
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
|
||||
text_sensor:
|
||||
- platform: template
|
||||
name: "IAQ Classification"
|
||||
icon: "mdi:checkbox-marked-circle-outline"
|
||||
web_server:
|
||||
sorting_weight: 60
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
lambda: |-
|
||||
if (int(id(iaq).state) <= 50) {
|
||||
return {"Excellent"};
|
||||
}
|
||||
else if (int(id(iaq).state) <= 100) {
|
||||
return {"Good"};
|
||||
}
|
||||
else if (int(id(iaq).state) <= 150) {
|
||||
return {"Lightly polluted"};
|
||||
}
|
||||
else if (int(id(iaq).state) <= 200) {
|
||||
return {"Moderately polluted"};
|
||||
}
|
||||
else if (int(id(iaq).state) <= 250) {
|
||||
return {"Heavily polluted"};
|
||||
}
|
||||
else if (int(id(iaq).state) <= 350) {
|
||||
return {"Severely polluted"};
|
||||
}
|
||||
else if (int(id(iaq).state) <= 500) {
|
||||
return {"Extremely polluted"};
|
||||
}
|
||||
else {
|
||||
return {"unknown"};
|
||||
}
|
||||
|
||||
- platform: bme680_bsec
|
||||
iaq_accuracy:
|
||||
# IAQ accuracy as a text value of Stabilizing, Uncertain, Calibrating, Calibrated
|
||||
name: "AQI Accuracy"
|
||||
web_server:
|
||||
sorting_weight: 61
|
||||
sorting_group_id: sorting_group_quality_settings
|
||||
@@ -16,9 +16,12 @@ time:
|
||||
# Enable Home Assistant API
|
||||
api:
|
||||
reboot_timeout: 15min
|
||||
encryption:
|
||||
key: !secret api-encryption-key
|
||||
|
||||
ota:
|
||||
- platform: esphome
|
||||
password: !secret ota-password
|
||||
|
||||
binary_sensor:
|
||||
- <<: !include binary_sensor/status_sensor.config.yaml
|
||||
|
||||
@@ -16,7 +16,6 @@ ethernet:
|
||||
gateway: !secret iot_default_gateway
|
||||
subnet: !secret iot_subnet_mask
|
||||
dns1: !secret iot_default_dns1
|
||||
dns2: !secret iot_default_dns2
|
||||
|
||||
text_sensor:
|
||||
- <<: !include text_sensor/ethernet_info.config.yaml
|
||||
@@ -21,7 +21,6 @@ ethernet:
|
||||
gateway: !secret iot_default_gateway
|
||||
subnet: !secret iot_subnet_mask
|
||||
dns1: !secret iot_default_dns1
|
||||
dns2: !secret iot_default_dns2
|
||||
|
||||
text_sensor:
|
||||
- <<: !include text_sensor/ethernet_info.config.yaml
|
||||
@@ -0,0 +1,82 @@
|
||||
esphome:
|
||||
name: ${devicename}
|
||||
platformio_options:
|
||||
board_build.arduino.memory_type: qio_opi
|
||||
board_build.flash_mode: dio
|
||||
upload_speed: 921600
|
||||
monitor_speed: 115200
|
||||
|
||||
esp32:
|
||||
board: ${board}
|
||||
flash_size: 16MB
|
||||
framework:
|
||||
type: ${framework}
|
||||
sdkconfig_options:
|
||||
CONFIG_ESP32_S3_BOX_BOARD: "y"
|
||||
|
||||
psram:
|
||||
mode: octal
|
||||
speed: 80MHz
|
||||
|
||||
# logger:
|
||||
|
||||
# api:
|
||||
# encryption:
|
||||
# key: !secret api_encryption_psk
|
||||
|
||||
# ota:
|
||||
# - platform: esphome
|
||||
# password: !secret ota-password
|
||||
|
||||
ethernet:
|
||||
type: W5500
|
||||
clk_pin: GPIO13
|
||||
mosi_pin: GPIO11
|
||||
miso_pin: GPIO12
|
||||
cs_pin: GPIO14
|
||||
interrupt_pin: GPIO10
|
||||
reset_pin: GPIO9
|
||||
|
||||
######################################
|
||||
### Camera
|
||||
######################################
|
||||
|
||||
# esp32_camera:
|
||||
# name: ${room_friendly_name} Camera
|
||||
# external_clock:
|
||||
# pin: GPIO3
|
||||
# frequency: 20MHz
|
||||
# i2c_pins:
|
||||
# sda: GPIO48
|
||||
# scl: GPIO47
|
||||
# data_pins: [GPIO41, GPIO45, GPIO46, GPIO42, GPIO40, GPIO38, GPIO15, GPIO18]
|
||||
# vsync_pin: GPIO1
|
||||
# href_pin: GPIO2
|
||||
# pixel_clock_pin: GPIO39
|
||||
# power_down_pin: GPIO8
|
||||
# resolution: 640x480
|
||||
# jpeg_quality: 10
|
||||
# #resolution: 1280x1024
|
||||
# #jpeg_quality: 30
|
||||
# vertical_flip: false
|
||||
# horizontal_mirror: false
|
||||
# # aec_mode: MANUAL
|
||||
# # aec_value: 1200
|
||||
# # brightness: 2
|
||||
# # wb_mode: HOME
|
||||
# # agc_mode: AUTO
|
||||
|
||||
|
||||
#######################################
|
||||
### Bluetooth Proxy
|
||||
#######################################
|
||||
|
||||
esp32_ble_tracker:
|
||||
scan_parameters:
|
||||
# only use these values on Ethernet not WIFI
|
||||
interval: 1100ms
|
||||
window: 1100ms
|
||||
active: true
|
||||
|
||||
bluetooth_proxy:
|
||||
active: true
|
||||
+20
-4
@@ -1,8 +1,22 @@
|
||||
esphome:
|
||||
name: ${devicename}
|
||||
platformio_options:
|
||||
board_build.arduino.memory_type: qio_opi
|
||||
board_build.flash_mode: dio
|
||||
upload_speed: 921600
|
||||
monitor_speed: 115200
|
||||
|
||||
esp32:
|
||||
board: esp32-s3
|
||||
board: ${board}
|
||||
flash_size: 16MB
|
||||
framework:
|
||||
#type: arduino
|
||||
type: esp-idf
|
||||
type: ${framework}
|
||||
sdkconfig_options:
|
||||
CONFIG_ESP32_S3_BOX_BOARD: "y"
|
||||
|
||||
psram:
|
||||
mode: octal
|
||||
speed: 80MHz
|
||||
|
||||
ethernet:
|
||||
id: eth
|
||||
@@ -21,7 +35,9 @@ ethernet:
|
||||
gateway: !secret iot_default_gateway
|
||||
subnet: !secret iot_subnet_mask
|
||||
dns1: !secret iot_default_dns1
|
||||
dns2: !secret iot_default_dns2
|
||||
|
||||
packages:
|
||||
ble_proxy: !include ../common/ble_proxy.yaml
|
||||
|
||||
text_sensor:
|
||||
- <<: !include text_sensor/ethernet_info.config.yaml
|
||||
@@ -2,29 +2,27 @@ esphome:
|
||||
captive_portal:
|
||||
|
||||
wifi:
|
||||
#power_save_mode: none
|
||||
networks:
|
||||
- ssid: !secret Wifi_SSID
|
||||
password: !secret Wifi_PWD
|
||||
# Enable fast connect
|
||||
fast_connect: true
|
||||
min_auth_mode: WPA2
|
||||
use_address: ${devicename}.local
|
||||
|
||||
#- ssid: !secret IoT_Wifi_SSID
|
||||
# password: !secret IoT_Wifi_PWD
|
||||
networks:
|
||||
- ssid: !secret wifi_ssid
|
||||
password: !secret wifi_password
|
||||
hidden: true
|
||||
|
||||
manual_ip:
|
||||
static_ip: ${static_ip}
|
||||
gateway: !secret iot_default_gateway
|
||||
subnet: !secret iot_subnet_mask
|
||||
|
||||
use_address: ${devicename}.local
|
||||
dns1: !secret iot_default_dns1
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
ssid: "${friendly_name}"
|
||||
password: !secret fallback_ap_password
|
||||
|
||||
# Enable fast connect
|
||||
fast_connect: true
|
||||
|
||||
sensor:
|
||||
- <<: !include sensor/rssi_sensor.config.yaml
|
||||
|
||||
|
||||
@@ -1,16 +1,17 @@
|
||||
esphome:
|
||||
captive_portal:
|
||||
|
||||
wifi:
|
||||
power_save_mode: none
|
||||
networks:
|
||||
- ssid: !secret Wifi_SSID
|
||||
password: !secret Wifi_PWD
|
||||
|
||||
- ssid: !secret IoT_Wifi_SSID
|
||||
password: !secret IoT_Wifi_PWD
|
||||
|
||||
# Enable fast connect
|
||||
fast_connect: true
|
||||
min_auth_mode: WPA2
|
||||
use_address: ${devicename}.local
|
||||
|
||||
networks:
|
||||
- ssid: !secret wifi_ssid
|
||||
password: !secret wifi_password
|
||||
hidden: true
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
ssid: "${friendly_name}"
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
esphome:
|
||||
captive_portal:
|
||||
|
||||
wifi:
|
||||
ssid: !secret Wifi_SSID
|
||||
password: !secret Wifi_PWD
|
||||
|
||||
#- ssid: !secret IoT_Wifi_SSID
|
||||
# password: !secret IoT_Wifi_PWD
|
||||
|
||||
use_address: ${devicename}.local
|
||||
|
||||
manual_ip:
|
||||
static_ip: ${static_ip}
|
||||
gateway: !secret iot_default_gateway
|
||||
subnet: !secret iot_subnet_mask
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
ssid: "${friendly_name}"
|
||||
password: !secret fallback_ap_password
|
||||
|
||||
# Enable fast connect
|
||||
fast_connect: true
|
||||
|
||||
sensor:
|
||||
- <<: !include sensor/rssi_sensor.config.yaml
|
||||
|
||||
text_sensor:
|
||||
- <<: !include text_sensor/wifi_sensor.config.yaml
|
||||
Reference in New Issue
Block a user