-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
610bfcf
commit cfbd00e
Showing
10 changed files
with
209 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,4 +25,3 @@ remote_receiver: | |
# filter: 250us | ||
# idle: 4ms | ||
# buffer_size: 2kb | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
substitutions: | ||
friendly_name: "CT clamp" | ||
friendly_id: "ctclamp" | ||
|
||
packages: | ||
device_base: !include device_base_esp32.yaml | ||
|
||
sensor: | ||
- platform: ct_clamp | ||
sensor: adc_sensor | ||
name: "Measured Current" | ||
id: current | ||
sample_duration: 600ms | ||
update_interval: 3000ms | ||
filters: | ||
- calibrate_linear: | ||
- 0.012 -> 0 | ||
- 0.025 -> 1.0 | ||
|
||
- platform: adc | ||
pin: GPIO32 | ||
id: adc_sensor | ||
attenuation: 11db | ||
# update_interval: never | ||
update_interval: 3000ms |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
esphome: | ||
name: $friendly_id | ||
|
||
esp8266: | ||
board: esp07 | ||
|
||
# board: nodemcuv2 | ||
# platform = espressif8266 | ||
|
||
restore_from_flash: true | ||
framework: | ||
version: recommended | ||
|
||
|
||
|
||
logger: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,14 @@ | ||
esphome: | ||
name: $friendly_id | ||
|
||
esp8266: | ||
board: nodemcuv2 | ||
|
||
# board: nodemcuv2 | ||
# platform = espressif8266 | ||
|
||
restore_from_flash: true | ||
framework: | ||
version: recommended | ||
|
||
|
||
logger: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,70 +1,71 @@ | ||
esphome: | ||
name: $friendly_name | ||
platform: ESP32 | ||
board: esp32dev | ||
board: nodemcu-32s | ||
|
||
wifi: | ||
ssid: !secret wifi_ssid | ||
password: !secret wifi_password | ||
# wifi: | ||
# ssid: !secret wifi_ssid | ||
# password: !secret wifi_password | ||
|
||
logger: | ||
api: | ||
ota: | ||
captive_portal: | ||
|
||
switch: | ||
- platform: restart | ||
id: restart1 | ||
name: $friendly_name ESP32 Restart | ||
# api: | ||
# ota: | ||
# captive_portal: | ||
|
||
time: | ||
- platform: homeassistant | ||
on_time: | ||
# Every morning at 12:30am | ||
- seconds: 0 | ||
minutes: 30 | ||
hours: 0 | ||
then: | ||
- switch.turn_on: restart1 | ||
# switch: | ||
# - platform: restart | ||
# id: restart1 | ||
# name: $friendly_name ESP32 Restart | ||
|
||
# time: | ||
# - platform: homeassistant | ||
# on_time: | ||
# # Every morning at 12:30am | ||
# - seconds: 0 | ||
# minutes: 30 | ||
# hours: 0 | ||
# then: | ||
# - switch.turn_on: restart1 | ||
|
||
text_sensor: | ||
# Send IP Address | ||
- platform: wifi_info | ||
ip_address: | ||
name: "$friendly_name IP Address" | ||
# text_sensor: | ||
# # Send IP Address | ||
# - platform: wifi_info | ||
# ip_address: | ||
# name: "$friendly_name IP Address" | ||
|
||
# Send Uptime in raw seconds | ||
- platform: template | ||
name: $friendly_name Uptime | ||
id: uptime_human | ||
icon: mdi:clock-start | ||
# # Send Uptime in raw seconds | ||
# - platform: template | ||
# name: $friendly_name Uptime | ||
# id: uptime_human | ||
# icon: mdi:clock-start | ||
|
||
# Sensors that the ESPhome unit is capable of reporting | ||
sensor: | ||
- platform: wifi_signal | ||
name: "$friendly_name WiFi Signal" | ||
update_interval: 10min | ||
# # Sensors that the ESPhome unit is capable of reporting | ||
# sensor: | ||
# - platform: wifi_signal | ||
# name: "$friendly_name WiFi Signal" | ||
# update_interval: 10min | ||
|
||
- platform: uptime | ||
internal: true | ||
id: uptime_sensor | ||
update_interval: 10min | ||
on_raw_value: | ||
then: | ||
- text_sensor.template.publish: | ||
id: uptime_human | ||
# Custom C++ code to generate the result | ||
state: !lambda |- | ||
int seconds = round(id(uptime_sensor).raw_state); | ||
int days = seconds / (24 * 3600); | ||
seconds = seconds % (24 * 3600); | ||
int hours = seconds / 3600; | ||
seconds = seconds % 3600; | ||
int minutes = seconds / 60; | ||
seconds = seconds % 60; | ||
return ( | ||
(days ? to_string(days) + "d " : "") + | ||
(hours ? to_string(hours) + "h " : "") + | ||
(minutes ? to_string(minutes) + "m " : "") + | ||
(to_string(seconds) + "s") | ||
).c_str(); | ||
# - platform: uptime | ||
# internal: true | ||
# id: uptime_sensor | ||
# update_interval: 10min | ||
# on_raw_value: | ||
# then: | ||
# - text_sensor.template.publish: | ||
# id: uptime_human | ||
# # Custom C++ code to generate the result | ||
# state: !lambda |- | ||
# int seconds = round(id(uptime_sensor).raw_state); | ||
# int days = seconds / (24 * 3600); | ||
# seconds = seconds % (24 * 3600); | ||
# int hours = seconds / 3600; | ||
# seconds = seconds % 3600; | ||
# int minutes = seconds / 60; | ||
# seconds = seconds % 60; | ||
# return ( | ||
# (days ? to_string(days) + "d " : "") + | ||
# (hours ? to_string(hours) + "h " : "") + | ||
# (minutes ? to_string(minutes) + "m " : "") + | ||
# (to_string(seconds) + "s") | ||
# ).c_str(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
substitutions: | ||
friendly_name: "Test" | ||
friendly_id: "test" | ||
|
||
packages: | ||
device_base: !include device_base_esp32.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
substitutions: | ||
friendly_name: fumeextractor | ||
friendly_id: fumeextractor | ||
|
||
packages: | ||
# device_base: !include device_base_esp32_nonetwork.yaml | ||
device_base: !include device_base_8266_nodemcu.yaml | ||
|
||
# ESP32 | ||
# sensor: | ||
# - platform: adc | ||
# name: "fanpot" | ||
# pin: GPIO2 | ||
# accuracy_decimals: 2 | ||
# update_interval: 100ms | ||
# attenuation: auto | ||
# filters: | ||
# - calibrate_linear: | ||
# - 0.075 -> 0.0 | ||
# - 3.148 -> 3.3 | ||
# - delta: 0.01 | ||
|
||
output: | ||
- platform: esp8266_pwm | ||
pin: D0 | ||
id: fan | ||
frequency: 25kHz | ||
# inverted: false | ||
# min_power: 0.01 | ||
# max_power: 0.75 | ||
|
||
sensor: | ||
- platform: adc | ||
name: "fanpot" | ||
id: fanpot | ||
pin: A0 | ||
raw: true | ||
accuracy_decimals: 1 | ||
update_interval: 100ms | ||
# attenuation: auto | ||
filters: | ||
- calibrate_linear: | ||
- 0 -> 0.0 | ||
- 1024 -> 1000 | ||
- delta: 10 | ||
- multiply: 0.001 | ||
on_value: | ||
then: | ||
- output.set_level: | ||
id: fan | ||
level: !lambda return id(fanpot).state; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.