Features Wishlist
Missing camera option for esphome.DEVICE_screen_show_alert
Hi,
First of all, thank you very much for the great and intuitive implementation! This is the first time I’ve really enjoyed using the Guition display!
Would it be possible to add an option to esphome.DEVICE_screen_show_alert for displaying a camera image like for the 'esp_screens_show_alert' event?
According to the sample code, the camera option isn’t included there yet, and adding it manually results in an error:
action: esphome.wohnzimmer_screen_show_alert
data:
title: "Jemand ist an der Tür"
subtitle: "Tür 3, hinten"
icon: doorbell
color: orange
button_text: "Komme"
timeout: 0
flash: true
camera: camera.doorbell # Added by me.
Without the camera extension, the alarm message works without any problems.
According to the instructions in the ESP Screen Manager, the manual event function esp_screens_show_alert should include the camera option, but unfortunately, this event doesn't trigger anything for me, whether or not there's a camera image.
Discussion 3
Add a commentThanks, glad you enjoy it on the Guition!
You found a real gap.
esphome.wohnzimmer_screen_show_alertis the screen's own ESPHome action, and Home Assistant only accepts the fields it declares and makes every one of them required. That is whycameragives an error there, and why we can't simply add it: every existing automation that callsshow_alertwould break. The camera picture is fetched and sent by ESP Screen Manager, so it only came with theesp_screens_show_alertevent, and that event always went to every screen.From app 0.2.133 the event takes
screen, so the alert with its camera picture goes to that one screen only:screentakes the device name (thewohnzimmer_screenfrom your action works as is), the name Home Assistant shows for the screen, or a room, which reaches every screen in it. A list such as[wohnzimmer_screen, kitchen_screen]reaches several. A name that matches no screen sends nothing, and the ESP Screen Manager log then lists the screens it knows. In ESP Screens, Alerts has a new One screen part that shows exactly what to fill in for each of your screens, ready to copy.About the event not doing anything for you: I tested it here on a Guition with a camera and the picture showed within a few seconds. Note that it has to run as a step in an automation or script, as above, not under Developer tools → Actions. If it still does nothing after updating, could you share the lines in the ESP Screen Manager log right after you fire it? There is one starting with
esp_screens_show_alert:that says which screens were reached and why any were skipped.Like my work? Consider buying me a coffee, much appreciated!
Original on GitHub
Thank you so much for the quick explanation and for adjusting the event for a single screen! I guess I didn't have the indentation set up correctly in the automation. Now it worked exactly the way I imagined it would. It's amazing how easily you made it possible to achieve something so practical!
Original on GitHub
Amazing!! Happy to help, this whole project is just something i missed for so long... i just wanted to make this all very easy and just as easy as home assistant itself. So nice that you get that.
Original on GitHub