Closed superkule closed 3 years ago
I don’t see this issue. The door opens fine for me running the latest homebridge. The no response error is likely a networking issue of some kind. I do sometimes get a no response error but then a few seconds later the door will open and close. The errors are not with my code but something network related and perhaps from the ryobi api. One difference between the ryobi app and this code is that you are already logged in to ryobi backend when issue a command with their app, whereas this code has to login and issue the command sometimes at the sametime and this can take longer and it maybe that the login’s are taking longer than before but I don’t see any errors that you sent relating to an actual failure.
As far as the warnings shown above, looking at the code I never set targetdoorstate, I only set currentdoorstate and those are legal values for opening and closing (which is what it is complaining about) so I have to assume the those warnings are either in error or a bug in the version of homebridge you are running. The target door state is passed to me and when it changes (not by me) it triggers my code. My guess is that these errors are caused by perhaps old bugs caught by homebridges recent changes from JavaScript to typescript.
The one thing you could do is to turn on debug output in homebridge and also on this plugin (see the read me for more debugging info from this NPM) and look at the output when it fails.
Sorry, I didn’t see the second error you sent (from latter in the day.) That is a problem with the response from ryobi. The code failed gracefully (and logged the error) but my guess is that ryobi website was temporarily down or you had a networking glitch. It was just “polling” ryobi the door to see if the state changes. Errors like this in the log are not uncommon.
Looking more at the first log, everything worked fine (ignoring the warnings.) The code polls ryobi and confirmed that the door opened and closed. Those states being logged are directly from the ryobi backend server. This would not have happened if a failure occurred as that state is coming from ryobi.
As noted, I think the warning is a bug in the homebridge code itself that should not impact operation.
From the log you sent I can tell that those log entries we initiated by the doors opening and closing via the ryobi's app, or directly from your garage door opener or remote. It it were initiated from homekit you'd see the logs say either:
Set Garage Door to 0
- Open or
Set Garage Door to 1
- Closed
It is possible "perhaps" to see the characters set wrong in the lower level homebridge code at startup based on timing issues as I noticed if said "CLOSED, CLOSING, CLOSED" which should not happen when I'm getting state from ryobi. I should never see CLOSED and then CLOSING without an open state but it is possible based on the polling interval and I think that is what triggered the first errors.
I've also seen the warning when for some reason the current state could not get initialized (say also because of a networking issue.)
One thing to look at, when it is failing, is if you look at the homekit app do you see the current state of all your homekit accessories? If the state is unknown (which can happen) you will see issues if you used siri to change a state when homekit does not know the current state.
The errors about commands taking too long are legit (and the warnings new from homebridge.) This should be fixed but I'm looking for someone to take the project for further development. This should not impact the errors you are seeing however. The code changes should be minor to fix that warning but I'm not set up to adequately test it anymore.
Bug #13 will handle the timeout issues. Someone is reworking the code anyway and will work on that. It will make the plugin better behaved.
Thanks Knuckleheadsmiff for your indepth and detailed analysis it really helps me understand how your code integrates with Ryobi GDO! Love your work and hope to see more great things from you/your team. Appreciate your efforts on this plugin and have a great one!
Ignore I guess the log errors, is opening/closing via siri/HomeKit still not working?
Hi knuckleheadsmiff - thats correct its still not working via Siri/Homekit, and my other devices don't drop connections when I try to open/close via Ryobi GDO or try to initiate within homekit (only the Ryobi GDO gets the no response error)
here is the version of homebridge I am using:
Node JS version - v14.16.1 NPM version - v6.14.12 Homebridge - v1.3.4
What I need to see is more debug info in the log ideally around the time why you use the Apple Home app to open/close the door. The readme has info for turning on debugging info in the app, and you should also run homebridge debug flag as well. The log above does not have relevant info in it. also do you have issues with any other homebridge devices? Finally do you have one or more garage doors configured?
Homebridge debug mode is described here: https://github.com/homebridge/homebridge/wiki/Basic-Troubleshooting
....also the readme in this NPM has a debug option where I log a lot more info.
I suspect your problem is with something else.
You should update.
andyedinborough just submitted a major rewrite that fixes tons of stuff and makes this NPM well behaved. You can also ignore the debug setting from this NPMs readme. Any got rid of that, but the himebridge debug output still applies:
Homebridge debug mode is described here: https://github.com/homebridge/homebridge/wiki/Basic-Troubleshooting
Let me know if things are fixed.
I tried opening within homekit but alas no luck as well after updating the plugin to the newer version: Lots from debug mode of the plugin
[4/23/2021, 4:40:31 PM] [ryobi-gdo] Polling state of Garage Door [4/23/2021, 4:40:31 PM] [ryobi-gdo] Updating ryobi data [4/23/2021, 4:40:31 PM] [ryobi-gdo] getApiKey [4/23/2021, 4:40:31 PM] [ryobi-gdo] GET https://tti.tiwiconnect.com/api/login [4/23/2021, 4:40:31 PM] [ryobi-gdo] {"result":{"id":"57b5c8dca4d5ef055e4cabbf","varName":"beamatomy@gmail.com","metaData":{"companyName":"","surName":"","givenName":"","autoLogout":false,"authCount":379,"sys":{"lastSeen":1619209710538,"ip":"Capture Off"},"name":"Wilfred Yung","wskAuthAttempts":[{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-20 13:21:26","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-20 13:21:41","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-22 12:46:54","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-22 12:59:28","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-23 20:28:30","success":true}]},"accountOptions":{"email":"beamatomy@gmail.com","alertPhone":"","alertEmail":"beamatomy@gmail.com","receiveEmailUpdates":false,"receiveEmailAlerts":false,"receiveSmsAlerts":false,"productResearchInvitations":true,"receiveProductInfo":true,"homeDepotPromotions":true},"enabled":true,"deleted":false,"createdDate":"2016-08-18T14:40:28.073Z","activated":0,"notificationTransports":[],"auth":{"apiKey":"fd80ee9a","regPin":"e518","clientUserName":"superkule@icloud.com","createdDate":"2016-08-18T14:40:28.077Z","childSelectors":["5e6d2ead829ec8412f3932ba"],"roleMap":{"roleSelectors":[],"roleRegex":["^GET\/api\/(auths?|sessions?|ping|notifications?|user-name)\/?$","^PUT\/api\/(users?|auth-selectors?|user-name)\/?$","^GET\/api\/(notifications?|triggers?|subscriptions?|endnodes?|clients?|devices?|users?|attributes?)(\W?\w+)$","^GET\/api\/users?\/(config|session)\/?$","^(GET|PUT)\/api\/dashboards?(\W?\w+)$","^POST\/api\/(endnodes?|actions?|devices?)\/?$","^DELETE\/api\/(devices?|endnodes?|auth-selectors?)\/?\w+\/?$","^(GET|PUT|POST)\/api\/users?\/config\/?$","^GET\/api\/log","^PUT\/api\/(endnodes?|devices?)\/\w+\/?$","^POST\/api\/uploads?\/image\/?$","^(GET|POST)\/api\/(triggers?|subscriptions?)\/?$","^(PUT|DELETE|GET)\/api\/(triggers?|subscriptions?)","^(PUT|DELETE)\/api\/(notifications?)\/\w+\/?$","^(GET)\/api\/triggers\/.+\/(subscribe|unsubscribe)\/[a-zA-Z]+\/?$","^(GET|PUT|POST)\/api\/groups","^PUT\/api\/(auths?|users?)\/password\/?$","^GET\/api\/websockets?\/ticket\/?$","^PUT\/api\/rpc\/?$","RPC\/.*","^(GET|PUT|POST|DELETE)\/api\/tti","^(GET|PUT|POST|DELETE)\/api\/notif-delivery","^(GET)\/api\/notif-services?","^PUT\/api\/attributes?\/\w+\/garageDoor[0-9]{1,2}\/presetPosition\/?$","^GET\/api\/auths?\/session-token\/?$","^(GET|DELETE)\/api\/activity-logs(\/.+){1,2}"],"roleNames":["site_user"]},"roleIds":["5526b99fb9cf33db6189438a"],"clientSchema":"UserAccountModel"}}} [4/23/2021, 4:40:31 PM] [ryobi-gdo] GET https://tti.tiwiconnect.com/api/devices/c4be8497df0d [4/23/2021, 4:40:32 PM] [homebridge-nest-cam] Checking for alerts on Front Door [4/23/2021, 4:40:32 PM] [ryobi-gdo] {"result":[{"_id":"5e6d2ead829ec8412f3932ba","varName":"c4be8497df0d","metaData":{"name":"Garage Door","version":1,"icon":"/img/devices/gdo.png","description":"RYOBI Connected Garage Door Opener Master Unit","wskAuthAttempts":[{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-04-23 06:36:26","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-04-23 10:20:11","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-04-23 11:51:14","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-04-23 14:45:04","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-04-23 20:22:43","success":true}],"authCount":1155,"sys":{"lastSeen":1619210308194},"socketId":"ad1026d1.ip-10-0-0-215.ec2.internal.8080_c4be8497df0d"},"enabled":true,"deleted":false,"createdDate":"2020-03-14T19:21:17.230Z","activated":2,"deviceTypeIds":["gdoMasterUnit"],"deviceTypeMap":{"modulePort_9":{"metaData":{"name":"Module Port 9"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":["wifiModule_9"],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":7,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1584213700326},"portStatus":{"value":true,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1584213700326},"portId":{"value":9,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_8":{"metaData":{"name":"Module Port 8"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":["backupCharger_8"],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":6,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1584213698496},"portStatus":{"value":true,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1584213698496},"portId":{"value":8,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_7":{"metaData":{"name":"Module Port 7"},"ac":{},"at":{"triggerTemplateVarNames":{"value":["GDO.DoorOpens.varName","GDO.DoorCloses.varName","GDO.DoorOpenLongerThan.varName","GDO.DoorOpenAfter.varName","GDO.MotionSensor.__varName"],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":["garageDoor_7","garageLight_7"],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":5,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1584213698895},"portStatus":{"value":true,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1584213698895},"portId":{"value":7,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_6":{"metaData":{"name":"Module Port 6"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":6,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_5":{"metaData":{"name":"Module Port 5"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":5,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_4":{"metaData":{"name":"Module Port 4"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":4,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_3":{"metaData":{"name":"Module Port 3"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":3,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_2":{"metaData":{"name":"Module Port 2"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":2,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_1":{"metaData":{"name":"Module Port 1"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":1,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_0":{"metaData":{"name":"Module Port 0"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[],"lastValue":[],"lastSet":1618773668978},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[],"lastValue":[],"lastSet":1618773668978},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1618773668351},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1618773668351},"portId":{"value":0,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"masterUnit":{"metaData":{"icon":"/img/profiles/gdo.png","description":"GDO Master Unit","name":"Master Unit"},"ac":{},"at":{"nwpVersion":{"value":"1.0.0.10-2.4.0.2.31.1.3.0.1.1.0.3.34","flags":["C"],"_id":"56f0572e474a81821adbf7b1","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"TI WiFi Network Processor Version","name":"NWP Version"},"units":"","dataType":"string","varType":"tc_string","varName":"nwpVersion","lastValue":"1.0.0.10-2.4.0.2.31.1.3.0.1.1.0.3.34","lastSet":1584213697030},"appVersion":{"value":"1.0.7","flags":["C"],"_id":"56f0572e474a81821adbf7b2","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"The TTI wifi Firmware Version","name":"WiFi FW Version"},"units":"","dataType":"string","varType":"tc_string","varName":"appVersion","lastValue":"1.0.7","lastSet":1584990178680},"macAddress":{"value":"c4be8497df0d","flags":["C"],"_id":"56f0572e474a81821adbf7b3","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"the description","name":"MAC Address"},"units":"","dataType":"string","varType":"tc_string","varName":"macAddress","lastValue":"c4be8497df0d","lastSet":1584213677315},"serialNumber":{"value":"00000000000001","flags":["C"],"_id":"56f0572e474a81821adbf7b4","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"","name":"Serial Number"},"units":"","dataType":"string","varType":"tc_string","varName":"serialNumber","lastValue":"00000000000001","lastSet":1584213677315},"portCount":{"value":10,"flags":["C"],"_id":"56f0572e474a81821adbf7b5","min":0,"max":255,"dataType":"number","varType":"tc_uint8","varName":"portCount","metaData":{"name":"Port Count"},"defv":7,"lastValue":10,"lastSet":1584213677315},"timeZoneOffset":{"value":-4,"flags":["SRV","C","SET"],"_id":"56f0572e474a81821adbf7b6","units":"hours","metaData":{"name":"Time Zone Offset"},"dataType":"number","varType":"tc_float","varName":"timeZoneOffset","max":14,"min":-12,"defv":0},"lastSeen":{"value":1619209363340,"flags":[],"_id":"56f0572e474a81821adbf7b7","varName":"lastSeen","varType":"tc_utcdate","dataType":"number","units":"","metaData":{"icon":"icon.png","description":"the description","name":"Last Seen"},"max":9223372036854776000,"min":0,"defv":0,"lastValue":1615395676437},"modulesInstalled":{"value":3,"flags":["C"],"_id":"56f0572e474a81821adbf7b8","defv":0,"min":0,"max":255,"metaData":{"icon":"icon.png","description":"the number of ports that are currently occupied","name":"Modules Installed"},"units":"","dataType":"number","varType":"tc_uint8","varName":"modulesInstalled","lastValue":3,"lastSet":1584213700339}}},"backupCharger_8":{"metaData":{"name":"Backup Charger","description":"GDO Main Unit","icon":"/img/profiles/gdo.png"},"ac":{},"at":{"chargeLevel":{"value":255,"flags":["C"],"defv":0,"min":-1,"max":100,"enum":["no battery",0,25,50,75,100],"metaData":{"messageType":"0x11","name":"Charge Level","description":"Level of battery charge","icon":"icon.png"},"units":"%","dataType":"number","varType":"tc_int8","varName":"chargeLevel","lastValue":255,"lastSet":1584255679464}}},"garageLight_7":{"metaData":{"name":"GDO Light"},"ac":{},"at":{"lightTimer":{"flags":["C","SET"],"min":0,"max":255,"metaData":{"name":"Light Timer","description":"Overhead Light Timer","icon":"icon.png"},"units":"","dataType":"number","varType":"tc_uint8","varName":"lightTimer","lastValue":3,"value":3,"lastSet":1584213700876},"lightState":{"value":true,"flags":["C","SET"],"defv":false,"min":false,"max":true,"metaData":{"name":"Light","description":"Overhead Light","icon":"icon.png"},"units":"off,on","dataType":"boolean","varType":"tc_bool","varName":"lightState","lastValue":false,"lastSet":1619210352506}}},"garageDoor_7":{"metaData":{"name":"GDO Door 200","icon":"/img/profiles/gdo.png"},"ac":{},"at":{"presetPosition":{"value":0,"flags":["C","SET"],"min":0,"max":72,"units":"inches","defv":0,"dataType":"number","varType":"tc_uint8","metaData":{"name":"Preset Position"},"varName":"presetPosition","lastValue":0},"maxDoorPosition":{"value":90,"flags":["C"],"min":0,"max":180,"metaData":{"name":"Uppermost Garage Door Position"},"defv":0,"dataType":"number","varType":"tc_uint8","varName":"maxDoorPosition","lastValue":90,"lastSet":1584213700876},"doorPosition":{"value":0,"flags":["C"],"min":0,"max":180,"metaData":{"name":"Garage Door Position"},"defv":0,"dataType":"number","varType":"tc_uint8","varName":"doorPosition","lastValue":0,"lastSet":1619195977522},"doorPercentOpen":{"value":-1,"flags":["C"],"min":-1,"max":100,"metaData":{"name":"Garage Door Percent Open"},"defv":-1,"dataType":"number","varType":"tc_uint8","varName":"doorPercentOpen"},"doorState":{"value":0,"flags":["C","SET"],"min":0,"max":4,"enum":["Closed","Open","Closing","Opening","Fault"],"defv":0,"metaData":{"name":"Garage Door State"},"units":"","dataType":"number","varType":"tc_uint8","varName":"doorState","lastValue":0,"lastSet":1619195977522},"opMode":{"value":0,"flags":["C"],"min":0,"max":5,"enum":["Standard","Pre-Lockout","Lockout"],"metaData":{"name":"Garage Door Operation Mode"},"units":"","dataType":"number","defv":0,"varType":"tc_uint8","varName":"opMode","lastValue":0,"lastSet":1592173046867},"sensorFlag":{"value":false,"flags":["C","SERV"],"metaData":{"name":"Safety Sensor Triggered"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"sensorFlag","lastValue":false,"lastSet":1619195955457},"vacationMode":{"value":false,"flags":["C","SERV"],"enum":["Disabled","Enabled"],"metaData":{"name":"Garage Door Vacation Mode"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"vacationMode","lastValue":false},"motorStatus":{"value":1,"flags":["C","SERV"],"metaData":{"name":"Garage Door Motor Status"},"units":"","dataType":"number","defv":0,"varType":"tc_uint8","varName":"motorStatus","lastValue":1,"lastSet":1584213702308},"alarmState":{"value":false,"flags":["C","SERV"],"metaData":{"name":"Garage Door Alarm State"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"alarmState","lastValue":false,"lastSet":1619195969941},"motionSensor":{"value":false,"flags":["C","SERV"],"metaData":{"name":"Garage Door Motion Sensor"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"motionSensor","lastValue":true,"lastSet":1619210399625},"heightUnits":{"value":false,"flags":["C"],"metaData":{"name":"Units Display"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"heightUnits"}}},"wifiModule_9":{"metaData":{"name":"Wifi Module Status"},"ac":{},"at":{"serialNum":{"value":0,"flags":{"C":true},"defv":0,"metaData":{"name":"Serial Number"},"dataType":"number","varType":"tc_int8","varName":"serialNum"},"portInfoReq":{"value":0,"flags":{"C":true},"defv":0,"metaData":{"name":"Port Info Req"},"dataType":"number","varType":"tc_int8","varName":"portInfoReq"},"id":{"value":0,"flags":{"C":true},"defv":0,"metaData":{"name":"ID"},"dataType":"number","varType":"tc_int8","varName":"id"},"ssid":{"value":"?","flags":{"C":true},"defv":"?","metaData":{"name":"SSID Value"},"dataType":"string","varType":"tc_string","varName":"ssid"},"ipAddr":{"value":"0.0.0.0","flags":{"C":true},"defv":"0.0.0.0","metaData":{"name":"IP Address"},"dataType":"string","varType":"tc_string","varName":"ipAddr"},"rssi":{"value":-50,"flags":{"C":true},"defv":-50,"metaData":{"name":"RSSI Value"},"dataType":"number","varType":"tc_int8","varName":"rssi"},"macAddress":{"value":"","flags":{"C":true},"defv":"","metaData":{"name":"WiFi MAC Address"},"dataType":"string","varType":"tc_string","varName":"macAddress"}}}},"activatedDate":"2021-03-15T04:00:01.608Z"}]} [4/23/2021, 4:40:32 PM] [ryobi-gdo] Garage Door: CLOSED (1)
Nothing looks wrong here. It’s just getting the initial state and everything seems fine (actually better than before as some of t(e warning you were seeing are now gone.
What is clear is that the request from HomeKit to Homebridge is not making it to this plugin. When I see problems like this (and it’s been a very long time for me) they are sometimes with the HomeKit cache. Sometimes the only way to fix is to remove your “home” from the home app, and then recreate it. This can be a PITA if you have rules and rooms setup.
I removed my home from homekit and setup a new one to clear the cache, however homekit still doesn't work - it gets alerts whenever I open or close the GDO with the physical remote or Ryobi app, but it never is able to open or close within homekit, it just says no response after about 5 seconds and then stalls.
here are the logs:
[5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] Changing Garage Door to 0 [5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] GARAGEDOOR openDoor [5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] getApiKey [5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] GET https://tti.tiwiconnect.com/api/login [5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] {"result":{"id":"57b5c8dca4d5ef055e4cabbf","varName":"beamatomy@gmail.com","metaData":{"companyName":"","surName":"","givenName":"","autoLogout":false,"authCount":394,"sys":{"lastSeen":1619885125809,"ip":"Capture Off"},"name":"Wilfred Yung","wskAuthAttempts":[{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-29 23:41:24","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-30 11:49:11","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-01 15:32:28","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-01 15:58:37","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-01 16:05:25","success":true}]},"accountOptions":{"email":"beamatomy@gmail.com","alertPhone":"","alertEmail":"beamatomy@gmail.com","receiveEmailUpdates":false,"receiveEmailAlerts":false,"receiveSmsAlerts":false,"productResearchInvitations":true,"receiveProductInfo":true,"homeDepotPromotions":true},"enabled":true,"deleted":false,"createdDate":"2016-08-18T14:40:28.073Z","activated":0,"notificationTransports":[],"auth":{"apiKey":"fd80ee9a","regPin":"e518","clientUserName":"superkule@icloud.com","createdDate":"2016-08-18T14:40:28.077Z","childSelectors":["5e6d2ead829ec8412f3932ba"],"roleMap":{"roleSelectors":[],"roleRegex":["^GET\/api\/(auths?|sessions?|ping|notifications?|user-name)\/?$","^PUT\/api\/(users?|auth-selectors?|user-name)\/?$","^GET\/api\/(notifications?|triggers?|subscriptions?|endnodes?|clients?|devices?|users?|attributes?)(\W?\w+)$","^GET\/api\/users?\/(config|session)\/?$","^(GET|PUT)\/api\/dashboards?(\W?\w+)$","^POST\/api\/(endnodes?|actions?|devices?)\/?$","^DELETE\/api\/(devices?|endnodes?|auth-selectors?)\/?\w+\/?$","^(GET|PUT|POST)\/api\/users?\/config\/?$","^GET\/api\/log","^PUT\/api\/(endnodes?|devices?)\/\w+\/?$","^POST\/api\/uploads?\/image\/?$","^(GET|POST)\/api\/(triggers?|subscriptions?)\/?$","^(PUT|DELETE|GET)\/api\/(triggers?|subscriptions?)","^(PUT|DELETE)\/api\/(notifications?)\/\w+\/?$","^(GET)\/api\/triggers\/.+\/(subscribe|unsubscribe)\/[a-zA-Z]+\/?$","^(GET|PUT|POST)\/api\/groups","^PUT\/api\/(auths?|users?)\/password\/?$","^GET\/api\/websockets?\/ticket\/?$","^PUT\/api\/rpc\/?$","RPC\/.*","^(GET|PUT|POST|DELETE)\/api\/tti","^(GET|PUT|POST|DELETE)\/api\/notif-delivery","^(GET)\/api\/notif-services?","^PUT\/api\/attributes?\/\w+\/garageDoor[0-9]{1,2}\/presetPosition\/?$","^GET\/api\/auths?\/session-token\/?$","^(GET|DELETE)\/api\/activity-logs(\/.+){1,2}"],"roleNames":["site_user"]},"roleIds":["5526b99fb9cf33db6189438a"],"clientSchema":"UserAccountModel"}}} [5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] sending api key [5/2/2021, 2:47:12 PM] [homebridge-garagedoor-ryobi] message received: {"jsonrpc":"2.0","result":{"authorized":false,"varName":null},"error":null,"id":3} [5/2/2021, 2:47:14 PM] [homebridge-garagedoor-ryobi] Polling state of Garage Door [5/2/2021, 2:47:14 PM] [homebridge-garagedoor-ryobi] Updating ryobi data [5/2/2021, 2:47:14 PM] [homebridge-garagedoor-ryobi] getApiKey [5/2/2021, 2:47:14 PM] [homebridge-garagedoor-ryobi] GET https://tti.tiwiconnect.com/api/login [5/2/2021, 2:47:14 PM] [homebridge-garagedoor-ryobi] {"result":{"id":"57b5c8dca4d5ef055e4cabbf","varName":"beamatomy@gmail.com","metaData":{"companyName":"","surName":"","givenName":"","autoLogout":false,"authCount":394,"sys":{"lastSeen":1619885125809,"ip":"Capture Off"},"name":"Wilfred Yung","wskAuthAttempts":[{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-29 23:41:24","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-04-30 11:49:11","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-01 15:32:28","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-01 15:58:37","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-01 16:05:25","success":true}]},"accountOptions":{"email":"beamatomy@gmail.com","alertPhone":"","alertEmail":"beamatomy@gmail.com","receiveEmailUpdates":false,"receiveEmailAlerts":false,"receiveSmsAlerts":false,"productResearchInvitations":true,"receiveProductInfo":true,"homeDepotPromotions":true},"enabled":true,"deleted":false,"createdDate":"2016-08-18T14:40:28.073Z","activated":0,"notificationTransports":[],"auth":{"apiKey":"fd80ee9a","regPin":"e518","clientUserName":"superkule@icloud.com","createdDate":"2016-08-18T14:40:28.077Z","childSelectors":["5e6d2ead829ec8412f3932ba"],"roleMap":{"roleSelectors":[],"roleRegex":["^GET\/api\/(auths?|sessions?|ping|notifications?|user-name)\/?$","^PUT\/api\/(users?|auth-selectors?|user-name)\/?$","^GET\/api\/(notifications?|triggers?|subscriptions?|endnodes?|clients?|devices?|users?|attributes?)(\W?\w+)$","^GET\/api\/users?\/(config|session)\/?$","^(GET|PUT)\/api\/dashboards?(\W?\w+)$","^POST\/api\/(endnodes?|actions?|devices?)\/?$","^DELETE\/api\/(devices?|endnodes?|auth-selectors?)\/?\w+\/?$","^(GET|PUT|POST)\/api\/users?\/config\/?$","^GET\/api\/log","^PUT\/api\/(endnodes?|devices?)\/\w+\/?$","^POST\/api\/uploads?\/image\/?$","^(GET|POST)\/api\/(triggers?|subscriptions?)\/?$","^(PUT|DELETE|GET)\/api\/(triggers?|subscriptions?)","^(PUT|DELETE)\/api\/(notifications?)\/\w+\/?$","^(GET)\/api\/triggers\/.+\/(subscribe|unsubscribe)\/[a-zA-Z]+\/?$","^(GET|PUT|POST)\/api\/groups","^PUT\/api\/(auths?|users?)\/password\/?$","^GET\/api\/websockets?\/ticket\/?$","^PUT\/api\/rpc\/?$","RPC\/.*","^(GET|PUT|POST|DELETE)\/api\/tti","^(GET|PUT|POST|DELETE)\/api\/notif-delivery","^(GET)\/api\/notif-services?","^PUT\/api\/attributes?\/\w+\/garageDoor[0-9]{1,2}\/presetPosition\/?$","^GET\/api\/auths?\/session-token\/?$","^(GET|DELETE)\/api\/activity-logs(\/.+){1,2}"],"roleNames":["site_user"]},"roleIds":["5526b99fb9cf33db6189438a"],"clientSchema":"UserAccountModel"}}} [5/2/2021, 2:47:14 PM] [homebridge-garagedoor-ryobi] GET https://tti.tiwiconnect.com/api/devices/c4be8497df0d [5/2/2021, 2:47:15 PM] [homebridge-garagedoor-ryobi] {"result":[{"_id":"5e6d2ead829ec8412f3932ba","varName":"c4be8497df0d","metaData":{"name":"Garage Door","version":1,"icon":"/img/devices/gdo.png","description":"RYOBI Connected Garage Door Opener Master Unit","wskAuthAttempts":[{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-05-02 03:56:22","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-05-02 06:49:43","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-05-02 09:44:26","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-05-02 10:10:53","success":true},{"varName":"c4be8497df0d","apiKey":"EewDcAqBQjiIXRxzUmIRWeDg","ts":"2021-05-02 16:12:46","success":true}],"authCount":1207,"sys":{"lastSeen":1619981056417},"socketId":"b2cea5af.ip-10-0-0-39.ec2.internal.8080_c4be8497df0d"},"enabled":true,"deleted":false,"createdDate":"2020-03-14T19:21:17.230Z","activated":2,"deviceTypeIds":["gdoMasterUnit"],"deviceTypeMap":{"modulePort_9":{"metaData":{"name":"Module Port 9"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":["wifiModule_9"],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":7,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1584213700326},"portStatus":{"value":true,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1584213700326},"portId":{"value":9,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_8":{"metaData":{"name":"Module Port 8"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":["backupCharger_8"],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":6,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1584213698496},"portStatus":{"value":true,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1584213698496},"portId":{"value":8,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_7":{"metaData":{"name":"Module Port 7"},"ac":{},"at":{"triggerTemplateVarNames":{"value":["GDO.DoorOpens.varName","GDO.DoorCloses.varName","GDO.DoorOpenLongerThan.varName","GDO.DoorOpenAfter.varName","GDO.MotionSensor.__varName"],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":["garageDoor_7","garageLight_7"],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":5,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1584213698895},"portStatus":{"value":true,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1584213698895},"portId":{"value":7,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_6":{"metaData":{"name":"Module Port 6"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":6,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_5":{"metaData":{"name":"Module Port 5"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":5,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_4":{"metaData":{"name":"Module Port 4"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":4,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_3":{"metaData":{"name":"Module Port 3"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":3,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_2":{"metaData":{"name":"Module Port 2"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":2,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_1":{"metaData":{"name":"Module Port 1"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[]},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[]},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false},"portId":{"value":1,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"modulePort_0":{"metaData":{"name":"Module Port 0"},"ac":{},"at":{"triggerTemplateVarNames":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ab","min":[],"max":[],"metaData":{"icon":"icon.png","description":"varnames of trigger templates that the module in this port uses","name":"Trigger Template VarNames"},"units":"","dataType":"object","varType":"tc_array","varName":"triggerTemplateVarNames","defv":[],"lastValue":[],"lastSet":1618773668978},"moduleProfiles":{"value":[],"flags":["C"],"_id":"56f0572e474a81821adbf7ac","varName":"moduleProfiles","varType":"tc_array","dataType":"object","metaData":{"name":"Module Profile VarName(s)"},"defv":[],"min":[],"max":[],"lastValue":[],"lastSet":1618773668978},"moduleId":{"value":255,"flags":["C"],"_id":"56f0572e474a81821adbf7ad","varName":"moduleId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Module Type Id"},"defv":0,"min":0,"max":0,"lastValue":255,"lastSet":1618773668351},"portStatus":{"value":false,"flags":["C"],"_id":"56f0572e474a81821adbf7ae","varName":"portStatus","varType":"tc_bool","dataType":"boolean","metaData":{"name":"Port Status"},"defv":false,"min":false,"max":false,"lastValue":false,"lastSet":1618773668351},"portId":{"value":0,"flags":["C"],"_id":"56f0572e474a81821adbf7af","varName":"portId","varType":"tc_uint8","dataType":"number","metaData":{"name":"Port Id"},"max":255,"min":0,"defv":0}}},"masterUnit":{"metaData":{"icon":"/img/profiles/gdo.png","description":"GDO Master Unit","name":"Master Unit"},"ac":{},"at":{"nwpVersion":{"value":"1.0.0.10-2.4.0.2.31.1.3.0.1.1.0.3.34","flags":["C"],"_id":"56f0572e474a81821adbf7b1","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"TI WiFi Network Processor Version","name":"NWP Version"},"units":"","dataType":"string","varType":"tc_string","varName":"nwpVersion","lastValue":"1.0.0.10-2.4.0.2.31.1.3.0.1.1.0.3.34","lastSet":1584213697030},"appVersion":{"value":"1.0.7","flags":["C"],"_id":"56f0572e474a81821adbf7b2","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"The TTI wifi Firmware Version","name":"WiFi FW Version"},"units":"","dataType":"string","varType":"tc_string","varName":"appVersion","lastValue":"1.0.7","lastSet":1584990178680},"macAddress":{"value":"c4be8497df0d","flags":["C"],"_id":"56f0572e474a81821adbf7b3","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"the description","name":"MAC Address"},"units":"","dataType":"string","varType":"tc_string","varName":"macAddress","lastValue":"c4be8497df0d","lastSet":1584213677315},"serialNumber":{"value":"00000000000001","flags":["C"],"_id":"56f0572e474a81821adbf7b4","defv":"","min":"","max":"","metaData":{"icon":"icon.png","description":"","name":"Serial Number"},"units":"","dataType":"string","varType":"tc_string","varName":"serialNumber","lastValue":"00000000000001","lastSet":1584213677315},"portCount":{"value":10,"flags":["C"],"_id":"56f0572e474a81821adbf7b5","min":0,"max":255,"dataType":"number","varType":"tc_uint8","varName":"portCount","metaData":{"name":"Port Count"},"defv":7,"lastValue":10,"lastSet":1584213677315},"timeZoneOffset":{"value":-4,"flags":["SRV","C","SET"],"_id":"56f0572e474a81821adbf7b6","units":"hours","metaData":{"name":"Time Zone Offset"},"dataType":"number","varType":"tc_float","varName":"timeZoneOffset","max":14,"min":-12,"defv":0},"lastSeen":{"value":1619971966774,"flags":[],"_id":"56f0572e474a81821adbf7b7","varName":"lastSeen","varType":"tc_utcdate","dataType":"number","units":"","metaData":{"icon":"icon.png","description":"the description","name":"Last Seen"},"max":9223372036854776000,"min":0,"defv":0,"lastValue":1615395676437},"modulesInstalled":{"value":3,"flags":["C"],"_id":"56f0572e474a81821adbf7b8","defv":0,"min":0,"max":255,"metaData":{"icon":"icon.png","description":"the number of ports that are currently occupied","name":"Modules Installed"},"units":"","dataType":"number","varType":"tc_uint8","varName":"modulesInstalled","lastValue":3,"lastSet":1584213700339}}},"backupCharger_8":{"metaData":{"name":"Backup Charger","description":"GDO Main Unit","icon":"/img/profiles/gdo.png"},"ac":{},"at":{"chargeLevel":{"value":255,"flags":["C"],"defv":0,"min":-1,"max":100,"enum":["no battery",0,25,50,75,100],"metaData":{"messageType":"0x11","name":"Charge Level","description":"Level of battery charge","icon":"icon.png"},"units":"%","dataType":"number","varType":"tc_int8","varName":"chargeLevel","lastValue":255,"lastSet":1584255679464}}},"garageLight_7":{"metaData":{"name":"GDO Light"},"ac":{},"at":{"lightTimer":{"flags":["C","SET"],"min":0,"max":255,"metaData":{"name":"Light Timer","description":"Overhead Light Timer","icon":"icon.png"},"units":"","dataType":"number","varType":"tc_uint8","varName":"lightTimer","lastValue":3,"value":3,"lastSet":1584213700876},"lightState":{"value":false,"flags":["C","SET"],"defv":false,"min":false,"max":true,"metaData":{"name":"Light","description":"Overhead Light","icon":"icon.png"},"units":"off,on","dataType":"boolean","varType":"tc_bool","varName":"lightState","lastValue":true,"lastSet":1619979837705}}},"garageDoor_7":{"metaData":{"name":"GDO Door 200","icon":"/img/profiles/gdo.png"},"ac":{},"at":{"presetPosition":{"value":0,"flags":["C","SET"],"min":0,"max":72,"units":"inches","defv":0,"dataType":"number","varType":"tc_uint8","metaData":{"name":"Preset Position"},"varName":"presetPosition","lastValue":0},"maxDoorPosition":{"value":90,"flags":["C"],"min":0,"max":180,"metaData":{"name":"Uppermost Garage Door Position"},"defv":0,"dataType":"number","varType":"tc_uint8","varName":"maxDoorPosition","lastValue":90,"lastSet":1584213700876},"doorPosition":{"value":0,"flags":["C"],"min":0,"max":180,"metaData":{"name":"Garage Door Position"},"defv":0,"dataType":"number","varType":"tc_uint8","varName":"doorPosition","lastValue":3,"lastSet":1619979536405},"doorPercentOpen":{"value":-1,"flags":["C"],"min":-1,"max":100,"metaData":{"name":"Garage Door Percent Open"},"defv":-1,"dataType":"number","varType":"tc_uint8","varName":"doorPercentOpen"},"doorState":{"value":0,"flags":["C","SET"],"min":0,"max":4,"enum":["Closed","Open","Closing","Opening","Fault"],"defv":0,"metaData":{"name":"Garage Door State"},"units":"","dataType":"number","varType":"tc_uint8","varName":"doorState","lastValue":2,"lastSet":1619979536405},"opMode":{"value":0,"flags":["C"],"min":0,"max":5,"enum":["Standard","Pre-Lockout","Lockout"],"metaData":{"name":"Garage Door Operation Mode"},"units":"","dataType":"number","defv":0,"varType":"tc_uint8","varName":"opMode","lastValue":0,"lastSet":1592173046867},"sensorFlag":{"value":false,"flags":["C","SERV"],"metaData":{"name":"Safety Sensor Triggered"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"sensorFlag","lastValue":true,"lastSet":1619979514253},"vacationMode":{"value":false,"flags":["C","SERV"],"enum":["Disabled","Enabled"],"metaData":{"name":"Garage Door Vacation Mode"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"vacationMode","lastValue":false},"motorStatus":{"value":1,"flags":["C","SERV"],"metaData":{"name":"Garage Door Motor Status"},"units":"","dataType":"number","defv":0,"varType":"tc_uint8","varName":"motorStatus","lastValue":1,"lastSet":1584213702308},"alarmState":{"value":false,"flags":["C","SERV"],"metaData":{"name":"Garage Door Alarm State"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"alarmState","lastValue":true,"lastSet":1619979529289},"motionSensor":{"value":false,"flags":["C","SERV"],"metaData":{"name":"Garage Door Motion Sensor"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"motionSensor","lastValue":true,"lastSet":1619979675369},"heightUnits":{"value":false,"flags":["C"],"metaData":{"name":"Units Display"},"units":"","dataType":"boolean","defv":false,"varType":"tc_bool","varName":"heightUnits"}}},"wifiModule_9":{"metaData":{"name":"Wifi Module Status"},"ac":{},"at":{"serialNum":{"value":0,"flags":{"C":true},"defv":0,"metaData":{"name":"Serial Number"},"dataType":"number","varType":"tc_int8","varName":"serialNum"},"portInfoReq":{"value":0,"flags":{"C":true},"defv":0,"metaData":{"name":"Port Info Req"},"dataType":"number","varType":"tc_int8","varName":"portInfoReq"},"id":{"value":0,"flags":{"C":true},"defv":0,"metaData":{"name":"ID"},"dataType":"number","varType":"tc_int8","varName":"id"},"ssid":{"value":"?","flags":{"C":true},"defv":"?","metaData":{"name":"SSID Value"},"dataType":"string","varType":"tc_string","varName":"ssid"},"ipAddr":{"value":"0.0.0.0","flags":{"C":true},"defv":"0.0.0.0","metaData":{"name":"IP Address"},"dataType":"string","varType":"tc_string","varName":"ipAddr"},"rssi":{"value":-50,"flags":{"C":true},"defv":-50,"metaData":{"name":"RSSI Value"},"dataType":"number","varType":"tc_int8","varName":"rssi"},"macAddress":{"value":"","flags":{"C":true},"defv":"","metaData":{"name":"WiFi MAC Address"},"dataType":"string","varType":"tc_string","varName":"macAddress"}}}},"activatedDate":"2021-03-15T04:00:01.608Z"}]} [5/2/2021, 2:47:15 PM] [homebridge-garagedoor-ryobi] Garage Door: CLOSED (0)
First, sorry about having you reset your home I know that was a pita.
Also, did you also update to the latest NPM from about a week ago? It did fix one new error that was preventing getting the current state (although from your logs you did not have that error.)
I guess I should have asked this earlier but what is in your config file, I thought you told me but I don’t see it in the comments, so I was just confused. Also do you have multiple doors?
When you said you are getting alerts from homekit, just confirming that these alerts are from HomeKit and not the GDO app.
Note that I run on raspberian and I just did a full upgrade to make sure I was using the latest node and npm releases that are supported. My version of node is v12.22.1 you are running a much newer version. I am however running the same NPM and Homebridge versions as you.
One other thing I want to clearing, are you trying to trigger the open close directly via the home app or Siri. I sometimes see issues when I use Siri that never show up if I use the home app or CarPlay. Siri will say it does not have a response but it does usually still work.
OK....I have an idea something with websockets is messed up perhaps. run this command:
npm -g list ws
and show the results. I want to see if it shows as installed for my NPM.
For me it returns this:
/usr/lib
├─┬ homebridge-config-ui-x@4.41.0
│ └─┬ @nestjs/platform-socket.io@7.6.5
│ └─┬ socket.io@2.3.0
│ ├─┬ engine.io@3.4.2
│ │ └── ws@7.4.4
│ └─┬ socket.io-client@2.3.0
│ └─┬ engine.io-client@3.4.4
│ └── ws@6.1.4
├─┬ homebridge-garagedoor-ryobi@0.3.3
│ └── ws@7.4.5
├─┬ homebridge-harmony@1.5.2
│ └─┬ harmony-websocket@1.5.5
│ └── ws@7.4.5
└── ws@7.4.5
i'm thinking that NPM for some reason was not installed?
Sorry about the thinking going on here. So you are sending the command to the server, and I don't see an error being logged.
here is the code where we log the call and then make the call:
this.logger.debug('GARAGEDOOR openDoor');
await this.sendWebsocketCommand(device, { doorCommand: 1 });
and you can see "GARAGEDOOR openDoor" in your logs.
That code (this.sendWebsocketCommand) in turn uses:
import WebSocket from 'ws';
NPM which should be installed. Can you make sure you have that NPM installed by using the command above.
I'm thinking for some reason this may not have been installed because if you had homebridge debugging on we should have seen more stuff in the logs unless the construction of the web socket itself perhaps failed. It does look like nothing was sent because the logs should have had more in it.
This code path is different from where we get the state of the garage door which does seem to be working fine.
@andyedinborough , can you add back some error logging code to sendWebsocketCommand because I think it is failing but I don't know why and when you cleaned up the code you removed a try catch with error logging that might help track down this users issue:
The code that needs the try catch starts in this block:
private async getDevicesRaw() {
....
const promise = new Promise<void>((resolve) => {
**<<start try here>>**
const ws = new WebSocket(websocketURL);
....
ws.on('error', (x) => this.logger.error('error ' + x));
**<<END TRY HERE>>**
... and on error log the error. The old code did this:
this.log("Error sending sendWebsocketCommand");
this.log("Error Message: " + error);
});
Just pushed it up. Sorry, meant to do that as a PR.
Wow, that was fast! No problem just pushing things. Want me to update npmjs site?
One sec, I'm review if there's any holes.
I'm surprised you didn't log right around the code I noted as well. I'm deferring to you because my JS skills are really really old, when I did JS all this async stuff was not 'builtin'. I'm sure I had the initially logging when tracking down errors in the past.
Yeah, the error should propagate all the way up to that catch
. Async/await is a beautiful thing. ;] Should be ready to publish now.
reminds me, I need to retag the code with all your changes.
OK, I updated the version number, published, and tagged this as a release.
@superkule can you just update and try again and lets see if we get an error in the logs that will help isolate your issue. Thanks.
FYI..., I did test and it does work for me still, of course I never saw the issue.
this is what I see when I run the command, also I only have 1 GDO if that helps:
/usr/local/lib ├─┬ homebridge-config-ui-x@4.41.1 │ └─┬ @nestjs/platform-socket.io@7.6.5 │ └─┬ socket.io@2.3.0 │ ├─┬ engine.io@3.4.2 │ │ └── ws@7.4.5 │ └─┬ socket.io-client@2.3.0 │ └─┬ engine.io-client@3.4.4 │ └── ws@6.1.4 ├─┬ homebridge-garagedoor-ryobi@0.3.3 │ └── ws@7.4.5 └─┬ homebridge-nest-cam@7.2.0 └── ws@7.4.4
Thanks. That looks correct.
Hopefully if you pick up the latest version we will see an error in the log file that will give us an idea as to what has gone wrong.
I updated everything - and now see websocket error (at the bottom of the log)
[5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] Changing Garage Door to 0 [5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] GARAGEDOOR openDoor [5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] getApiKey [5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] GET https://tti.tiwiconnect.com/api/login [5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] {"result":{"id":"57b5c8dca4d5ef055e4cabbf","varName":"beamatomy@gmail.com","metaData":{"companyName":"","surName":"","givenName":"","autoLogout":false,"authCount":400,"sys":{"lastSeen":1620307275986,"ip":"Capture Off"},"name":"Wilfred Yung","wskAuthAttempts":[{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-03 21:12:51","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-04 21:13:22","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-04 21:13:59","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-04 21:20:58","success":true},{"varName":"beamatomy@gmail.com","apiKey":"fd80ee9a","ts":"2021-05-06 13:21:15","success":true}]},"accountOptions":{"email":"beamatomy@gmail.com","alertPhone":"","alertEmail":"beamatomy@gmail.com","receiveEmailUpdates":false,"receiveEmailAlerts":false,"receiveSmsAlerts":false,"productResearchInvitations":true,"receiveProductInfo":true,"homeDepotPromotions":true},"enabled":true,"deleted":false,"createdDate":"2016-08-18T14:40:28.073Z","activated":0,"notificationTransports":[],"auth":{"apiKey":"fd80ee9a","regPin":"e518","clientUserName":"superkule@icloud.com","createdDate":"2016-08-18T14:40:28.077Z","childSelectors":["5e6d2ead829ec8412f3932ba"],"roleMap":{"roleSelectors":[],"roleRegex":["^GET\/api\/(auths?|sessions?|ping|notifications?|user-name)\/?$","^PUT\/api\/(users?|auth-selectors?|user-name)\/?$","^GET\/api\/(notifications?|triggers?|subscriptions?|endnodes?|clients?|devices?|users?|attributes?)(\W?\w+)$","^GET\/api\/users?\/(config|session)\/?$","^(GET|PUT)\/api\/dashboards?(\W?\w+)$","^POST\/api\/(endnodes?|actions?|devices?)\/?$","^DELETE\/api\/(devices?|endnodes?|auth-selectors?)\/?\w+\/?$","^(GET|PUT|POST)\/api\/users?\/config\/?$","^GET\/api\/log","^PUT\/api\/(endnodes?|devices?)\/\w+\/?$","^POST\/api\/uploads?\/image\/?$","^(GET|POST)\/api\/(triggers?|subscriptions?)\/?$","^(PUT|DELETE|GET)\/api\/(triggers?|subscriptions?)","^(PUT|DELETE)\/api\/(notifications?)\/\w+\/?$","^(GET)\/api\/triggers\/.+\/(subscribe|unsubscribe)\/[a-zA-Z]+\/?$","^(GET|PUT|POST)\/api\/groups","^PUT\/api\/(auths?|users?)\/password\/?$","^GET\/api\/websockets?\/ticket\/?$","^PUT\/api\/rpc\/?$","RPC\/.*","^(GET|PUT|POST|DELETE)\/api\/tti","^(GET|PUT|POST|DELETE)\/api\/notif-delivery","^(GET)\/api\/notif-services?","^PUT\/api\/attributes?\/\w+\/garageDoor[0-9]{1,2}\/presetPosition\/?$","^GET\/api\/auths?\/session-token\/?$","^(GET|DELETE)\/api\/activity-logs(\/.+){1,2}"],"roleNames":["site_user"]},"roleIds":["5526b99fb9cf33db6189438a"],"clientSchema":"UserAccountModel"}}} [5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] sending api key [5/6/2021, 9:41:21 AM] [homebridge-garagedoor-ryobi] message received: {"jsonrpc":"2.0","result":{"authorized":false,"varName":null},"error":null,"id":3} [5/6/2021, 9:41:24 AM] [homebridge-nest-cam] Checking for alerts on Front Door [5/6/2021, 9:41:29 AM] [homebridge-garagedoor-ryobi] closing [5/6/2021, 9:41:29 AM] [homebridge-garagedoor-ryobi] WebSocket closing before completed [5/6/2021, 9:41:29 AM] [homebridge-garagedoor-ryobi] Error sending openDoor command: WebSocket closed prematurely
OK.. getting somewhere... getting a response that you are not authorized when being the API key! I'm a little confused as to why I did not see some of that logging earlier unless the logging buffer did not get flushed when the crash (uncaught exception) happened which we just fixed.
Can you double check that your password is correct in the config file?
More importantly does your password (or email?) contain symbols like '&', '?', '/'.... ? Things that sometimes get included weird? I had a bug that early on that was fixed but a bunch of that code was rewritten however to the eye it looks OK.
note: Also are there other log entries ever 90 seconds or so with the current garage door state? Just wondering because I did not see in any of your logs above.
Whats weird in the login result from ryobi is I see the email "beamatomy@gmail.com" and then your ""superkule@icloud.com" as your user name; would you know why that is? which one is in your config file?
I have "-" (dashes) in my password should I remove it? the initial ryobi account was setup with the beamatomy email, then I changed it later to the icloud one. In my config I use the icloud to login.
The iCloud account should be the correct one to use.
If you wouldn't mind could you try removing dashes from the password? I give it a 25% chance that might be the issue. But if anything it would simplify this. I'lll be out for the next 8 hours but I'll check back later.
Also, are you seeing other log entries every 90 seconds posting the garage door state? (OPEN/CLOSED...)
changed password but still same websocket issue - the polling every 90 seconds is fine shows the correct status seems only GDO open and close commands don't make it through
Thanks. It was worth a try.
One last thing for now. Can you copy your config settings (you can leave out your password) here?
I'm going to ask @andyedinborough to look at this. (At this point all I can think of is that the device id or the garage door type is somehow messed up although even that does not make sense because getting the status is working.)
Yep, I'll take a look. A quick glance makes it look like login is successful, but then the webhooks endpoint which does the actual opening/closing rejects the token returned by the login process.
@superkule besides getting your config settings, did it ever work for you?
@andyedinborough Thanks. You have it correct.
I actually don't see an issue except he may have multiple users set up with the other being "beamatomy@gmail.com."
I can't tell how he is actually logging into his GDO app and if this login is from a "managed account". I don't have a "managed account" and don't know if they have different access rights and access points (or even how they work.) I tried to create one but ryobi never sent an mail to me so the managed account request is still pending.
my config - Nest works fine, ryobi hasn't worked succesfully once - i mean I still get the updates when the door opens and closes via the ryobi gdo app or the physical remote, just can't open and close within homekit
{ "bridge": { "name": "Homebridge 6185", "username": "0E:19:37:24:61:85", "port": 51491, "pin": "924-52-872", "advertiser": "ciao" }, "accessories": [ { "accessory": "RyobiGarageCommand", "name": "Garage Door", "email": "superkule@icloud.com", "password": "???????", "_bridge": { "username": "0E:F4:AA:C4:68:28", "port": 49211 } } ], "platforms": [ { "email": "superkule@icloud.com", "password": "????.", "poll_short_delay": 15, "poll_long_delay": 90, "_bridge": { "username": "0E:35:7D:64:AA:B9", "port": 41464 }, "platform": "ryobi-gdo" } ], "disabledPlugins": [] }
I deleted your nest info and passwords, you don’t want that out for people to see.
@andyedinborough I was first confused as to why I was seeing stuff in both the accessories and platform sections. Then I looked at my config and noticed that it changed to be the same for me? I assume Homebridge, or homebridge UI, added the platform section? The reason I say this is because the platform section has the non required delay settings which I did not have in my settings.
I think the readme need to be updated (can you do that.)
I’m not sure what the ramifications are with entries duplicated in both sections are and if this could explain some of the issues.
I’m sure double entry is a result of making this a platform.
@superkule
I’m trying to get clear timeline because we made some big changes
very recently. When you said I worked once, did you first just install this a little over 3 or so weeks ago? And after it worked “once”, did it stop working after an update?
@andyedinborough i also don’t know what the bridge settings and port settings do but I do see they have different values in the two sections in @superkule’s config file?!?!?
@superkule
We can wait for Andy to pipe-in but in addition to the question I asked about when did you first install.... (which I'd like to know) you might try to remove the "accessories" section in your config file as the relevant information is duplicated in the platform section (which may happened automatically) because it does not need to be in twice and I'm making a guess that the different bridge/port setting in the 2 places might causes issues. (I don't have a bridge section and I do not understand how/why the bridge section is in your config but I have an unproven theory why this might be related to your issue.)
The bug change that we was put in recently was among other things to convert the code to be a "platform" so that is new and I really don't understand the ramifications if the info is duplicated.
For what it's worth, as I said above to Andy, I noticed it was duplicated in my config and I removed the accessories section in mine without issue.
@knuckleheadsmiff I'll update the readme. It should have only created a platform section if it was configured via homebridge-ui. The extra settings under _bridge
shouldn't do anything. The existing accessory configs should work side-by-side with the platform config.
@superkule The only thing I can figure is that having both accessories and the platform defined causes an issue with Ryobi's API. My guess is there's a race-condition. The platform and accessory configs act independently. One logs in and generates an api key, then the other logs in and generates an api key that invalidates the first one. I'll see if I can test that.
i removed accessories but still getting that websocket error, anything left to try?
@superkule I assume this was never fixed for you?
I did just push an update that references a newer version of web sockets but that version afaik only contains a minor security fix and should have nothing to do with your issue.
Hi knuckleheadsmiff
yes I have given up for now still doesn’t work however thank you and your team for helping to update the code and helping me diagnose. Keep up the great work!
thanks again!
HI KN,
this is the error I get in homebridge - I can open the GDO within the Ryobi app, but not within HomeKit. I do get the alerts in HomeKit that the door is opening or closing (however it will show HomeKit - no response error when I try to open or close within HomeKit) so its at least connected but it mentions error about wrong state exceeded value, any idea how to change or fix?
[4/17/2021, 8:18:16 PM] [Garage Door] State of Garage Door is: OPENING [4/17/2021, 8:18:16 PM] [homebridge-garagedoor-ryobi] This plugin generated a warning from the characteristic 'Target Door State': characteristic was supplied illegal value: number 2 exceeded maximum of 1. See https://git.io/JtMGR for more info. [4/17/2021, 8:18:28 PM] [Garage Door] State of Garage Door is: OPEN [4/17/2021, 8:19:58 PM] [Garage Door] State of Garage Door is: CLOSED [4/17/2021, 8:29:46 PM] [Garage Door] State of Garage Door is: CLOSING [4/17/2021, 8:29:46 PM] [homebridge-garagedoor-ryobi] This plugin generated a warning from the characteristic 'Target Door State': characteristic was supplied illegal value: number 3 exceeded maximum of 1. See https://git.io/JtMGR for more info. [4/17/2021, 8:30:33 PM] [Garage Door] State of Garage Door is: CLOSED
2nd error message - later in the day didn't do anything 4/18/2021, 9:04:22 AM] [Garage Door] Error update 1 - retrieving ryobi GDO status [4/18/2021, 9:04:22 AM] [Garage Door] Error Message: SyntaxError: Unexpected token < in JSON at position 0 [4/18/2021, 9:05:52 AM] [Garage Door] State of Garage Door is: CLOSED [4/18/2021, 9:56:28 AM] [homebridge-garagedoor-ryobi] This plugin slows down Homebridge. The read handler for the characteristic 'Target Door State' was slow to respond! See https://git.io/JtMGR for more info.