mirror of
https://github.com/CeeWeasel/fresh-home.git
synced 2026-08-09 18:40:14 -04:00
updating common esphome sensors
finally fixing hvac-multisensor. All of this was caused by the display switch referenced the display while it wasn't plugged in. Updated code to check for the existence first.
This commit is contained in:
@@ -1,3 +1,2 @@
|
||||
platform: status
|
||||
name: "${friendly_name} Status"
|
||||
id: ${entity_name}_status
|
||||
name: "Status"
|
||||
@@ -1,8 +1 @@
|
||||
esp32_ble_tracker:
|
||||
|
||||
binary_sensor:
|
||||
- platform: ble_presence
|
||||
ibeacon_uuid: '601c742f-2b19-ed3c-f5fc-0bb31d6c2eac'
|
||||
ibeacon_major: 100
|
||||
ibeacon_minor: 1
|
||||
name: "${friendly_name} Pixel 4"
|
||||
esp32_ble_tracker:
|
||||
@@ -1,4 +1,3 @@
|
||||
platform: restart
|
||||
name: "${friendly_name} Restart"
|
||||
id: ${entity_name}_restart
|
||||
name: "Restart"
|
||||
disabled_by_default: false
|
||||
@@ -29,5 +29,5 @@ button:
|
||||
sensor:
|
||||
- <<: !include sensor/uptime_sensor.config.yaml
|
||||
|
||||
#text_sensor:
|
||||
# - <<: !include text_sensor/version_sensor.config.yaml
|
||||
text_sensor:
|
||||
- <<: !include text_sensor/version_sensor.config.yaml
|
||||
|
||||
@@ -3,15 +3,18 @@ ethernet:
|
||||
type: LAN8720
|
||||
mdc_pin: GPIO23
|
||||
mdio_pin: GPIO18
|
||||
clk_mode: GPIO17_OUT
|
||||
phy_addr: 0
|
||||
clk:
|
||||
pin: GPIO17
|
||||
mode: CLK_OUT
|
||||
power_pin: GPIO5
|
||||
phy_addr: 0
|
||||
|
||||
manual_ip:
|
||||
static_ip: ${static_ip}
|
||||
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_ip_address.config.yaml
|
||||
|
||||
@@ -27,7 +27,7 @@ sensor:
|
||||
id: occupied
|
||||
|
||||
- platform: template
|
||||
name: "${friendly_name} Raw Value"
|
||||
name: "Raw Value"
|
||||
lambda: |-
|
||||
return id(hx711_value_raw).raw_state;
|
||||
unit_of_measurement: w
|
||||
@@ -35,7 +35,7 @@ sensor:
|
||||
state_class: measurement
|
||||
|
||||
- platform: template
|
||||
name: "${friendly_name} Auto Tare"
|
||||
name: "Auto Tare"
|
||||
lambda: |-
|
||||
return id(auto_tare_difference);
|
||||
unit_of_measurement: w
|
||||
@@ -43,7 +43,7 @@ sensor:
|
||||
state_class: measurement
|
||||
|
||||
- platform: template
|
||||
name: "${friendly_name} Initial Zero"
|
||||
name: "Initial Zero"
|
||||
lambda: |-
|
||||
return id(initial_zero);
|
||||
unit_of_measurement: w
|
||||
@@ -95,7 +95,7 @@ sensor:
|
||||
# Mapped value to lbs
|
||||
- platform: template
|
||||
id: hx711_value
|
||||
name: "${friendly_name} Weight"
|
||||
name: "Weight"
|
||||
internal: False
|
||||
filters:
|
||||
# apply auto_tare difference
|
||||
@@ -125,7 +125,7 @@ sensor:
|
||||
binary_sensor:
|
||||
- platform: template
|
||||
device_class: occupancy
|
||||
name: "${friendly_name} Occupied"
|
||||
name: "Occupied"
|
||||
icon: mdi:bed
|
||||
lambda: |-
|
||||
if (
|
||||
@@ -137,7 +137,7 @@ binary_sensor:
|
||||
}
|
||||
|
||||
- platform: template
|
||||
name: "${friendly_name} HX711 Error"
|
||||
name: "HX711 Error"
|
||||
id: hx711_error
|
||||
device_class: problem
|
||||
lambda: |-
|
||||
@@ -152,7 +152,7 @@ binary_sensor:
|
||||
switch:
|
||||
- platform: template
|
||||
id: force_occupancy
|
||||
name: "${friendly_name} Force Occupancy"
|
||||
name: "Force Occupancy"
|
||||
lambda: |-
|
||||
return id(occupancy_forced);
|
||||
turn_on_action:
|
||||
@@ -166,7 +166,7 @@ switch:
|
||||
id: auto_tare
|
||||
# optimistic: true
|
||||
# assumed_state: true
|
||||
name: "${friendly_name} Auto Tare"
|
||||
name: "Auto Tare"
|
||||
lambda: |-
|
||||
return id(auto_tare_enabled);
|
||||
turn_on_action:
|
||||
@@ -179,14 +179,14 @@ switch:
|
||||
button:
|
||||
- platform: template
|
||||
id: manual_tare
|
||||
name: "${friendly_name} Manual Tare"
|
||||
name: "Manual Tare"
|
||||
on_press:
|
||||
- lambda: |-
|
||||
id(auto_tare_difference) = id(initial_zero) - id(hx711_value_raw).state;
|
||||
|
||||
- platform: template
|
||||
id: reset_tare
|
||||
name: "${friendly_name} Reset Tare"
|
||||
name: "Reset Tare"
|
||||
on_press:
|
||||
- lambda: |-
|
||||
id(auto_tare_difference) = 0;
|
||||
@@ -1,9 +0,0 @@
|
||||
filters:
|
||||
- median:
|
||||
window_size: 5
|
||||
send_every: 2
|
||||
send_first_at: 1
|
||||
- or:
|
||||
- throttle: 5min
|
||||
- delta: 1.0
|
||||
- delta: .1
|
||||
@@ -1,4 +1,3 @@
|
||||
platform: wifi_signal
|
||||
name: ${friendly_name} RSSI
|
||||
id: ${entity_name}_rssi
|
||||
name: RSSI
|
||||
update_interval: 60s
|
||||
@@ -1,4 +1,3 @@
|
||||
platform: uptime
|
||||
name: ${friendly_name} Uptime
|
||||
id: ${entity_name}_uptime
|
||||
name: Uptime
|
||||
disabled_by_default: true
|
||||
@@ -1,8 +1,7 @@
|
||||
# Text sensors with general information.
|
||||
platform: template
|
||||
#ip_address:
|
||||
name: ${friendly_name} IP
|
||||
id: ${entity_name}_ip
|
||||
name: IP
|
||||
icon: mdi:ip-network
|
||||
entity_category: diagnostic
|
||||
disabled_by_default: true
|
||||
|
||||
@@ -1,8 +1,7 @@
|
||||
# Text sensors with general information.
|
||||
platform: template
|
||||
#mac_address:
|
||||
name: ${friendly_name} Ethernet MAC Address
|
||||
id: ${entity_name}_ethernet_mac_address
|
||||
name: Ethernet MAC Address
|
||||
disabled_by_default: true
|
||||
icon: mdi:network
|
||||
entity_category: diagnostic
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
# platform: version
|
||||
# name: ${friendly_name} ESPHome Version
|
||||
platform: version
|
||||
name: ESPHome Version
|
||||
# id: ${entity_name}_version
|
||||
# hide_timestamp: true
|
||||
# disabled_by_default: true
|
||||
hide_timestamp: true
|
||||
disabled_by_default: true
|
||||
icon: mdi:chip
|
||||
|
||||
@@ -1,22 +1,18 @@
|
||||
# Text sensors with general information.
|
||||
platform: wifi_info
|
||||
ip_address:
|
||||
name: ${friendly_name} IP
|
||||
id: ${entity_name}_ip
|
||||
name: IP
|
||||
icon: mdi:ip
|
||||
disabled_by_default: true
|
||||
ssid:
|
||||
name: ${friendly_name} SSID
|
||||
id: ${entity_name}_ssid
|
||||
name: SSID
|
||||
icon: mdi:lan
|
||||
disabled_by_default: true
|
||||
bssid:
|
||||
name: ${friendly_name} BSSID
|
||||
id: ${entity_name}_bssid
|
||||
name: BSSID
|
||||
disabled_by_default: true
|
||||
icon: mdi:router-network
|
||||
mac_address:
|
||||
name: ${friendly_name} Wifi MAC Address
|
||||
id: ${entity_name}_wifi_mac_address
|
||||
name: Wifi MAC Address
|
||||
disabled_by_default: true
|
||||
icon: mdi:wifi-cog
|
||||
@@ -1,13 +0,0 @@
|
||||
esp32_touch:
|
||||
setup_mode: ${setup_mode}
|
||||
|
||||
binary_sensor:
|
||||
- platform: esp32_touch
|
||||
name: "${friendly_name} Occupied"
|
||||
pin: ${touch_pin}
|
||||
device_class: occupancy
|
||||
icon: mdi:bed
|
||||
threshold: ${threshold}
|
||||
filters:
|
||||
- delayed_on: 5s
|
||||
- delayed_off: 10s
|
||||
@@ -16,7 +16,8 @@ wifi:
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
password: !secret EspHome_AP_PWD
|
||||
ssid: "${friendly_name}"
|
||||
password: !secret fallback_ap_password
|
||||
|
||||
# Enable fast connect
|
||||
fast_connect: true
|
||||
|
||||
@@ -11,7 +11,8 @@ wifi:
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
password: !secret EspHome_AP_PWD
|
||||
ssid: "${friendly_name}"
|
||||
password: !secret fallback_ap_password
|
||||
|
||||
sensor:
|
||||
- <<: !include sensor/rssi_sensor.config.yaml
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
captive_portal:
|
||||
|
||||
wifi:
|
||||
networks:
|
||||
- ssid: !secret Wifi_SSID
|
||||
password: !secret Wifi_PWD
|
||||
ssid: !secret Wifi_SSID
|
||||
password: !secret Wifi_PWD
|
||||
|
||||
#- ssid: !secret IoT_Wifi_SSID
|
||||
# password: !secret IoT_Wifi_PWD
|
||||
@@ -15,7 +14,8 @@ wifi:
|
||||
|
||||
# Enable fallback hotspot (captive portal) in case wifi connection fails
|
||||
ap:
|
||||
password: !secret EspHome_AP_PWD
|
||||
ssid: "${friendly_name}"
|
||||
password: !secret fallback_ap_password
|
||||
|
||||
# Enable fast connect
|
||||
fast_connect: true
|
||||
|
||||
Reference in New Issue
Block a user