Compare commits

...

9 Commits

Author SHA1 Message Date
Jason Williams
249d981689 Adding bindicator 2024-04-11 15:56:24 -06:00
Jason Williams
aff8f85afd Reconfiguring bedroom lightstrips after hardware refresh
Adding one additional LED to each segment
2024-04-11 15:55:50 -06:00
Jason Williams
f62e04aef1 Removing faulty onpress/onrelease code from garage.yaml 2024-04-11 15:55:06 -06:00
Jason Williams
f1db356421 Updating mqtt server address 2024-04-11 15:53:50 -06:00
Jason Williams
2789e0e4c3 Adding restart button to all ESPHome nodes 2023-06-02 11:41:07 -06:00
Jason Williams
2de799c753 Updating bedroom-lightstrips.yaml
Adding custom twinkle function and reducing the number of lights by one as a result of rewiring a faulty connection between the two sides of the bed
2023-05-25 19:47:26 -06:00
Jason Williams
c3225ab919 Update garage.yaml
Adding additional code to immediately set the status of the garage door when the status of the fully open or fully closed sensor changes
2023-05-15 11:54:03 -06:00
Jason Williams
9ebe7e5a82 Removing laundry 2023-05-15 11:39:10 -06:00
Jason Williams
b9144437fe Update bedroom-lightstrips.yaml
Cleaning up spacing, etc.
2023-05-15 11:38:12 -06:00
8 changed files with 200 additions and 163 deletions

View File

@@ -15,7 +15,7 @@ wifi:
fast_connect: true fast_connect: true
mqtt: mqtt:
broker: henry.int.jnf.me broker: mqtt.srv.jnf.me
username: esphome username: esphome
password: esphome password: esphome
topic_prefix: esphome/basement topic_prefix: esphome/basement
@@ -49,3 +49,7 @@ binary_sensor:
filters: filters:
- invert - invert
- delayed_off: 5s - delayed_off: 5s
button:
- platform: restart
name: "Restart"

View File

@@ -17,7 +17,7 @@ wifi:
fast_connect: true fast_connect: true
mqtt: mqtt:
broker: henry.int.jnf.me broker: mqtt.srv.jnf.me
username: esphome username: esphome
password: esphome password: esphome
topic_prefix: esphome/bedroom-lightstrips topic_prefix: esphome/bedroom-lightstrips
@@ -42,7 +42,18 @@ light:
- addressable_rainbow - addressable_rainbow
- addressable_color_wipe - addressable_color_wipe
- addressable_scan - addressable_scan
- addressable_twinkle - addressable_twinkle:
name: Twinkle Light
twinkle_probability: 5%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Medium
twinkle_probability: 15%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Heavy
twinkle_probability: 85%
progress_interval: 10ms
- addressable_random_twinkle - addressable_random_twinkle
- addressable_fireworks - addressable_fireworks
- addressable_flicker - addressable_flicker
@@ -59,12 +70,22 @@ light:
- addressable_rainbow - addressable_rainbow
- addressable_color_wipe - addressable_color_wipe
- addressable_scan - addressable_scan
- addressable_twinkle - addressable_twinkle:
name: Twinkle Light
twinkle_probability: 5%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Medium
twinkle_probability: 15%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Heavy
twinkle_probability: 85%
progress_interval: 10ms
- addressable_random_twinkle - addressable_random_twinkle
- addressable_fireworks - addressable_fireworks
- addressable_flicker - addressable_flicker
- platform: neopixelbus - platform: neopixelbus
name: "Headboard Lights" name: "Headboard Lights"
id: headboardlights id: headboardlights
@@ -75,12 +96,21 @@ light:
- addressable_rainbow - addressable_rainbow
- addressable_color_wipe - addressable_color_wipe
- addressable_scan - addressable_scan
- addressable_twinkle - addressable_twinkle:
- addressable_random_twinkle name: Twinkle Light
twinkle_probability: 5%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Medium
twinkle_probability: 15%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Heavy
twinkle_probability: 85%
progress_interval: 10ms
- addressable_fireworks - addressable_fireworks
- addressable_flicker - addressable_flicker
- platform: neopixelbus - platform: neopixelbus
name: "Tree Lights" name: "Tree Lights"
id: treelights id: treelights
@@ -91,7 +121,22 @@ light:
- addressable_rainbow - addressable_rainbow
- addressable_color_wipe - addressable_color_wipe
- addressable_scan - addressable_scan
- addressable_twinkle - addressable_twinkle:
name: Twinkle Light
twinkle_probability: 5%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Medium
twinkle_probability: 15%
progress_interval: 10ms
- addressable_twinkle:
name: Twinkle Heavy
twinkle_probability: 85%
progress_interval: 10ms
- addressable_random_twinkle - addressable_random_twinkle
- addressable_fireworks - addressable_fireworks
- addressable_flicker - addressable_flicker
button:
- platform: restart
name: "Restart"

101
bindicator.yaml Normal file
View File

@@ -0,0 +1,101 @@
esphome:
name: bindicator
esp32:
board: esp32-c3-devkitm-1
framework:
type: arduino
logger:
level: INfO
baud_rate: 0
ota:
password: "bd2c004f2016fde90fbbb01706ad039a"
wifi:
ssid: !secret ssid
password: !secret pass
mqtt:
broker: mqtt.srv.jnf.me
username: esphome
password: esphome
topic_prefix: esphome/bindicator
light:
- platform: neopixelbus
name: "Bindicator"
id: bindicator
variant: WS2812X
pin: 0
num_leds: 2
effects:
- lambda:
name: Pulsing
update_interval: 1s
lambda: |-
static int loopnum = 0;
auto call = id(bindicator).turn_on();
call.set_brightness(1);
call.set_transition_length(1000);
if (loopnum == 0) {
call.set_brightness(0.5);
} else if (loopnum == 1) {
call.set_brightness(1);
}
call.perform();
loopnum++;
if (loopnum == 30) loopnum = 0;
- platform: partition
name: "Bindicator - Bottom"
id: bindicatorbottom
segments:
- id: bindicator
from: 0
to: 0
effects:
- lambda:
name: Pulsing
update_interval: 1s
lambda: |-
static int loopnum = 0;
auto call = id(bindicatorbottom).turn_on();
call.set_brightness(1);
call.set_transition_length(1500);
if (loopnum == 0) {
call.set_brightness(0.5);
} else if (loopnum == 1) {
call.set_brightness(1);
}
call.perform();
loopnum++;
if (loopnum == 30) loopnum = 0;
- platform: partition
name: "Bindicator - Top"
id: bindicatortop
segments:
- id: bindicator
from: 1
to: 1
effects:
- lambda:
name: Pulsing
update_interval: 1s
lambda: |-
static int loopnum = 0;
auto call = id(bindicatortop).turn_on();
call.set_brightness(1);
call.set_transition_length(1500);
if (loopnum == 0) {
call.set_brightness(0.5);
} else if (loopnum == 1) {
call.set_brightness(1);
}
call.perform();
loopnum++;
if (loopnum == 30) loopnum = 0;

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 182 KiB

View File

@@ -15,7 +15,7 @@ wifi:
fast_connect: true fast_connect: true
mqtt: mqtt:
broker: henry.int.jnf.me broker: mqtt.srv.jnf.me
username: esphome username: esphome
password: esphome password: esphome
topic_prefix: esphome/garage topic_prefix: esphome/garage
@@ -63,33 +63,39 @@ binary_sensor:
device_class: door device_class: door
id: garage_door_open id: garage_door_open
filters: filters:
- invert: - invert
on_press: # on_press:
then: # then:
- lambda: |- # - lambda: |-
id(garage_door_state).publish_state("Open"); # //id(garage_door).current_operation = COVER_OPERATION_IDLE;
on_release: # //id(garage_door).position = COVER_OPEN;
then: # //id(garage_door_state).publish_state("Open");
- lambda: |- # on_release:
id(garage_door).current_operation = COVER_OPERATION_CLOSING; # then:
id(garage_door).publish_state(); # - lambda: |-
id(garage_door_state).publish_state("Moving"); # //id(garage_door).current_operation = COVER_OPERATION_CLOSING;
# //id(garage_door).publish_state();
# //id(garage_door_state).publish_state("Moving");
- platform: gpio - platform: gpio
pin: D1 pin: D1
id: garage_door_closed id: garage_door_closed
filters: filters:
- invert: - invert
internal: true internal: true
on_press: # on_press:
then: # then:
- lambda: |- # - lambda: |-
id(garage_door_state).publish_state("Closed"); # //id(garage_door).current_operation = COVER_OPERATION_IDLE;
on_release: # //id(garage_door).position = COVER_CLOSED;
then: # //id(garage_door_state).publish_state("Closed");
- lambda: |- # on_release:
id(garage_door).current_operation = COVER_OPERATION_OPENING; # then:
id(garage_door).publish_state(); # - lambda: |-
id(garage_door_state).publish_state("Moving"); # //id(garage_door).current_operation = COVER_OPERATION_OPENING;
# //id(garage_door).publish_state();
# //id(garage_door_state).publish_state("Moving");
- platform: gpio - platform: gpio
pin: D2 pin: D2
name: "Side Door" name: "Side Door"
@@ -156,3 +162,7 @@ cover:
binary_sensor.is_on: garage_door_open binary_sensor.is_on: garage_door_open
then: then:
- switch.turn_on: garage_door_switch - switch.turn_on: garage_door_switch
button:
- platform: restart
name: "Restart"

View File

@@ -15,7 +15,7 @@ wifi:
fast_connect: true fast_connect: true
mqtt: mqtt:
broker: henry.int.jnf.me broker: mqtt.srv.jnf.me
username: esphome username: esphome
password: esphome password: esphome
topic_prefix: esphome/houseplant topic_prefix: esphome/houseplant
@@ -38,3 +38,7 @@ sensor:
return (std::string) "https://jasonsplant.jaywll.co/newreading?v=" + to_string(int(id(moisture_level).state)); return (std::string) "https://jasonsplant.jaywll.co/newreading?v=" + to_string(int(id(moisture_level).state));
headers: headers:
auth-key: !secret houseplant_key auth-key: !secret houseplant_key
button:
- platform: restart
name: "Restart"

View File

@@ -1,127 +0,0 @@
esphome:
name: laundry
platform: ESP8266
board: nodemcuv2
logger:
level: INFO
ota:
password: "03af999284928f8525c82a13771a4a4f"
wifi:
ssid: !secret ssid
password: !secret pass
fast_connect: true
mqtt:
broker: henry.int.jnf.me
username: esphome
password: esphome
topic_prefix: esphome/laundry
i2c:
sda: D6
scl: D5
scan: True
id: bus_a
sensor:
- platform: mpu6050
address: 0x68
update_interval: 1s
gyro_x:
name: "Dryer Gyro X"
id: dryer_gyro_x
internal: true
gyro_y:
name: "Dryer Gyro Y"
id: dryer_gyro_y
internal: true
gyro_z:
name: "Dryer Gyro Z"
id: dryer_gyro_z
internal: true
temperature:
name: "Dryer Temperature"
filters:
- throttle: 30s
- platform: mpu6050
address: 0x69
update_interval: 1s
gyro_x:
name: "Washer Gyro X"
id: washer_gyro_x
internal: true
gyro_y:
name: "Washer Gyro Y"
id: washer_gyro_y
internal: true
gyro_z:
name: "Washer Gyro Z"
id: washer_gyro_z
internal: true
temperature:
name: "Washer Temperature"
filters:
- throttle: 30s
- platform: template
name: "Dryer Gyro All"
id: dryer_gyro_all
unit_of_measurement: °/s²
lambda: |-
return fabs(id(dryer_gyro_x).state) + fabs(id(dryer_gyro_y).state) + fabs(id(dryer_gyro_z).state);
update_interval: 1s
filters:
- lambda: |-
static float last_dryer_value = 0;
static float dryer_change = 0;
dryer_change = x - last_dryer_value;
last_dryer_value = x;
return fabs(dryer_change);
- sliding_window_moving_average:
window_size: 120
send_every: 10
- platform: template
name: "Washer Gyro All"
id: washer_gyro_all
unit_of_measurement: °/s²
lambda: |-
return fabs(id(washer_gyro_x).state) + fabs(id(washer_gyro_y).state) + fabs(id(washer_gyro_z).state);
update_interval: 1s
filters:
- lambda: |-
static float last_washer_value = 0;
static float washer_change = 0;
washer_change = x - last_washer_value;
last_washer_value = x;
return fabs(washer_change);
- sliding_window_moving_average:
window_size: 120
send_every: 10
binary_sensor:
- platform: template
name: "Dryer"
id: dryer
lambda: |-
if (id(dryer_gyro_all).state >= 2.0) {
return true;
} else {
return false;
}
filters:
- delayed_on: 30s
- delayed_off: 60s
- platform: template
name: "Washer"
id: washer
lambda: |-
if (id(washer_gyro_all).state >= 1.0) {
return true;
} else {
return false;
}
filters:
- delayed_on: 30s
- delayed_off: 120s