sairon / esphome-nspanel-lovelace-ui

ESPHome component for NSPanel Lovelace UI
Other
126 stars 32 forks source link

New full screen notifications #22

Closed mruizh closed 1 year ago

mruizh commented 1 year ago

Hi , I have updated to NsPanel Lovelace v.3.9.4 and tested some new features with last tft firmware updated in Nspanel. I can confirm that new functions like screensaver runs directly in apps.yaml and with little changes in nspanel.yaml, Full Screen Notification works with icon, colors and font sizes.

This is my nspanel.yaml.

# Service to send a command To show the screen of a specific like
# interaction of the buttons are on implemented yet
# New Variables icon . Not all implemented. Icon must be "U" value (copy and paste).
- service: notify_fullscreen
  variables:
    title: string
    description: string
    button1: string
    button2: string
    time_secs: string
    icon: string
  then:
    # show notification screen
    - lambda: 'id(nspanel).send_custom_command("pageType~popupNotify");'
    # set values on notification screen
    # color defined as number created in binary and converted to decimal (rrrrggggbbbbaaaa)
    #- lambda: 'id(nspanel).send_custom_command("entityUpdateDetail~id~"+ title + "~65535~" + button1 +"~3840~" + button2 + "~61440~" + description + "~65535~" + time_secs);'
    # New funcionalities v 3.9.4
    #entityUpdateDetail~internalName~heading~headingColor~button1text~button1color~button2text~tB2Color~notificationText~textColor~sleepTimeout~fontIdText~icon~iconColor

    - lambda: 'id(nspanel).send_custom_command("entityUpdateDetail~id~"+ title + "~65535~" + button1 +"~3840~" + button2 + "~61440~" + description + "~65535~" + time_secs + "~3~" + icon + "~65535~");'
    - rtttl.play: "scale_up:d=32,o=5,b=100:c,c#,d#,e,f#,g#,a#,b"

Enjoy it!

sairon commented 1 year ago

Thanks for the heads-up! But since this is a tip rather than an issue, I'm closing it, next time please use the discussions page.

mruizh commented 1 year ago

Yes! my fault.

2 de febrero de 2023 20:23, "Jan Čermák" @. @*.**@*.***>)> escribió: Thanks for the heads-up! But since this is a tip rather than an issue, I'm closing it, next time please use the discussions (https://github.com/sairon/esphome-nspanel-lovelace-ui/discussions) page.

Reply to this email directly, view it on GitHub (https://github.com/sairon/esphome-nspanel-lovelace-ui/issues/22#issuecomment-1414246264), or unsubscribe (https://github.com/notifications/unsubscribe-auth/AGJVXVHAASSLO2DKJXUYGZLWVQCR7ANCNFSM6AAAAAAUPHTUCA). You are receiving this because you authored the thread.Message ID: @.***>