lubeda / EsphoMaTrix

A simple DIY status display with an 8x32 RGB LED panel implemented with esphome.io and Home Assistant
MIT License
217 stars 23 forks source link

Instant alert screen? #72

Closed poblabs closed 1 year ago

poblabs commented 1 year ago

Hi, is it possible to have a new method to have an instant alert screen? I have tried to add a screen, and force that screen but it didn't work immediately. I'm looking for something that will stop the current loop, display the alert, then go back to the loop.

lubeda commented 1 year ago

i thought this was already fixed, i will take a look

lubeda commented 1 year ago

i can't find any error on this.

you have to add a screen to the queue, then you can immediatly force it to the display

poblabs commented 1 year ago

I guess I'm looking for something different. I do not want a screen in queue to show. I want to be able to instantly alert on something, have it pushed to the screen to show, then it can go away. If that doesn't exist, should I open a feature request?

lubeda commented 1 year ago

Thats already available, e.g. with this automation triggerd by incoming phone call:

- id: "1xyxcyxc7143"
  alias: EHMTX Anruf anzeigen
  trigger:
    - platform: state
      entity_id: sensor.fritz_box_6490_cable_lgi_call_monitor_phone
      attribute: to
      to: "0555123555"
  condition: []
  action:
    - data:
        icon_name: phone
        text: "someone is calling"
        lifetime: 1
        screen_time: 60
      service: esphome.awtrix_add_screen
    - service: esphome.awtrix_force_screen
      data:
        icon_name: phone
  mode: single

The icon will disapear after one minute (lifetime)

poblabs commented 1 year ago

I'll try it, thanks!

poblabs commented 1 year ago

I have some issues in testing this:

  1. If I send an alert when the time/date is on screen, it does not force it to that screen, it just adds the screen to the end of the loop
  2. When an alert is sent when the time/date is displayed, the alert isn't removed after lifetime. it stays in the loop.
  3. When the alert does show using force_screen, it does not follow the scroll_count nor the screen_time.

Here is my sample automation I used to test:

alias: Ulanzi - Alert
description: ""
trigger:
  - platform: mqtt
    topic: pob/ulanzi/alert
condition: []
action:
  - service: esphome.ulanzi_add_screen
    data:
      alarm: false
      icon_name: alert
      text: this is a test alert
      lifetime: 1
      screen_time: 10
  - service: esphome.ulanzi_force_screen
    data:
      icon_name: alert
mode: single
lubeda commented 1 year ago

thanks for this detailed analytics

lubeda commented 1 year ago

1 and 2 are fixed in fixed in 2023.4.1b

but 2023.4.1b is a complete redesign, so it is not usable yet

poblabs commented 1 year ago

I will try it when it's available, thanks!