Skip to content
Snippets Groups Projects
Commit 488a4fdd authored by void's avatar void
Browse files
parents 049abaf0 f7cd18ac
No related branches found
No related tags found
No related merge requests found
Subproject commit e8a049414bca2b14b158444dac1b94c2ca90d9be
Subproject commit 900377e4f72486f6699ecf736f96adfbc04e92da
File added
File added
......@@ -20,6 +20,9 @@
dest: "{{ basedir }}/{{ item }}"
with_items:
- config/04B03.ttf
- config/C64_Pro_Mono-STYLE.ttf
- config/tall-pixel-8x3.ttf
- config/tall-pixel-edit.ttf
- config/frekvens-dot.ttf
register: config
......@@ -34,6 +37,7 @@
- config/esphome_dach.yaml
- config/esphome_display01.yaml
- config/esphome_display02.yaml
- config/esphome_display03.yaml
- config/esphome_feinstaub01.yaml
- config/esphome_hauptraum.yaml
- config/esphome_holzwerkstatt.yaml
......
......@@ -44,29 +44,57 @@ globals:
restore_value: no
initial_value: '0'
time:
- platform: sntp
id: ntp_time
timezone: 'Europe/Berlin'
interval:
- interval: 300ms
- interval: 5s
then:
lambda: |-
if (id(coords) < -(id(length))) {
id(coords) = 0;
}
else {
id(coords) -= 2;
}
- display.page.show_next: my_display
- component.update: my_display
font:
- file: "04B03.ttf"
- file: "tall-pixel-edit.ttf"
id: b03
size: 16
size: 6
glyphs: '!"%()+=,-_.:°0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyzü'
text_sensor:
- platform: mqtt_subscribe
name: "Sensor Hauptraum Temp"
id: sensor_hauptraum_temp
topic: ESPHome/esphome_hauptraum/sensor/temp/state
- platform: mqtt_subscribe
name: "Sensor Vortragsraum Temp"
id: sensor_vortragsraum_temp
topic: ESPHome/esphome_vortragsraum/sensor/temp/state
- platform: mqtt_subscribe
name: "Sensor Kuehlschrank Temp"
id: sensor_kuehlschrank_temp
topic: ESPHome/esphome_kuehlschrank/sensor/kuehlschrank-temp/state
display:
- platform: obegraensad_panel
latch_pin: 12
clock_pin: 04
data_pin: 05
lambda: |-
std::string printout=" warpzone";
int clength = printout.length();
id(length)=clength*16;
it.print(id(coords), 0, id(b03), printout.c_str());;
\ No newline at end of file
id: my_display
pages:
- id: Page1
lambda: |-
it.printf(0,0,id(b03),"Haup");
it.printf(0,8,id(b03),"%s°C",id(sensor_hauptraum_temp).state.c_str());
- id: Page2
lambda: |-
it.printf(0,0,id(b03),"Vort");
it.printf(0,8,id(b03),"%s°C",id(sensor_vortragsraum_temp).state.c_str());
- id: Page3
lambda: |-
it.printf(0,0,id(b03),"Kühl");
it.printf(0,8,id(b03),"%s°C",id(sensor_kuehlschrank_temp).state.c_str());
- id: Page4
lambda: |-
it.strftime(4, 0, id(b03), "%H", id(ntp_time).now());
it.strftime(4, 8, id(b03), "%M", id(ntp_time).now());
\ No newline at end of file
{% set devicename = "esphome_display03" %}
{% include "/includes/ansible.inc.yaml" %}
{% include "/includes/board.esp32-doit-devkit-v1.inc.yaml" %}
# force newline
platformio_options:
upload_speed: 115200
lib_deps:
- Wire # Also required by GFX.
- SPI # Also required by GFX.
- adafruit/Adafruit BusIO # Required by GFX Library.
- adafruit/Adafruit GFX Library # Required for FrekvensPanel.
- me-no-dev/ESPAsyncTCP
external_components:
- source: github://phiten/esphome-ikea-led-matrix@master
components: [ frekvens_panel ]
refresh: 0s
{% include "/includes/common.inc.yaml" %}
light:
- platform: monochromatic
name: 'Brightness'
output: matrix_brightness
restore_mode: RESTORE_DEFAULT_ON
output:
- platform: ledc
# Enables brightness control.
max_power: 0.05
id: matrix_brightness
pin:
number: GPIO27
inverted: True
time:
- platform: sntp
id: ntp_time
timezone: 'Europe/Berlin'
font:
- file: "04B03.ttf"
id: b03
size: 8
display:
- platform: frekvens_panel
latch_pin: 13
clock_pin: 26
data_pin: 14
id: my_display
pages:
- id: Page1
lambda: |-
it.strftime(4, 0, id(b03), "%H", id(ntp_time).now());
it.strftime(4, 8, id(b03), "%M", id(ntp_time).now());
interval:
- interval: 5s
then:
- display.page.show_next: my_display
- component.update: my_display
......@@ -4,5 +4,5 @@
## Diese Device-Konfiguration wird über Ansible verwaltet.
## Direkte Änderungen in ESPHome sind nur temporär und müssen anschließend
## in das Ansible Repo übernommen werden
## https://gitlab.warpzone.ms/infrastruktur/ansible-warpzone/-/tree/master/warpsrvint/docker_esphome/templates/config
## https://gitlab.warpzone.ms/infrastruktur/ansible-warpzone/-/blob/master/intern/docker_esphome/templates/config
##############################################################################
esphome:
name: "{{ devicename }}"
platform: ESP32
board: esp32doit-devkit-v1
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