Skip to content
Snippets Groups Projects
Commit 94d61488 authored by 3d's avatar 3d
Browse files

revert to 2022.10 and update popcorn

parent 03d2621a
No related branches found
No related tags found
No related merge requests found
...@@ -4,11 +4,26 @@ ...@@ -4,11 +4,26 @@
{% include "/includes/board.esp32-doit-devkit-v1.inc.yaml" %} {% include "/includes/board.esp32-doit-devkit-v1.inc.yaml" %}
on_boot: on_boot:
priority: 250 - priority: 600
then: then:
- climate.control: - light.turn_on:
id: pid_heater id: status_led
mode: "OFF" effect: BootUp
- display.page.show: page1
- priority: 250
then:
- light.addressable_set:
id: status_led
range_from: 0
range_to: 2
red: 0%
green: 100%
blue: 0%
- priority: -100
then:
- light.turn_off:
id: status_led
- display.page.show: page3
{% include "/includes/common.inc.yaml" %} {% include "/includes/common.inc.yaml" %}
...@@ -37,6 +52,11 @@ climate: ...@@ -37,6 +52,11 @@ climate:
kp: 0.49460 kp: 0.49460
ki: 0.00487 ki: 0.00487
kd: 12.56301 kd: 12.56301
output_averaging_samples: 5 # smooth the output over 5 samples
derivative_averaging_samples: 5 # smooth the derivative value over 10 samples
deadband_parameters:
threshold_high: 1°C # deadband within +/-1°C of target_temperature
threshold_low: -1°C
visual: visual:
min_temperature: 0 min_temperature: 0
max_temperature: 275 max_temperature: 275
...@@ -125,12 +145,54 @@ binary_sensor: ...@@ -125,12 +145,54 @@ binary_sensor:
- climate.control: - climate.control:
id: pid_heater id: pid_heater
mode: "OFF" mode: "OFF"
- light.addressable_set:
id: status_led
range_from: 0
range_to: 0
red: 0%
green: 0%
blue: 0%
- light.addressable_set:
id: status_led
range_from: 1
range_to: 1
red: 0%
green: 0%
blue: 0%
- light.addressable_set:
id: status_led
range_from: 2
range_to: 2
red: 0%
green: 0%
blue: 0%
on_press: on_press:
then: then:
- climate.control: - climate.control:
id: pid_heater id: pid_heater
mode: HEAT mode: HEAT
target_temperature: 264 target_temperature: 264
- light.addressable_set:
id: status_led
range_from: 0
range_to: 0
red: 0%
green: 0%
blue: 100%
- light.addressable_set:
id: status_led
range_from: 1
range_to: 1
red: 100%
green: 0%
blue: 0%
- light.addressable_set:
id: status_led
range_from: 2
range_to: 2
red: 0%
green: 100%
blue: 0%
font: font:
- file: "gfonts://Roboto" - file: "gfonts://Roboto"
...@@ -166,22 +228,27 @@ display: ...@@ -166,22 +228,27 @@ display:
dc_pin: GPIO16 dc_pin: GPIO16
reset_pin: GPIO17 reset_pin: GPIO17
rotation: 90° rotation: 90°
pages:
- id: page1
lambda: |-
it.printf(160,120,id(text),TextAlign::CENTER,"Booting");
- id: page3
lambda: |-
it.printf(160,120,id(temp),TextAlign::CENTER,"%.0f°C",id(pid_heater).current_temperature);
if ((id(pid_heater).action) == 0) {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: OFF");
}
else if ((id(pid_heater).action) == 3) {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: HEATING");
}
else if ((id(pid_heater).action) == 4) {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: IDLE");
}
else {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: ERROR %d",id(pid_heater).action);
};
it.printf(0,230,id(text),TextAlign::BOTTOM_LEFT,"Target: %.1f°C",id(pid_heater).target_temperature);
lambda: |-
it.printf(160,120,id(temp),TextAlign::CENTER,"%.0f°C",id(pid_heater).current_temperature);
if ((id(pid_heater).action) == 0) {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: OFF");
}
else if ((id(pid_heater).action) == 3) {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: HEATING");
}
else if ((id(pid_heater).action) == 4) {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: IDLE");
}
else {
it.printf(0,10,id(text),TextAlign::TOP_LEFT,"PID: ERROR %d",id(pid_heater).action);
};
it.printf(0,230,id(text),TextAlign::BOTTOM_LEFT,"Target: %.1f°C",id(pid_heater).target_temperature);
time: time:
- platform: sntp - platform: sntp
...@@ -194,29 +261,30 @@ light: ...@@ -194,29 +261,30 @@ light:
name: "ILI9341 Display Backlight" name: "ILI9341 Display Backlight"
id: back_light id: back_light
restore_mode: ALWAYS_ON restore_mode: ALWAYS_ON
internal: True
- platform: fastled_spi - platform: fastled_spi
rgb_order: BRG rgb_order: RGB
chipset: WS2801 chipset: WS2801
id: status_led id: status_led
clock_pin: GPIO25 clock_pin: GPIO25
data_pin: GPIO26 data_pin: GPIO26
num_leds: 3 num_leds: 3
name: "NeoPixel Light" name: "NeoPixel Light"
internal: True
effects: effects:
- addressable_scan: - addressable_color_wipe:
- addressable_scan: name: BootUp
name: Scan Effect With Custom Values colors:
move_interval: 500ms - red: 100%
scan_width: 1 green: 0%
- pulse: blue: 0%
- pulse: num_leds: 3
name: "Fast Pulse" - red: 0%
transition_length: 0.5s green: 0%
update_interval: 0.5s blue: 0%
- pulse: num_leds: 3
name: "Slow Pulse" add_led_interval: 500ms
# transition_length: 1s # defaults to 1s reverse: False
update_interval: 2s
text_sensor: text_sensor:
- platform: template - platform: template
...@@ -236,4 +304,5 @@ text_sensor: ...@@ -236,4 +304,5 @@ text_sensor:
else { else {
return {"ERROR see Display"}; return {"ERROR see Display"};
} }
update_interval: 5s update_interval: 5s
\ No newline at end of file
\ No newline at end of file
...@@ -4,7 +4,7 @@ services: ...@@ -4,7 +4,7 @@ services:
app: app:
image: esphome/esphome:2022.12 image: esphome/esphome:2022.10
restart: always restart: always
volumes: volumes:
- "{{ basedir }}/config/:/config" - "{{ basedir }}/config/:/config"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment