feat: Updates to esp boards and mqtt custom sensors
This commit is contained in:
@@ -1 +1 @@
|
||||
2024.10.3
|
||||
2024.10.4
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -2,6 +2,7 @@
|
||||
custom_components/*
|
||||
www/community/*
|
||||
image/*
|
||||
esphome/trash/*
|
||||
|
||||
*.log
|
||||
*.log*
|
||||
|
||||
@@ -449,3 +449,42 @@
|
||||
target:
|
||||
entity_id: switch.fan_low_2
|
||||
mode: single
|
||||
- id: '1729393621896'
|
||||
alias: Send humidify dew point to test topic.
|
||||
description: ''
|
||||
triggers:
|
||||
- trigger: state
|
||||
entity_id:
|
||||
- input_number.humidify_dew_point
|
||||
conditions: []
|
||||
actions:
|
||||
- action: mqtt.publish
|
||||
data:
|
||||
evaluate_payload: false
|
||||
qos: 0
|
||||
retain: false
|
||||
topic: frankensystem/test
|
||||
payload: '{{ state_attr(''input_number.humidify_dew_point'', ''state'') | float
|
||||
}}'
|
||||
mode: single
|
||||
- id: '1729433000402'
|
||||
alias: Notify Authentik postgres changed.
|
||||
description: Send a notification when the state of postgres changed for the Authentik
|
||||
service. This generally happens when the docker volume is disconnected and requires
|
||||
attention.
|
||||
triggers:
|
||||
- trigger: state
|
||||
entity_id:
|
||||
- sensor.portainer_mighty_mini_authentik_postgres
|
||||
for:
|
||||
hours: 0
|
||||
minutes: 0
|
||||
seconds: 0
|
||||
conditions: []
|
||||
actions:
|
||||
- action: notify.notify
|
||||
metadata: {}
|
||||
data:
|
||||
message: Authentik postgres changed {{ states('sensor.portainer_mighty_mini_authentik_postgres')
|
||||
}}
|
||||
mode: single
|
||||
|
||||
@@ -17,10 +17,22 @@ scene: !include scenes.yaml
|
||||
#influxdb: !include influxdb.yaml
|
||||
template: !include templates.yaml
|
||||
|
||||
# Move to a package
|
||||
input_number:
|
||||
humidify_dew_point:
|
||||
name: "Humidify Dew Point"
|
||||
initial: 50
|
||||
min: 30
|
||||
max: 55
|
||||
step: 0.5
|
||||
unit_of_measurement: "°F"
|
||||
icon: "mdi:temperature-fahrenheit"
|
||||
|
||||
# Example configuration.yaml entry for the HTTP component
|
||||
http:
|
||||
server_port: 443
|
||||
ssl_certificate: /ssl/fullchain.pem
|
||||
ssl_key: /ssl/privkey.pem
|
||||
|
||||
mqtt: !include sensors.yaml
|
||||
|
||||
|
||||
47
esphome/aqi-sensor.yaml
Normal file
47
esphome/aqi-sensor.yaml
Normal file
@@ -0,0 +1,47 @@
|
||||
esphome:
|
||||
name: aqi-sensor
|
||||
friendly_name: AQI-Sensor
|
||||
|
||||
esp8266:
|
||||
board: esp01_1m
|
||||
|
||||
# Enable logging
|
||||
logger:
|
||||
#level: VERY_VERBOSE
|
||||
|
||||
# Enable Home Assistant API
|
||||
api:
|
||||
encryption:
|
||||
key: "3CIARK+MjVSvSJ1VP/GjplrkvFb+TlVPH0CTsHciKdw="
|
||||
|
||||
ota:
|
||||
- platform: esphome
|
||||
password: "cbc40991e6bdea7d9ce6c63085403419"
|
||||
|
||||
wifi:
|
||||
ssid: !secret wifi_ssid
|
||||
password: !secret wifi_password
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
ssid: "Aqi-Sensor Fallback Hotspot"
|
||||
password: "ddjn1Ua2MWWf"
|
||||
|
||||
captive_portal:
|
||||
|
||||
|
||||
# Configuration
|
||||
i2c:
|
||||
scan: true
|
||||
|
||||
sensor:
|
||||
- platform: ccs811
|
||||
eco2:
|
||||
name: "AQI eCO2 Value"
|
||||
tvoc:
|
||||
name: "AQI TVOC"
|
||||
update_interval: 10s
|
||||
#baseline: 0x19BC
|
||||
switch:
|
||||
- platform: restart
|
||||
name: "AQI Sensor Restart"
|
||||
@@ -56,29 +56,34 @@ mqtt:
|
||||
username: !secret mqtt_username
|
||||
password: !secret mqtt_password
|
||||
topic_prefix: frankensystem
|
||||
discovery: true
|
||||
discovery: false
|
||||
|
||||
switch:
|
||||
# 8 Channel Relay - 2
|
||||
- platform: gpio
|
||||
pin: $relay5_pin
|
||||
name: "Coil Damper - 1"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay3_pin
|
||||
name: "Coil Damper - 2"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay1_pin
|
||||
name: "Coil Damper - 3"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay2_pin
|
||||
name: "Bypass Damper - 1"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay4_pin
|
||||
name: "Bypass Damper - 2"
|
||||
restore_mode: RESTORE_DEFAULT_ON
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay6_pin
|
||||
@@ -92,3 +97,5 @@ switch:
|
||||
pin: $relay8_pin
|
||||
name: "Spare - 3"
|
||||
|
||||
- platform: restart
|
||||
name: "FrankenSystem Damper Relay Restart"
|
||||
@@ -2,7 +2,16 @@ esphome:
|
||||
name: sensor-1
|
||||
platform: ESP8266
|
||||
board: nodemcuv2
|
||||
libraries:
|
||||
- ESP8266WiFi
|
||||
- https://github.com/akaJes/AsyncPing#95ac7e4
|
||||
|
||||
external_components:
|
||||
- source:
|
||||
type: git
|
||||
url: https://github.com/trombik/esphome-component-ping
|
||||
ref: main
|
||||
|
||||
# Enable logging
|
||||
logger:
|
||||
|
||||
@@ -28,7 +37,9 @@ mqtt:
|
||||
username: !secret mqtt_username
|
||||
password: !secret mqtt_password
|
||||
topic_prefix: frankensystem
|
||||
discovery: true
|
||||
discovery: false
|
||||
will_message:
|
||||
|
||||
|
||||
captive_portal:
|
||||
|
||||
@@ -64,4 +75,19 @@ sensor:
|
||||
name: "Supply Temperature"
|
||||
humidity:
|
||||
name: "Supply Humidity"
|
||||
update_interval: 5s
|
||||
update_interval: 5s
|
||||
|
||||
- platform: ping
|
||||
ip_address: 192.168.1.1 ## Router IP
|
||||
num_attempts: 5
|
||||
timeout: 1sec
|
||||
loss:
|
||||
name: Packet loss
|
||||
latency:
|
||||
name: Latency
|
||||
accuracy_decimals: 3
|
||||
update_interval: 30s
|
||||
|
||||
switch:
|
||||
- platform: restart
|
||||
name: "FrankenSystem Sensors Restart"
|
||||
@@ -57,7 +57,7 @@ mqtt:
|
||||
username: !secret mqtt_username
|
||||
password: !secret mqtt_password
|
||||
topic_prefix: frankensystem
|
||||
discovery: true
|
||||
discovery: false
|
||||
|
||||
network:
|
||||
enable_ipv6: True
|
||||
@@ -67,34 +67,45 @@ switch:
|
||||
- platform: gpio
|
||||
pin: $relay4_pin
|
||||
name: "Fan Low"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay5_pin
|
||||
name: "Fan Medium Low"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay8_pin
|
||||
name: "Fan Medium High"
|
||||
restore_mode: RESTORE_DEFAULT_OFF
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay7_pin
|
||||
name: "Fan High"
|
||||
restore_mode: RESTORE_DEFAULT_ON
|
||||
|
||||
- platform: gpio
|
||||
pin:
|
||||
number: $relay3_pin
|
||||
inverted: true
|
||||
name: "Dehumidification"
|
||||
restore_mode: ALWAYS_ON
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay1_pin
|
||||
name: "Humidification"
|
||||
restore_mode: ALWAYS_ON
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay2_pin
|
||||
name: "Reheat"
|
||||
restore_mode: ALWAYS_ON
|
||||
|
||||
- platform: gpio
|
||||
pin: $relay6_pin
|
||||
name: "Cooling"
|
||||
restore_mode: ALWAYS_ON
|
||||
|
||||
- platform: restart
|
||||
name: "FrankenSystem System Relays Restart"
|
||||
|
||||
|
||||
9
mqtt.yaml
Normal file
9
mqtt.yaml
Normal file
@@ -0,0 +1,9 @@
|
||||
number:
|
||||
- name: "Frankensystem Test"
|
||||
command_topic: "frankensystem/test"
|
||||
state_topic: "frankensystem/test"
|
||||
|
||||
sensor:
|
||||
name: "Frankensystem Test Sensor"
|
||||
state_topic: "frankensystem/sensor/test/state"
|
||||
value_template: "{{ value_json['temperature'] | float }}"
|
||||
135
sensors.yaml
135
sensors.yaml
@@ -1,72 +1,65 @@
|
||||
# Custom MQTT Sensor values.
|
||||
- platform: mqtt
|
||||
name: Mixed Air Dew Point
|
||||
state_topic: "frankensystem/sensor/mixed_air_dew_point/state"
|
||||
unit_of_measurement: "°F"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "mixed_air_dew_point"
|
||||
|
||||
- platform: mqtt
|
||||
name: Mixed Air Enthalpy
|
||||
state_topic: "frankensystem/sensor/mixed_air_enthalpy/state"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
#unit_of_measurement: "°F"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "mixed_air_enthalpy"
|
||||
|
||||
- platform: mqtt
|
||||
name: Post Coil Dew Point
|
||||
state_topic: "frankensystem/sensor/post_coil_dew_point/state"
|
||||
unit_of_measurement: "°F"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "post_coil_dew_point"
|
||||
|
||||
- platform: mqtt
|
||||
name: Post Coil Enthalpy
|
||||
state_topic: "frankensystem/sensor/post_coil_enthalpy/state"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
#unit_of_measurement: "°F"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "post_coil_enthalpy"
|
||||
|
||||
- platform: mqtt
|
||||
name: Return Dew Point
|
||||
state_topic: "frankensystem/sensor/return_dew_point/state"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
unit_of_measurement: "°F"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "return_dew_point"
|
||||
|
||||
- platform: mqtt
|
||||
name: Return Enthalpy
|
||||
state_topic: "frankensystem/sensor/return_enthalpy/state"
|
||||
#unit_of_measurement: "°F"
|
||||
#value_template: "{{ value_json.temperature }}""
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "return_enthalpy"
|
||||
|
||||
- platform: mqtt
|
||||
name: Supply Dew Point
|
||||
state_topic: "frankensystem/sensor/supply_dew_point/state"
|
||||
unit_of_measurement: "°F"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "supply_dew_point"
|
||||
|
||||
- platform: mqtt
|
||||
name: Supply Enthalpy
|
||||
state_topic: "frankensystem/sensor/supply_enthalpy/state"
|
||||
#unit_of_measurement: "°F"
|
||||
value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "supply_enthalpy"
|
||||
sensor:
|
||||
- name: Mixed Air Dew Point
|
||||
state_topic: "frankensystem/sensor/mixed_air_dew_point/state"
|
||||
unit_of_measurement: "°F"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "mixed_air_dew_point"
|
||||
|
||||
- name: Mixed Air Enthalpy
|
||||
state_topic: "frankensystem/sensor/mixed_air_enthalpy/state"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
unit_of_measurement: "BTU/lb"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "mixed_air_enthalpy"
|
||||
|
||||
- name: Post Coil Dew Point
|
||||
state_topic: "frankensystem/sensor/post_coil_dew_point/state"
|
||||
unit_of_measurement: "°F"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "post_coil_dew_point"
|
||||
|
||||
- name: Post Coil Enthalpy
|
||||
state_topic: "frankensystem/sensor/post_coil_enthalpy/state"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
unit_of_measurement: "BTU/lb"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "post_coil_enthalpy"
|
||||
|
||||
- name: Return Dew Point
|
||||
state_topic: "frankensystem/sensor/return_dew_point/state"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
unit_of_measurement: "°F"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "return_dew_point"
|
||||
|
||||
- name: Return Enthalpy
|
||||
state_topic: "frankensystem/sensor/return_enthalpy/state"
|
||||
unit_of_measurement: "BTU/lb"
|
||||
#value_template: "{{ value_json.temperature }}""
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "return_enthalpy"
|
||||
|
||||
- name: Supply Dew Point
|
||||
state_topic: "frankensystem/sensor/supply_dew_point/state"
|
||||
unit_of_measurement: "°F"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "supply_dew_point"
|
||||
|
||||
- name: Supply Enthalpy
|
||||
state_topic: "frankensystem/sensor/supply_enthalpy/state"
|
||||
unit_of_measurement: "BTU/lb"
|
||||
#value_template: "{{ value_json.temperature }}"
|
||||
payload_available: "online"
|
||||
payload_not_available: "offline"
|
||||
unique_id: "supply_enthalpy"
|
||||
|
||||
Reference in New Issue
Block a user