Legrand Self-e batteryless switches (ZLGP1X)

Sorry, wrong deconz.list for apt… I was on the stable channel.

Let me try again with the beta one.

Ok, build went fine.

New issue: the deCONZ app crashes at start:

Removed ~/.local/share/dresden-elektronik
Rebooted
No more crashes.

For the 1 button switch (0 677 23L or ZLGP17):
Device commissioning : options.byte 0xC5 , extOptions.byte 0xF2 , gpdsrcid 5345230 , command 0x02 , Payload 02c5f20164366c366d12f5587972fd1dae3dee65ff1de0f001000004022220

For the 2 buttons switch (0 677 24L or ZLGP18):
Button 1: Device commissioning : options.byte 0xC5 , extOptions.byte 0xF2 , gpdsrcid 5375258 , command 0x02 , Payload 02c5f29ddf38cc0baaa63c6d8c31176a7d50892a7f84e35f00000004022220
Button 2: Device commissioning : options.byte 0xC5 , extOptions.byte 0xF2 , gpdsrcid 5375259 , command 0x02 , Payload 02c5f2361cf5a1f812cebb4744edfec5d591f07fe3e2935800000004022220

Hu ? I don’t understand what happen, how have you this idea ?

So have updated the code

cd deconz-rest-plugin
git pull
qmake && make -j2
sudo cp ../libde_rest_plugin.so /usr/share/deCONZ/plugins

Compilation will be faster.

With this code (if I m right), the device can be reconized, and some action can have value on “state/buttonevent” value on the JSON (only 2 for the moment).

I have added one more debug line, to check the paylaod because, you have only 2 command used by this device
// It use as command
// 0x20 GpCommandIdOff
// 0x22 GpCommandIdToggle

So I need to check if I can find something more in the payload to use (like for the FOHSWITCH)

But can be fine as I think this device will create 1 entry by button.

I m using “ZGPSWITCH” as model type, but not sure it will be enought to make the device visible in phoscon, so pls check the API too.

What do mean exactly by “the device can be recognized” ? As a switch in the Phoscon app ?

I pulled the changes, but I don’t really know what you want me to do next. The switch still isn’t in the Phoscon app, and here are the deCONZ logs:

Join procedure for the 2 buttons switch:

09:50:39:371 ZGP srcId: 0x0052051A cmd: 0xE0 frameCounter: 0
09:50:39:372 Incoming ZGP Frame: gpdsrcid 5375258, command 0xE0, Payload 02c5f29ddf38cc0baaa63c6d8c31176a7d50892a7f84e36200000004022220
09:50:39:372 OpenSSl version 0x1010106F loaded
09:50:39:372 Device commissioning : options.byte 0xC5, extOptions.byte 0xF2
09:50:39:373 unsupported green power device 0x02

09:50:44:184 ZGP srcId: 0x0052051B cmd: 0xE0 frameCounter: 0
09:50:44:185 Incoming ZGP Frame: gpdsrcid 5375259, command 0xE0, Payload 02c5f2361cf5a1f812cebb4744edfec5d591f07fe3e2935f00000004022220
09:50:44:185 OpenSSl version 0x1010106F loaded
09:50:44:185 Device commissioning : options.byte 0xC5, extOptions.byte 0xF2
09:50:44:185 unsupported green power device 0x02

Some successive pushes:

09:55:39:620 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 102
09:55:39:620 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload bd40fa64
09:55:40:493 ZGP srcId: 0x0052051B cmd: 0x22 frameCounter: 98
09:55:40:493 Incoming ZGP Frame: gpdsrcid 5375259, command 0x22, Payload adf03b65
09:55:42:608 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 104
09:55:42:608 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload cf9851c8
09:55:43:326 ZGP srcId: 0x0052051B cmd: 0x22 frameCounter: 100
09:55:43:326 Incoming ZGP Frame: gpdsrcid 5375259, command 0x22, Payload 053c8f23
09:55:46:543 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 106
09:55:46:543 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload 55b1321c
09:55:49:238 ZGP srcId: 0x0052051A cmd: 0x20 frameCounter: 109
09:55:49:238 Incoming ZGP Frame: gpdsrcid 5375258, command 0x20, Payload 448d6cd6
09:55:53:577 ZGP srcId: 0x0052051A cmd: 0x20 frameCounter: 111
09:55:53:577 Incoming ZGP Frame: gpdsrcid 5375258, command 0x20, Payload 151c6beb
09:55:54:439 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 112
09:55:54:440 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload cde020de
09:55:54:822 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 114
09:55:54:822 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload 9da09106
09:55:55:178 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 116
09:55:55:178 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload 1ceb5e95
09:55:55:485 ZGP srcId: 0x0052051A cmd: 0x20 frameCounter: 119
09:55:55:485 Incoming ZGP Frame: gpdsrcid 5375258, command 0x20, Payload 1e3d6e43
09:55:55:855 ZGP srcId: 0x0052051A cmd: 0x20 frameCounter: 121
09:55:55:855 Incoming ZGP Frame: gpdsrcid 5375258, command 0x20, Payload efc3a7d2
09:55:56:286 ZGP srcId: 0x0052051A cmd: 0x20 frameCounter: 123
09:55:56:287 Incoming ZGP Frame: gpdsrcid 5375258, command 0x20, Payload 5bc7d041

Because I’m so lame, I installed deconz-dev from the stable APT repository, then launched the app to verify my VM USB passthrough settings. Then, I realized I was on the stable channel, so, I switched to the beta channel, re-installed deconz-dev from there, and launched the app. But all the initial configuration was already done by the “stable” version of the app, so I think there was some conflicts. Purging the folder forced the app to properly apply the initial config. The reboot was just in case…

Ok, my bad, Have used the type 0x07 (GpDeviceIdGenericSwitch) and your device is a 0x02 (GpDeviceIdOnOffSwitch).

What do mean exactly by “the device can be recognized” ? As a switch in the Phoscon app ?

As switch in the API at least, IDK for other, will be the surprise.

Can use the new code.

cd deconz-rest-plugin
git pull
qmake && make -j2
sudo cp ../libde_rest_plugin.so /usr/share/deCONZ/plugins

I think it will be fine now.

BTW if you have problem to use the API without third app (not sure phoscon will be enought), can use the beta version of phoscon http://phoscon.de/pwabeta in help / API information

Join procedure for the 1 button switch:

16:59:41:311 ZGP srcId: 0x00518FCE cmd: 0xE0 frameCounter: 0
16:59:41:311 Incoming ZGP Frame: gpdsrcid 5345230, command 0xE0, Payload 02c5f20164366c366d12f5587972fd1dae3dee65ff1de0a002000004022220
16:59:41:311 OpenSSl version 0x1010106F loaded
16:59:41:311 Device commissioning : options.byte 0xC5, extOptions.byte 0xF2
16:59:41:311 sql exec SELECT sid FROM sensors WHERE deletedState = 'deleted'
16:59:41:312 SensorNode 2: Hue Tap 2 added
16:59:41:312 enqueue event event/added for /sensors/2
16:59:41:312 ZGP button 224 ZGPSWITCH
16:59:41:312 enqueue event state/buttonevent for /sensors/2
16:59:41:312 enqueue event state/lastupdated for /sensors/2
16:59:41:315 Websocket 10.0.2.15:52362 send message: {"e":"added","id":"2","r":"sensors","sensor":{"config":{"on":true},"ep":242,"etag":"d52513c3e22d6f438dcdc328da65dfa2","id":"2","lastseen":"2021-07-12T14:59Z","manufacturername":"Legrand","modelid":"ZGPSWITCH","name":"Hue Tap 2","state":{"buttonevent":224,"lastupdated":"2021-07-12T14:59:41.312"},"type":"ZGPSwitch","uniqueid":"00:00:00:00:00:51:8f:ce-f2"},"t":"event","uniqueid":"00:00:00:00:00:51:8f:ce-f2"} (ret = 408)
16:59:41:324 Websocket 10.0.2.15:52362 send message: {"e":"changed","id":"2","r":"sensors","state":{"buttonevent":224,"lastupdated":"2021-07-12T14:59:41.312"},"t":"event","uniqueid":"00:00:00:00:00:51:8f:ce-f2"} (ret = 158)
16:59:41:331 discard sensor state push for 2: state/lastupdated (already pushed)

API information:

{
    "config": {
        "on": true
    },
    "ep": 242,
    "etag": "c54f887315686dc8f1a2b4530bdfcfe6",
    "lastseen": "2021-07-12T15:04Z",
    "manufacturername": "Legrand",
    "modelid": "ZGPSWITCH",
    "name": "Hue Tap 2",
    "state": {
        "buttonevent": 34,
        "lastupdated": "2021-07-12T15:04:10.063"
    },
    "type": "ZGPSwitch",
    "uniqueid": "00:00:00:00:00:51:8f:ce-f2"
}

1 short press:

17:00:45:097 ZGP srcId: 0x00518FCE cmd: 0x22 frameCounter: 675
17:00:45:098 Incoming ZGP Frame: gpdsrcid 5345230, command 0x22, Payload 60905874
17:00:45:098 ZGP button 34 ZGPSWITCH
17:00:45:098 enqueue event state/buttonevent for /sensors/2
17:00:45:098 enqueue event state/lastupdated for /sensors/2
17:00:45:099 Websocket 10.0.2.15:52362 send message: {"e":"changed","id":"2","r":"sensors","state":{"buttonevent":34,"lastupdated":"2021-07-12T15:00:45.098"},"t":"event","uniqueid":"00:00:00:00:00:51:8f:ce-f2"} (ret = 157)
17:00:45:102 discard sensor state push for 2: state/lastupdated (already pushed)

API event:

{
    "17:04:10:70": {
        "e": "changed",
        "id": "2",
        "r": "sensors",
        "state": {
            "buttonevent": 34,
            "lastupdated": "2021-07-12T15:04:10.063"
        },
        "t": "event",
        "uniqueid": "00:00:00:00:00:51:8f:ce-f2"
    }
}

2 short presses:

17:02:22:618 ZGP srcId: 0x00518FCE cmd: 0x20 frameCounter: 682
17:02:22:618 Incoming ZGP Frame: gpdsrcid 5345230, command 0x20, Payload 5fc5e7ac
17:02:22:618 ZGP button 32 ZGPSWITCH
17:02:22:618 enqueue event state/buttonevent for /sensors/2
17:02:22:619 enqueue event state/lastupdated for /sensors/2
17:02:22:621 Websocket 10.0.2.15:52362 send message: {"e":"changed","id":"2","r":"sensors","state":{"buttonevent":32,"lastupdated":"2021-07-12T15:02:22.618"},"t":"event","uniqueid":"00:00:00:00:00:51:8f:ce-f2"} (ret = 157)
17:02:22:623 discard sensor state push for 2: state/lastupdated (already pushed)

API event:

{
    "17:05:37:878": {
        "e": "changed",
        "id": "2",
        "r": "sensors",
        "state": {
            "buttonevent": 32,
            "lastupdated": "2021-07-12T15:05:37.869"
        },
        "t": "event",
        "uniqueid": "00:00:00:00:00:51:8f:ce-f2"
    }
}

2 buttons switch:

Join procedure for first button:

17:14:49:623 ZGP srcId: 0x0052051A cmd: 0xE0 frameCounter: 0
17:14:49:624 Incoming ZGP Frame: gpdsrcid 5375258, command 0xE0, Payload 02c5f29ddf38cc0baaa63c6d8c31176a7d50892a7f84e37c00000004022220
17:14:49:624 OpenSSl version 0x1010106F loaded
17:14:49:624 Device commissioning : options.byte 0xC5, extOptions.byte 0xF2
17:14:49:624 sql exec SELECT sid FROM sensors WHERE deletedState = 'deleted'
17:14:49:624 SensorNode 3: Hue Tap 3 added
17:14:49:624 enqueue event event/added for /sensors/3
17:14:49:624 ZGP button 224 ZGPSWITCH
17:14:49:624 enqueue event state/buttonevent for /sensors/3
17:14:49:624 enqueue event state/lastupdated for /sensors/3
17:14:49:628 Websocket 10.0.2.15:53956 send message: {"e":"added","id":"3","r":"sensors","sensor":{"config":{"on":true},"ep":242,"etag":"72e4a74926590755a6bae299acc49bb5","id":"3","lastseen":"2021-07-12T15:14Z","manufacturername":"Legrand","modelid":"ZGPSWITCH","name":"Hue Tap 3","state":{"buttonevent":224,"lastupdated":"2021-07-12T15:14:49.624"},"type":"ZGPSwitch","uniqueid":"00:00:00:00:00:52:05:1a-f2"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1a-f2"} (ret = 408)
17:14:49:630 Websocket 10.0.2.15:53956 send message: {"e":"changed","id":"3","r":"sensors","state":{"buttonevent":224,"lastupdated":"2021-07-12T15:14:49.624"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1a-f2"} (ret = 158)
17:14:49:632 discard sensor state push for 3: state/lastupdated (already pushed)

API information:

{
    "config": {
        "on": true
    },
    "ep": 242,
    "etag": "72e4a74926590755a6bae299acc49bb5",
    "lastseen": "2021-07-12T15:14Z",
    "manufacturername": "Legrand",
    "modelid": "ZGPSWITCH",
    "name": "Hue Tap 3",
    "state": {
        "buttonevent": 224,
        "lastupdated": "2021-07-12T15:14:49.624"
    },
    "type": "ZGPSwitch",
    "uniqueid": "00:00:00:00:00:52:05:1a-f2"
}

1 short press:

17:19:48:072 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 127
17:19:48:073 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload 1bfd2422
17:19:48:073 ZGP button 34 ZGPSWITCH
17:19:48:073 enqueue event state/buttonevent for /sensors/3
17:19:48:073 enqueue event state/lastupdated for /sensors/3
17:19:48:075 Websocket 10.0.2.15:55372 send message: {"e":"changed","id":"3","r":"sensors","state":{"buttonevent":34,"lastupdated":"2021-07-12T15:19:48.073"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1a-f2"} (ret = 157)
17:19:48:078 discard sensor state push for 3: state/lastupdated (already pushed)

API event:

{
    "17:19:48:79": {
        "e": "changed",
        "id": "3",
        "r": "sensors",
        "state": {
            "buttonevent": 34,
            "lastupdated": "2021-07-12T15:19:48.073"
        },
        "t": "event",
        "uniqueid": "00:00:00:00:00:52:05:1a-f2"
    }
}

2 short presses:

17:20:46:885 ZGP srcId: 0x0052051A cmd: 0x20 frameCounter: 130
17:20:46:886 Incoming ZGP Frame: gpdsrcid 5375258, command 0x20, Payload 4a5fad42
17:20:46:886 ZGP button 32 ZGPSWITCH
17:20:46:886 enqueue event state/buttonevent for /sensors/3
17:20:46:886 enqueue event state/lastupdated for /sensors/3
17:20:46:888 Websocket 10.0.2.15:55372 send message: {"e":"changed","id":"3","r":"sensors","state":{"buttonevent":32,"lastupdated":"2021-07-12T15:20:46.886"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1a-f2"} (ret = 157)
17:20:46:890 discard sensor state push for 3: state/lastupdated (already pushed)

API event:

{
    "17:20:46:891": {
        "e": "changed",
        "id": "3",
        "r": "sensors",
        "state": {
            "buttonevent": 32,
            "lastupdated": "2021-07-12T15:20:46.886"
        },
        "t": "event",
        "uniqueid": "00:00:00:00:00:52:05:1a-f2"
    }
}

Join procedure for second button:

17:22:53:463 ZGP srcId: 0x0052051B cmd: 0xE0 frameCounter: 0
17:22:53:464 Incoming ZGP Frame: gpdsrcid 5375259, command 0xE0, Payload 02c5f2361cf5a1f812cebb4744edfec5d591f07fe3e2936700000004022220
17:22:53:464 OpenSSl version 0x1010106F loaded
17:22:53:464 Device commissioning : options.byte 0xC5, extOptions.byte 0xF2
17:22:53:464 sql exec SELECT sid FROM sensors WHERE deletedState = 'deleted'
17:22:53:464 SensorNode 4: Hue Tap 4 added
17:22:53:464 enqueue event event/added for /sensors/4
17:22:53:464 ZGP button 224 ZGPSWITCH
17:22:53:464 enqueue event state/buttonevent for /sensors/4
17:22:53:464 enqueue event state/lastupdated for /sensors/4
17:22:53:467 Websocket 10.0.2.15:55396 send message: {"e":"added","id":"4","r":"sensors","sensor":{"config":{"on":true},"ep":242,"etag":"4a1be5089a93990eb183cecac8dc1e65","id":"4","lastseen":"2021-07-12T15:22Z","manufacturername":"Legrand","modelid":"ZGPSWITCH","name":"Hue Tap 4","state":{"buttonevent":224,"lastupdated":"2021-07-12T15:22:53.464"},"type":"ZGPSwitch","uniqueid":"00:00:00:00:00:52:05:1b-f2"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1b-f2"} (ret = 408)
17:22:53:470 Websocket 10.0.2.15:55396 send message: {"e":"changed","id":"4","r":"sensors","state":{"buttonevent":224,"lastupdated":"2021-07-12T15:22:53.464"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1b-f2"} (ret = 158)
17:22:53:473 discard sensor state push for 4: state/lastupdated (already pushed)

API information:

{
    "config": {
        "on": true
    },
    "ep": 242,
    "etag": "4a1be5089a93990eb183cecac8dc1e65",
    "lastseen": "2021-07-12T15:22Z",
    "manufacturername": "Legrand",
    "modelid": "ZGPSWITCH",
    "name": "Hue Tap 4",
    "state": {
        "buttonevent": 224,
        "lastupdated": "2021-07-12T15:22:53.464"
    },
    "type": "ZGPSwitch",
    "uniqueid": "00:00:00:00:00:52:05:1b-f2"
}

1 short press:

17:24:01:862 ZGP srcId: 0x0052051B cmd: 0x22 frameCounter: 106
17:24:01:862 Incoming ZGP Frame: gpdsrcid 5375259, command 0x22, Payload d92e8629
17:24:01:862 ZGP button 34 ZGPSWITCH
17:24:01:862 enqueue event state/buttonevent for /sensors/4
17:24:01:862 enqueue event state/lastupdated for /sensors/4
17:24:01:864 Websocket 10.0.2.15:55732 send message: {"e":"changed","id":"4","r":"sensors","state":{"buttonevent":34,"lastupdated":"2021-07-12T15:24:01.862"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1b-f2"} (ret = 157)
17:24:01:866 discard sensor state push for 4: state/lastupdated (already pushed)

API event:

{
    "17:24:01:869": {
        "e": "changed",
        "id": "4",
        "r": "sensors",
        "state": {
            "buttonevent": 34,
            "lastupdated": "2021-07-12T15:24:01.862"
        },
        "t": "event",
        "uniqueid": "00:00:00:00:00:52:05:1b-f2"
    }
}

2 short presses:

17:25:06:356 ZGP srcId: 0x0052051B cmd: 0x20 frameCounter: 109
17:25:06:357 Incoming ZGP Frame: gpdsrcid 5375259, command 0x20, Payload ae5ecac1
17:25:06:358 ZGP button 32 ZGPSWITCH
17:25:06:358 enqueue event state/buttonevent for /sensors/4
17:25:06:359 enqueue event state/lastupdated for /sensors/4
17:25:06:361 Websocket 10.0.2.15:55732 send message: {"e":"changed","id":"4","r":"sensors","state":{"buttonevent":32,"lastupdated":"2021-07-12T15:25:06.358"},"t":"event","uniqueid":"00:00:00:00:00:52:05:1b-f2"} (ret = 157)
17:25:06:371 discard sensor state push for 4: state/lastupdated (already pushed)

API event:

{
    "17:25:06:373": {
        "e": "changed",
        "id": "4",
        "r": "sensors",
        "state": {
            "buttonevent": 32,
            "lastupdated": "2021-07-12T15:25:06.358"
        },
        "t": "event",
        "uniqueid": "00:00:00:00:00:52:05:1b-f2"
    }
}

I’m a bit sad that the device doesn’t handle long press, but at least, we’re going somewhere :slight_smile:

Yes, I m trying to find information to decode payload, but unfortunately, there is few combinaisons possibles

First button 1 short push-up: ZGP srcId: 0x0052051A cmd: 0x22
First button 1 short push-down: ZGP srcId: 0x0052051A cmd: 0x22
First button 1 long push-up: ZGP srcId: 0x0052051A cmd: 0x22
First button 1 long push-down: ZGP srcId: 0x0052051A cmd: 0x22
First button 2 short push-up: ZGP srcId: 0x0052051A cmd: 0x20
First button 2 short push-down: ZGP srcId: 0x0052051A cmd: 0x20
Second button 1 short push-up: ZGP srcId: 0x0052051B cmd: 0x22
Second button 1 short push-down: ZGP srcId: 0x0052051B cmd: 0x22
Second button 1 long push-up: ZGP srcId: 0x0052051B cmd: 0x22
Second button 1 long push-down: ZGP srcId: 0x0052051B cmd: 0x22
Second button 2 short push-up: ZGP srcId: 0x0052051B cmd: 0x20
Second button 2 short push-down: ZGP srcId: 0x0052051B cmd: 0x20

The only difference is the “A” and the “B”, but as you have 2 devices created (one by button), no need to differentiate them.
It seem Legrand use the toogle feature for the simple press, and the “off” for the double press, like for classic switches. And I think this technologie can’t handle the long press (kinetic hardware)

And here

09:55:39:620 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 102
09:55:39:620 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload bd40fa64
09:55:40:493 ZGP srcId: 0x0052051B cmd: 0x22 frameCounter: 98
09:55:40:493 Incoming ZGP Frame: gpdsrcid 5375259, command 0x22, Payload adf03b65
09:55:42:608 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 104
09:55:42:608 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload cf9851c8
09:55:43:326 ZGP srcId: 0x0052051B cmd: 0x22 frameCounter: 100
09:55:43:326 Incoming ZGP Frame: gpdsrcid 5375259, command 0x22, Payload 053c8f23
09:55:46:543 ZGP srcId: 0x0052051A cmd: 0x22 frameCounter: 106
09:55:46:543 Incoming ZGP Frame: gpdsrcid 5375258, command 0x22, Payload 55b1321c

Sorry, but I don’t see logic at all, nothing usable for me …

But for the moment all seem working ? Perhaps need to change the defaut name

Hue Tap 3

That’s what makes me sad: the batteryless FoH switches can handle press & release events.

Yep, that was my point: the payload seems to be random on each press.

Yes, I get logs from the switches, thanks!

So, what are the remaining steps needed to have this usable in production (switches visible in Phoscon and Home Assistant/Domoticz/other automation systems)?

Because the two variations of the switch are handled the same way (and maybe even the 4 buttons variation 0 677 55L, I’ll confirm that soon), something generic like “Self-e switch” ?

Done.

So, what are the remaining steps needed to have this usable in production (switches visible in Phoscon and Home Assistant/Domoticz/other automation systems)?

Have just made the PR > Add support for Legrand ZGP kinetic switch (Self-e) by Smanar · Pull Request #5111 · dresden-elektronik/deconz-rest-plugin · GitHub

Need be validated (I haven’t delay, can take 1 days or 1 month, depend on first comment on it ^^)
After that, you will have it in next beta version or 1 month after in the official one.

You will have it in API, so you will be able to use it in third app. All ZGP switches have different value as buttonevent return, so you will have probably something to do.

For Phoscon, it s same, it s a third app too, so If you realy need it in phoscon (and BTW you have checked if phoscon don’t support it natively ?), you need to ask the support in phoscon issue too.

1 Like

Wow, so many thanks for your help!

Is there a specific reason why you left the DBG_Printf calls on the PR? A helper for future ZGP devices integration?

Yep, I’ll investigate on how to properly fill an issue.

image

Thanks again!

Exactly, thoses values are needed, better if there are displayed by defaut.

Hey @Smanar, ready for another round? :wink:

ZLGP15: 4 buttons (0 677 55L for the Céliane White)

Join procedure

ZGP srcId: 0x0051A412 cmd: 0xE0 frameCounter: 0
Incoming ZGP Frame: gpdsrcid 5350418, command 0xE0, Payload fec5f20aed654eac2b62be20be25648b591e5097033fbf640000000408141516171c1d1e1f
Device commissioning : options.byte 0xC5, extOptions.byte 0xF2
unsupported green power device 0xFE
ZGP srcId: 0x0051A412 cmd: 0x1C frameCounter: 101
Incoming ZGP Frame: gpdsrcid 5350418, command 0x1C, Payload 36efe01a

Simple press on button 1

ZGP srcId: 0x0051A412 cmd: 0x14 frameCounter: 104
Incoming ZGP Frame: gpdsrcid 5350418, command 0x14, Payload 7af6c786

Simple press on button 2

ZGP srcId: 0x0051A412 cmd: 0x15 frameCounter: 105
Incoming ZGP Frame: gpdsrcid 5350418, command 0x15, Payload 82a0667c

Simple press on button 3

ZGP srcId: 0x0051A412 cmd: 0x16 frameCounter: 106
Incoming ZGP Frame: gpdsrcid 5350418, command 0x16, Payload aaeca4ff

Simple press on button 4

ZGP srcId: 0x0051A412 cmd: 0x17 frameCounter: 107
Incoming ZGP Frame: gpdsrcid 5350418, command 0x17, Payload 24bfa3a9

No long press or double press on this one.

I have no idea for the name… LEGRANDZGPSWITCH4? LEGRANDZGPSWITCH15? LEGRANDZLGP15?

Hello, sure was not the harder device ^^
So I have used the same branch, as the previous was not yet validated.
But you will need to re-include your previous one, I have modified the name too.

  • LEGRANDZGPTOGGLESWITCH > for the toggle switch
  • LEGRANDZGPSCENESWITCH > for the scene switch

Was more logic to understand for me than ZGPXX.

BTW on your log you had

Incoming ZGP Frame: gpdsrcid 5350418, command 0x1C, Payload 36efe01a

It’s a scene command too, but I see it only during the inclusion …

1 Like

Thanks again! I updated the HA integration to reflect your changes.

Hello are you still here ?
I think you have see the Kane610 comment, we will probably need to make another change on code.

Nothing important, I think we will need to use “nomalised” value for return, like for standard switches.

@fredericseiler ok, so it s decided ^^.

I have modified the code again, always the same branch, you don’t need to re-include device, just update the code

Now instead of value 34 32 20 21 22 23, you will have value on format X00Y.
X : button number
Y : action short press release or double press.

1 Like

Got it, the HA plugin part is updated to reflect your changes.

1 Like