ilcato / homebridge-fibaro-home-center

Homebridge plugin for Fibaro Home Center
Apache License 2.0
27 stars 24 forks source link

Fibaro The Button Support #498

Closed xsaomii closed 5 days ago

xsaomii commented 1 week ago

Product (manufacturer, model)

FGPB-101

As what should be displayed?

stateless programmable switch

API response for this device

{"id":89,"name":"Kontroler Scen","roomID":225,"type":"com.fibaro.FGPB101","baseType":"com.fibaro.remoteSceneController","enabled":true,"visible":true,"isPlugin":false,"parentId":88,"remoteGatewayId":0,"interfaces":["battery","fibaroFirmwareUpdate","zwave","zwaveAlarm","zwaveCentralScene","zwaveMultiChannelAssociation","zwaveWakeup"],"properties":{"parameters":[{"id":1,"lastReportedValue":127,"lastSetValue":127,"size":1,"value":127},{"id":3,"lastReportedValue":7,"lastSetValue":7,"size":1,"value":7},{"id":10,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":11,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":12,"lastReportedValue":1,"lastSetValue":1,"size":1,"value":1},{"id":13,"lastReportedValue":99,"lastSetValue":99,"size":2,"value":99},{"id":14,"lastReportedValue":0,"lastSetValue":0,"size":1,"value":0},{"id":15,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":20,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":21,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":22,"lastReportedValue":1,"lastSetValue":1,"size":1,"value":1},{"id":23,"lastReportedValue":99,"lastSetValue":99,"size":2,"value":99},{"id":24,"lastReportedValue":0,"lastSetValue":0,"size":1,"value":0},{"id":25,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":29,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":30,"lastReportedValue":127,"lastSetValue":127,"size":1,"value":127}],"pollingTimeSec":0,"wakeUpTime":0,"zwaveCompany":"Fibargroup","zwaveInfo":"3,4,38","zwaveVersion":"3.2","alarmLevel":"0","alarmType":"0","batteryLevel":"100","batteryLowNotification":"true","categories":"[\"remotes\"]","centralSceneSupport":"[{\"keyAttributes\":[\"Pressed\",\"Released\",\"HeldDown\",\"Pressed2\",\"Pressed3\",\"Pressed4\",\"Pressed5\"],\"keyId\":1}]","configured":true,"dead":"false","deadReason":"","defInterval":"0","deviceControlType":"0","deviceIcon":"115","emailNotificationID":"0","emailNotificationType":"0","endPointId":"0","firmwareUpdate":"{\"info\":\"\",\"progress\":0,\"status\":\"UpToDate\",\"updateVersion\":\"3.2\"}","icon":"{\"path\":\"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101_white.png\",\"source\":\"HC\"}","log":"","logTemp":"","manufacturer":"","markAsDead":"true","maxInterval":"0","minInterval":"0","model":"","nodeId":"17","panicMode":"false","parametersTemplate":"772","productInfo":"1,15,15,1,16,0,3,2","pushNotificationID":"0","pushNotificationType":"0","remoteGatewayId":"0","saveLogs":"true","sequences":"[]","serialNumber":"h'000000000000d25c","smsNotificationID":"0","smsNotificationType":"0","stepInterval":"0","updateVersion":"","useTemplate":"true","userDescription":""},"actions":{"abortUpdate":1,"reconfigure":0,"retryUpdate":1,"setInterval":1,"startUpdate":1,"updateFirmware":1},"created":1728124698,"modified":1728124698,"sortOrder":33}

Additional info

No response

ilcato commented 1 week ago

@xsaomii, I don't have this kind of devices. What's the use case for integration in HomeKit?

mkz212 commented 1 week ago

@xsaomii @ilcato Isn't it better to create a scene in Fibaro? I think it's easier.

ilcato commented 1 week ago

@xsaomii @ilcato Isn't it better to create a scene in Fibaro? I think it's easier.

Exactly, this is what I do with a remote.

Additionally, in the actions data of the device I do not see any significant element to map to an HomeKit characteristic. May be we only need to listen to fired events.

ilcato commented 1 week ago

The only use case I can see is when I want control devices not directly visible to Fibaro Home Center but connected to the same HomeKit environment. @xsaomii is this your use case?

xsaomii commented 1 week ago

The only use case I can see is when I want control devices not directly visible to Fibaro Home Center but connected to the same HomeKit environment. @xsaomii is this your use case?

I'd like to use the Fibaro button to control HomeKit scenes that would include devices I've added to Homekit but not to Fibaro. For example I'd like to use this Fibaro switch to control a Xiaomi lamp that has official Homekit support but which I can't add to Fibaro. I've tried to do this using the 'variables acting like a bistable switch' function, but this doesn't always work, and when it does, it has a very long delay. So is there now any method to make it so that it works well?

mkz212 commented 1 week ago

The only use case I can see is when I want control devices not directly visible to Fibaro Home Center but connected to the same HomeKit environment. @xsaomii is this your use case?

I'd like to use the Fibaro button to control HomeKit scenes that would include devices I've added to Homekit but not to Fibaro. For example I'd like to use this Fibaro switch to control a Xiaomi lamp that has official Homekit support but which I can't add to Fibaro. I've tried to do this using the 'variables acting like a bistable switch' function, but this doesn't always work, and when it does, it has a very long delay. So is there now any method to make it so that it works well?

If you add scene from Fibaro it will be displayed as switch in HomeKit. Switch that will be on for a while when you activate scene and automaticaly turn off after while.

Then you can add automation in Home app - when switch is turned on -> change lamp state

ilcato commented 1 week ago

We are already managing ProgrammableSwitchEvent, I don't remember why :-) It should be very easy to add these devices directly.

ilcato commented 1 week ago

Now I remember. The problem is that remote controllers manage the button events in very different ways 1 button, multiple buttons, multiple actions... It's very complicated. For example I have a minimote with 4 buttons that manages 8 events (single press and hold press). it has an available scenes property with 8 values. The FGPB-101 doesn't hav an available scenes property but a centralSceneSupport property with 1 key and 7 values with only 2 that we can map to a programmable switch in HomeKit. How can we manage it? I think that it's better to follow the strategy suggested by @mkz212

ilcato commented 1 week ago

@xsaomii can you check via the refreshStates API what data the FGPB-101 generate?

xsaomii commented 1 week ago

@xsaomii can you check via the refreshStates API what data the FGPB-101 generate?

@ilcato I'm not sure is it what you asking for: [10/8/2024, 11:30:52 PM] [FibaroHC] Kontroler Scen [id: 89, type: com.fibaro.FGPB101]: device not supported, if you need something else please let me know how to check it and I will send it to you.

ilcato commented 1 week ago

@xsaomii can you check via the refreshStates API what data the FGPB-101 generate?

@ilcato I'm not sure is it what you asking for: [10/8/2024, 11:30:52 PM] [FibaroHC] Kontroler Scen [id: 89, type: com.fibaro.FGPB101]: device not supported, if you need something else please let me know how to check it and I will send it to you.

In the same place where you get the data relative to the device by calling the API devices, there another API called refreshStates that you can call in the same way

xsaomii commented 1 week ago

@xsaomii can you check via the refreshStates API what data the FGPB-101 generate?

@ilcato I'm not sure is it what you asking for: [10/8/2024, 11:30:52 PM] [FibaroHC] Kontroler Scen [id: 89, type: com.fibaro.FGPB101]: device not supported, if you need something else please let me know how to check it and I will send it to you.

In the same place where you get the data relative to the device by calling the API devices, there another API called refreshStates that you can call in the same way

Im sorry but I'm still not sure where to find it. Is it somewhere in Homebridge or in Home Center?

ilcato commented 1 week ago

@xsaomii how did you get this data: {"id":89,"name":"Kontroler Scen","roomID":225,"type":"com.fibaro.FGPB101","baseType":"com.fibaro.remoteSceneController","enabled":true,"visible":true,"isPlugin":false,"parentId":88,"remoteGatewayId":0,"interfaces":["battery","fibaroFirmwareUpdate","zwave","zwaveAlarm","zwaveCentralScene","zwaveMultiChannelAssociation","zwaveWakeup"],"properties":{"parameters":[{"id":1,"lastReportedValue":127,"lastSetValue":127,"size":1,"value":127},{"id":3,"lastReportedValue":7,"lastSetValue":7,"size":1,"value":7},{"id":10,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":11,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":12,"lastReportedValue":1,"lastSetValue":1,"size":1,"value":1},{"id":13,"lastReportedValue":99,"lastSetValue":99,"size":2,"value":99},{"id":14,"lastReportedValue":0,"lastSetValue":0,"size":1,"value":0},{"id":15,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":20,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":21,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":22,"lastReportedValue":1,"lastSetValue":1,"size":1,"value":1},{"id":23,"lastReportedValue":99,"lastSetValue":99,"size":2,"value":99},{"id":24,"lastReportedValue":0,"lastSetValue":0,"size":1,"value":0},{"id":25,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":29,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":30,"lastReportedValue":127,"lastSetValue":127,"size":1,"value":127}],"pollingTimeSec":0,"wakeUpTime":0,"zwaveCompany":"Fibargroup","zwaveInfo":"3,4,38","zwaveVersion":"3.2","alarmLevel":"0","alarmType":"0","batteryLevel":"100","batteryLowNotification":"true","categories":"[\"remotes\"]","centralSceneSupport":"[{\"keyAttributes\":[\"Pressed\",\"Released\",\"HeldDown\",\"Pressed2\",\"Pressed3\",\"Pressed4\",\"Pressed5\"],\"keyId\":1}]","configured":true,"dead":"false","deadReason":"","defInterval":"0","deviceControlType":"0","deviceIcon":"115","emailNotificationID":"0","emailNotificationType":"0","endPointId":"0","firmwareUpdate":"{\"info\":\"\",\"progress\":0,\"status\":\"UpToDate\",\"updateVersion\":\"3.2\"}","icon":"{\"path\":\"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101_white.png\",\"source\":\"HC\"}","log":"","logTemp":"","manufacturer":"","markAsDead":"true","maxInterval":"0","minInterval":"0","model":"","nodeId":"17","panicMode":"false","parametersTemplate":"772","productInfo":"1,15,15,1,16,0,3,2","pushNotificationID":"0","pushNotificationType":"0","remoteGatewayId":"0","saveLogs":"true","sequences":"[]","serialNumber":"h'000000000000d25c","smsNotificationID":"0","smsNotificationType":"0","stepInterval":"0","updateVersion":"","useTemplate":"true","userDescription":""},"actions":{"abortUpdate":1,"reconfigure":0,"retryUpdate":1,"setInterval":1,"startUpdate":1,"updateFirmware":1},"created":1728124698,"modified":1728124698,"sortOrder":33}

?

ilcato commented 1 week ago

I successfully implemented the remote controller support for my Aeotec Minimote. @xsaomii if you can provide the info for the Fibaro Button I can implement support for it.

xsaomii commented 1 week ago

@xsaomii how did you get this data: {"id":89,"name":"Kontroler Scen","roomID":225,"type":"com.fibaro.FGPB101","baseType":"com.fibaro.remoteSceneController","enabled":true,"visible":true,"isPlugin":false,"parentId":88,"remoteGatewayId":0,"interfaces":["battery","fibaroFirmwareUpdate","zwave","zwaveAlarm","zwaveCentralScene","zwaveMultiChannelAssociation","zwaveWakeup"],"properties":{"parameters":[{"id":1,"lastReportedValue":127,"lastSetValue":127,"size":1,"value":127},{"id":3,"lastReportedValue":7,"lastSetValue":7,"size":1,"value":7},{"id":10,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":11,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":12,"lastReportedValue":1,"lastSetValue":1,"size":1,"value":1},{"id":13,"lastReportedValue":99,"lastSetValue":99,"size":2,"value":99},{"id":14,"lastReportedValue":0,"lastSetValue":0,"size":1,"value":0},{"id":15,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":20,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":21,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":22,"lastReportedValue":1,"lastSetValue":1,"size":1,"value":1},{"id":23,"lastReportedValue":99,"lastSetValue":99,"size":2,"value":99},{"id":24,"lastReportedValue":0,"lastSetValue":0,"size":1,"value":0},{"id":25,"lastReportedValue":255,"lastSetValue":255,"size":2,"value":255},{"id":29,"lastReportedValue":3,"lastSetValue":3,"size":1,"value":3},{"id":30,"lastReportedValue":127,"lastSetValue":127,"size":1,"value":127}],"pollingTimeSec":0,"wakeUpTime":0,"zwaveCompany":"Fibargroup","zwaveInfo":"3,4,38","zwaveVersion":"3.2","alarmLevel":"0","alarmType":"0","batteryLevel":"100","batteryLowNotification":"true","categories":"[\"remotes\"]","centralSceneSupport":"[{\"keyAttributes\":[\"Pressed\",\"Released\",\"HeldDown\",\"Pressed2\",\"Pressed3\",\"Pressed4\",\"Pressed5\"],\"keyId\":1}]","configured":true,"dead":"false","deadReason":"","defInterval":"0","deviceControlType":"0","deviceIcon":"115","emailNotificationID":"0","emailNotificationType":"0","endPointId":"0","firmwareUpdate":"{\"info\":\"\",\"progress\":0,\"status\":\"UpToDate\",\"updateVersion\":\"3.2\"}","icon":"{\"path\":\"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101_white.png\",\"source\":\"HC\"}","log":"","logTemp":"","manufacturer":"","markAsDead":"true","maxInterval":"0","minInterval":"0","model":"","nodeId":"17","panicMode":"false","parametersTemplate":"772","productInfo":"1,15,15,1,16,0,3,2","pushNotificationID":"0","pushNotificationType":"0","remoteGatewayId":"0","saveLogs":"true","sequences":"[]","serialNumber":"h'000000000000d25c","smsNotificationID":"0","smsNotificationType":"0","stepInterval":"0","updateVersion":"","useTemplate":"true","userDescription":""},"actions":{"abortUpdate":1,"reconfigure":0,"retryUpdate":1,"setInterval":1,"startUpdate":1,"updateFirmware":1},"created":1728124698,"modified":1728124698,"sortOrder":33}

?

I get it by entering http:///api/devices/

ilcato commented 1 week ago

@xsaomii perfect. Now enter: http://YOUR_IP_ADDRESS/api/refreshStates?last=0&lang=en&rand=12345 Note in the response the value of the "last" field like in:

{
  "status": "IDLE",
  "last": 149841,
  "date": "20:30 | 12.10.2024",
  "timestamp": 1728757831,
  "timestampMillis": 1728757831210,
  ....

In this case it's 149841. Prepare BUT DO NOT EXECUTE the new URL in which you put the value noted in the previous step like: http://YOUR_IP_ADDRESS/api/refreshStates?last= 149841&lang=en&rand=12345

Now make some actions with your Fibaro Button.

EXECUTE the new URL.

Report the results.

Thanks

xsaomii commented 1 week ago

{"status":"IDLE","last":55402,"date":"21:05 | 12.10.2024","timestamp":1728759908,"logs":[],"events":[{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed_white.png","source":"HC"}}},{"type":"SceneRunningInstancesEvent","data":{"id":22,"type":"","runningInstances":1,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"value","oldValue":true,"newValue":false}},{"type":"SceneRunningInstancesEvent","data":{"id":43,"type":"","runningInstances":1,"runningManualInstances":0}},{"type":"SceneRunningInstancesEvent","data":{"id":22,"type":"","runningInstances":0,"runningManualInstances":0}},{"type":"SceneRunningInstancesEvent","data":{"id":43,"type":"","runningInstances":0,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"power","oldValue":18.6,"newValue":0.0}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed2","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed2_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed2_white.png","source":"HC"}}},{"type":"SceneRunningInstancesEvent","data":{"id":23,"type":"","runningInstances":1,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":85,"property":"value","oldValue":false,"newValue":true}},{"type":"SceneRunningInstancesEvent","data":{"id":23,"type":"","runningInstances":0,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":85,"property":"power","oldValue":0.0,"newValue":21.4}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed3","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed3_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed2_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed3_white.png","source":"HC"}}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed4","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed4_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed3_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed4_white.png","source":"HC"}}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed5","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed5_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed4_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed5_white.png","source":"HC"}}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"HeldDown","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1HeldDown_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed5_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1HeldDown_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"value","oldValue":false,"newValue":true}},{"type":"SceneRunningInstancesEvent","data":{"id":43,"type":"","runningInstances":2,"runningManualInstances":0}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Released","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Released_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1HeldDown_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Released_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"power","oldValue":0.0,"newValue":18.5}}],"changes":[{"id":84,"log":"","logTemp":""},{"id":85,"log":"","logTemp":"","power":"21.40","value":"true"},{"id":86,"log":"transfer OK","logTemp":"TxtGreen"},{"id":87,"log":"transfer OK","logTemp":"TxtGreen","power":"18.50","value":"true"},{"id":88,"log":"","logTemp":""},{"id":89,"icon":"{\"path\":\"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Released_white.png\",\"source\":\"HC\"}","log":"","logTemp":""}],"alarmChanges":[]}

I performed all 6 possible actions and these were the last actions immediately before the URL was launched. In the following order I pressed once, pressed twice, pressed three times, pressed four times, pressed five times and hold.

ilcato commented 1 week ago

{"status":"IDLE","last":55402,"date":"21:05 | 12.10.2024","timestamp":1728759908,"logs":[],"events":[{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed_white.png","source":"HC"}}},{"type":"SceneRunningInstancesEvent","data":{"id":22,"type":"","runningInstances":1,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"value","oldValue":true,"newValue":false}},{"type":"SceneRunningInstancesEvent","data":{"id":43,"type":"","runningInstances":1,"runningManualInstances":0}},{"type":"SceneRunningInstancesEvent","data":{"id":22,"type":"","runningInstances":0,"runningManualInstances":0}},{"type":"SceneRunningInstancesEvent","data":{"id":43,"type":"","runningInstances":0,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"power","oldValue":18.6,"newValue":0.0}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed2","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed2_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed2_white.png","source":"HC"}}},{"type":"SceneRunningInstancesEvent","data":{"id":23,"type":"","runningInstances":1,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":85,"property":"value","oldValue":false,"newValue":true}},{"type":"SceneRunningInstancesEvent","data":{"id":23,"type":"","runningInstances":0,"runningManualInstances":0}},{"type":"DevicePropertyUpdatedEvent","data":{"id":85,"property":"power","oldValue":0.0,"newValue":21.4}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed3","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed3_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed2_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed3_white.png","source":"HC"}}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed4","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed4_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed3_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed4_white.png","source":"HC"}}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Pressed5","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed5_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed4_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed5_white.png","source":"HC"}}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"HeldDown","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1HeldDown_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Pressed5_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1HeldDown_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"value","oldValue":false,"newValue":true}},{"type":"SceneRunningInstancesEvent","data":{"id":43,"type":"","runningInstances":2,"runningManualInstances":0}},{"type":"CentralSceneEvent","data":{"deviceId":89,"keyId":1,"keyAttribute":"Released","icon":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Released_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":89,"property":"icon","oldValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1HeldDown_white.png","source":"HC"},"newValue":{"path":"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Released_white.png","source":"HC"}}},{"type":"DevicePropertyUpdatedEvent","data":{"id":87,"property":"power","oldValue":0.0,"newValue":18.5}}],"changes":[{"id":84,"log":"","logTemp":""},{"id":85,"log":"","logTemp":"","power":"21.40","value":"true"},{"id":86,"log":"transfer OK","logTemp":"TxtGreen"},{"id":87,"log":"transfer OK","logTemp":"TxtGreen","power":"18.50","value":"true"},{"id":88,"log":"","logTemp":""},{"id":89,"icon":"{\"path\":\"fibaro/icons/com.fibaro.FGPB101_white/com.fibaro.FGPB101-1Released_white.png\",\"source\":\"HC\"}","log":"","logTemp":""}],"alarmChanges":[]}

I performed all 6 possible actions and these were the last actions immediately before the URL was launched. In the following order I pressed once, pressed twice, pressed three times, pressed four times, pressed five times and hold.

Perfect

ilcato commented 6 days ago

@xsaomii I made an implementation in 3.1.0-beta.4 I was not able to test it since I don't have this kind of device. Can you test it?

xsaomii commented 6 days ago

@xsaomii I made an implementation in 3.1.0-beta.4 I was not able to test it since I don't have this kind of device. Can you test it?

Sorry it took so long, but I've checked all the options both with the FGPB-101 and the FGWDS221 and everything works fine. The only thing I noticed is that there is an option to assign a scene only to single press, double press and hold, despite the fact that both devices support triple click and the FGPB-101 additionally supports four times and five times clicks, but I guess that may be due to the HomeKit limitations.

ilcato commented 6 days ago

@xsaomii thank you for your feedback. So are you using the Walli as a remote controller not to control locally attached load?

ilcato commented 6 days ago

but I guess that may be due to the HomeKit limitations.

Yes, this is the reason.

xsaomii commented 6 days ago

@xsaomii thank you for your feedback. So are you using the Walli as a remote controller not to control locally attached load?

Walli Switch is displayed in Home Center as up to three devices, of which one or two allow you to control one or two locally connected loads, and in addition it is also displayed as a scene controller similar to the The Button allowing you to control scenes by different types of clicks. I use it in such a way that by single clicks I control the locally connected loads and by double-clicking the Walli Switch that I have next to the door I turn off all the lights when leaving the room, and now I can also turn off the Xiaomi lamps added to Apple Home for which I am very thankful :D

ilcato commented 6 days ago

@xsaomii very clever. I will release this version in a few days. Report any malfunctioning please.

ilcato commented 5 days ago

@xsaomii version 3.1.0 is published. Please close the issue if all is good. Thanks.