nutechsoftware / alarmdecoder-smartthings

AlarmDecoder webapp support for the SmartThings home automation platform.
Apache License 2.0
25 stars 43 forks source link

Suggestion: Simplify alarm decoder tiles #17

Closed jmaxxz closed 5 years ago

jmaxxz commented 6 years ago

In smartthings tiles must be statically declared. Since the number of zones varies from panel to panel it does not make sense to show zones on the alarm decoder device. Further more the UX weird at the moment, the most used buttons (arm, stay, disarm) are the smallest. Meanwhile the least used buttons, panic, aux, and fire are the biggest.

Below is what I propose it be changed to

    tiles(scale: 2) {
        multiAttributeTile(name: "status", type: "generic", width: 6, height: 4) {
            tileAttribute("device.panel_state", key: "PRIMARY_CONTROL") {
                attributeState "armed", label: 'Armed', icon: "st.security.alarm.on", backgroundColor: "#ffa81e"
                attributeState "armed_stay", label: 'Armed (stay)', icon: "st.security.alarm.on", backgroundColor: "#ffa81e"
                attributeState "disarmed", label: 'Disarmed', icon: "st.security.alarm.off", backgroundColor: "#79b821", defaultState: true
                attributeState "alarming", label: 'Alarming!', icon: "st.home.home2", backgroundColor: "#ff4000"
                attributeState "fire", label: 'Fire!', icon: "st.contact.contact.closed", backgroundColor: "#ff0000"
                attributeState "ready", label: 'Ready', icon: "st.security.alarm.off", backgroundColor: "#79b821"
                attributeState "notready", label: 'Not Ready', icon: "st.security.alarm.off", backgroundColor: "#e86d13"
            }
        }

        standardTile("arm_disarm", "device.panel_state", inactiveLabel: false, width: 2, height: 2) {
            state "armed", action:"lock.unlock", icon:"st.security.alarm.off", label: "DISARM"
            state "armed_stay", action:"lock.unlock", icon:"st.security.alarm.off", label: "DISARM"
            state "disarmed", action:"lock.lock", icon:"st.security.alarm.on", label: "AWAY"
            state "alarming", action:"lock.unlock", icon:"st.security.alarm.off", label: "DISARM"
            state "fire", action:"lock.unlock", icon:"st.security.alarm.off", label: "DISARM"
            state "ready", action:"lock.lock", icon:"st.security.alarm.off", label: "AWAY"
            state "notready", action:"lock.unlock", icon:"st.security.alarm.off", label: "DISARM"
        }

        standardTile("stay_disarm", "device.panel_state", inactiveLabel: false, width: 2, height: 2) {
            state "armed", action:"switch.off", icon:"st.security.alarm.off", label: "DISARM"
            state "armed_stay", action:"switch.off", icon:"st.security.alarm.off", label: "DISARM"
            state "disarmed", action:"switch.on", icon:"st.Home.home4", label: "STAY"
            state "alarming", action:"switch.off", icon:"st.security.alarm.off", label: "DISARM"
            state "fire", action:"switch.off", icon:"st.security.alarm.off", label: "DISARM"
            state "ready", action:"switch.on", icon:"st.security.alarm.off", label: "STAY"
            state "notready", action:"switch.off", icon:"st.security.alarm.off", label: "DISARM"
        }

        standardTile("panic", "device.panic_state", inactiveLabel: false, width: 2, height: 2) {
            state "default", icon:"st.alarm.alarm.alarm", label: "PANIC", nextState: "panic1", action: "panic1"
            state "panic1", icon: "st.alarm.alarm.alarm", label: "PANIC", nextState: "panic2", action: "panic2", backgroundColor: "#ffa81e"
            state "panic2", icon: "st.alarm.alarm.alarm", label: "PANIC", nextState: "default", action: "panic", backgroundColor: "#ff4000"
        }

        standardTile("refresh", "device.refresh", inactiveLabel: false, decoration: "flat", width: 6, height: 2) {
            state "default", action:"refresh.refresh", icon:"st.secondary.refresh"
        }

        main(["status"])
        details(["status", "arm_disarm", "stay_disarm", "panic", "refresh",])
    }

image

f34rdotcom commented 6 years ago

The zones do change for every panel but the lower area is only supposed to show a list of known faulted zones regardless of the zone number. I just turned these indicators into PUSH buttons to allow an easy "Bypass" of a faulted zone. This way when I am sitting next to a window I want to open up I can easy bypass it and not get up. Just open the window wait for it to show up and then press it to bypass.

Regarding the Panic vs Arm buttons size. I also mostly use the arm / disarm buttons and they are a little small. How does this look. screenshot_20180522-130509

jmaxxz commented 6 years ago

That looks great! I did not know about the bypass feature (dsc and all).