Skip to content
Snippets Groups Projects
Commit 15f29f20 authored by KERDREUX Jerome's avatar KERDREUX Jerome
Browse files

Fix some missing Expose.Name usage

parent eafe2e41
No related branches found
No related tags found
No related merge requests found
...@@ -200,3 +200,32 @@ Power strip ...@@ -200,3 +200,32 @@ Power strip
│ state_l4 │ ON │ │ state_l4 │ ON │
│ state_l5 │ ON │ │ state_l5 │ ON │
╰─────────────┴─────╯ ╰─────────────┴─────╯
Ikea remote
╭───────────────────────────────╮
│ Def:0x287681fffe4a056e │
├──────────┬────────────────────┤
│ IeeeAddr │ 0x287681fffe4a056e │
│ Vendor │ IKEA │
│ Model │ E2213 │
│ Type │ EndDevice │
╰──────────┴────────────────────╯
╭──────────────────────────────────────────────────────────────────────────────────────────────────╮
│ Exp:0x287681fffe4a056e │
├─────────────┬─────────┬─────┬──────┬─────────────────┬───────────────────────────────────────────┤
│ NAME │ TYPE │ ACC │ UNIT │ VALUES │ FEATURES: NAME[TYPE]-ACC-(UNIT){PROPERTY} │
├─────────────┼─────────┼─────┼──────┼─────────────────┼───────────────────────────────────────────┤
│ identify │ enum │ W │ │ identify │ │
│ battery │ numeric │ RN │ % │ │ │
│ action │ enum │ R │ │ 1_initial_press │ │
│ │ │ │ │ 1_long_press │ │
│ │ │ │ │ 1_short_release │ │
│ │ │ │ │ 1_long_release │ │
│ │ │ │ │ 1_double_press │ │
│ │ │ │ │ 2_initial_press │ │
│ │ │ │ │ 2_long_press │ │
│ │ │ │ │ 2_short_release │ │
│ │ │ │ │ 2_long_release │ │
│ │ │ │ │ 2_double_press │ │
│ linkquality │ numeric │ R │ lqi │ │ │
╰─────────────┴─────────┴─────┴──────┴─────────────────┴───────────────────────────────────────────╯
...@@ -436,7 +436,7 @@ func (dev *ButtonRemote) update(payload map[string]interface{}) { ...@@ -436,7 +436,7 @@ func (dev *ButtonRemote) update(payload map[string]interface{}) {
func (dev *ButtonRemote) GetButtons(xaal.MessageBody) *xaal.MessageBody { func (dev *ButtonRemote) GetButtons(xaal.MessageBody) *xaal.MessageBody {
body := make(xaal.MessageBody) body := make(xaal.MessageBody)
action := dev.Z2MDevice.GetExpose("action") action := dev.Z2MDevice.GetExpose(dev.Expose.Name)
if action != nil { if action != nil {
body["buttons"] = action.Values body["buttons"] = action.Values
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment