Closed MouseRatt closed 2 years ago
Thanks for the request. Unfortunately, I can’t afford to buy any RA gear just for library development, and the operations are different enough that I don’t think I could add support myself without the real hardware in hand. I world love to see the library extended, though.
It’s worth noting, however, that this library doesn’t implement support for devices as such, only the messages that describe the devices. Support for a device would have to be at a higher level, either in my homebridge plug-in or elsewhere.
Totally understand - is this something I'd be able to help implement with a bit of testing using your typescript code? Or does figuring out the leap API commands require decompiling Android Lutron app (or some alternative)? Happy to help if I can in anyway
Decompiling APKs is one way to see what objects Lutron has implemented, for sure. Another way is to look at the pylutron and pylutron-caseta projects, which are alternative implementations to this one. I'm going to update the README to this project to expound a bit more on adding device support and what that means for this particular library, so watch that space.
I'm going to close this issue since I think there's nothing more to be done (within the scope of this library). Please reopen it if I've misunderstood.
Hi @thenewwazoo
Any plans to add support for the RA2 fan controller and Sunnata keypads? I have a couple keypads and some RA2 fan controllers coming in, if you are interested in adding support for them I could help get these added.
What would you need me to collect to determine the best way to add support for these devices? Do you need something like the log output below for the 4 button keypad? Or do you need the full log?
DEBUG:pylutron_caseta.leap:sending b'{"CommuniqueType": "ReadRequest", "Header": {"ClientTag": "0707247d-7814-4ef0-80bb-4997699866ba", "Url": "/device/1004/buttongroup/expanded"}}' DEBUG:pylutron_caseta.leap:received: {'CommuniqueType': 'ReadResponse', 'Header': {'MessageBodyType': 'MultipleButtonGroupExpandedDefinition', 'StatusCode': '200 OK', 'Url': '/device/1004/buttongroup/expanded'}, 'Body': {'ButtonGroupsExpanded': [{'href': '/buttongroup/1013', 'Parent': {'href': '/device/1004'}, 'SortOrder': 0, 'ProgrammingType': 'Freeform', 'Buttons': [{'href': '/button/1014', 'ButtonNumber': 1, 'ProgrammingModel': {'href': '/programmingmodel/1015', 'ProgrammingModelType': 'AdvancedToggleProgrammingModel'}, 'Parent': {'href': '/buttongroup/1013'}, 'Name': 'Button 1', 'Engraving': {'Text': ''}, 'AssociatedLED': {'href': '/led/1009'}}, {'href': '/button/1018', 'ButtonNumber': 2, 'ProgrammingModel': {'href': '/programmingmodel/1019', 'ProgrammingModelType': 'AdvancedToggleProgrammingModel'}, 'Parent': {'href': '/buttongroup/1013'}, 'Name': 'Button 2', 'Engraving': {'Text': ''}, 'AssociatedLED': {'href': '/led/1010'}}, {'href': '/button/1022', 'ButtonNumber': 3, 'ProgrammingModel': {'href': '/programmingmodel/1023', 'ProgrammingModelType': 'AdvancedToggleProgrammingModel'}, 'Parent': {'href': '/buttongroup/1013'}, 'Name': 'Button 3', 'Engraving': {'Text': ''}, 'AssociatedLED': {'href': '/led/1011'}}, {'href': '/button/1026', 'ButtonNumber': 4, 'ProgrammingModel': {'href': '/programmingmodel/1027', 'ProgrammingModelType': 'AdvancedToggleProgrammingModel'}, 'Parent': {'href': '/buttongroup/1013'}, 'Name': 'Button 4', 'Engraving': {'Text': ''}, 'AssociatedLED': {'href': '/led/1012'}}]}]}} DEBUG:pylutron_caseta.leap:sending b'{"CommuniqueType": "ReadRequest", "Header": {"ClientTag": "71ca268a-0d0a-4d67-b483-40963292167a", "Url": "/device/1004"}}' DEBUG:pylutron_caseta.leap:received: {'CommuniqueType': 'ReadResponse', 'Header': {'MessageBodyType': 'OneDeviceDefinition', 'StatusCode': '200 OK', 'Url': '/device/1004'}, 'Body': {'Device': {'href': '/device/1004', 'Name': 'Device 3', 'Parent': {'href': '/project'}, 'SerialNumber': 76775880, 'ModelNumber': 'RRST-W4B-XX', 'DeviceType': 'SunnataKeypad', 'AssociatedArea': {'href': '/area/520'}, 'LinkNodes': [{'href': '/device/1004/linknode/1006'}], 'FirmwareImage': {'href': '/firmwareimage/1004'}, 'DeviceClass': {'HexadecimalEncoding': '1270101'}, 'AddressedState': 'Addressed'}}} DEBUG:pylutron_caseta.leap:sending b'{"CommuniqueType": "ReadRequest", "Header": {"ClientTag": "a13c4c52-fbd9-48c1-84ca-63dc9ed9bd52", "Url": "/area/520/associatedzone"}}'