• 10 dec 2017: forum version update. In case of issues use this topic.
  • 30 nov 2017: pilight moved servers. In case of issues use this topic.
Hello There, Guest! Login Register


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Done] generic_label protocol
#1
This is (basically a copy of an other post, but) an idea for a generic information saving and displaying. It is a device with custom user-defined states with a gui-element of type "label" or "string". Logically it is a generic device with protocol "generic_label" for displaying any possible sort of information and switching logic, but without any send or receive to be used in gui and eventing. This way, all devices without gui elements can be shown if needed.

To give an example, this is a sample elro_he_contact which doesn't have any displayed element:
Code:
"door": {
        "protocol": [{ "elro_he_contact }],
        "id": [{ "systemcode": 1, "unitcode": 2 }],
        "state": "opened"
}

This is what we want to acchieve in the gui:
Door State: Opened

This is the device entry within config.json:
Code:
"genericlabel1" {
        "protocol": [{ "generic_label" }],
        "states": [{ "Opened", "Closed" }],
        "state": "Opened"
}

This is the eventing rule to make this all work:
Code:
"update-my-label-opened": {
        "rule": "IF door.state IS opened THEN switch DEVICE genericlabel1 TO Opened",
        "active": 1
}

Backlink to the original post: http://forum.pilight.org/Thread-pilight-...03#pid9503
 
Reply
#2
Can you post your request on the pilight github?
https://github.com/pilight/pilight/issues

According to these rules:
https://github.com/pilight/pilight/blob/...IBUTING.md
 
Reply
#3
Done in latest nightly code. Label action will follow soon.
 
Reply
  


Possibly Related Threads...
Thread Author Replies Views Last Post
  [Done] Presence Detection (ping protocol) atahualpa 3 2,988 01-07-2015, 07:01 PM
Last Post: curlymo
  [Done] Datetime protocol, day of the week Niek 1 2,403 01-05-2015, 08:14 PM
Last Post: curlymo
  [Done] Doorbell GPIO input (gpio_switch protocol) Jeroenk 24 14,016 12-24-2014, 10:20 AM
Last Post: curlymo
  [Done] The generic weather protocol is not generic enough Tweakertje 4 3,476 09-25-2013, 08:16 PM
Last Post: curlymo

Forum Jump:


Browsing: 1 Guest(s)