-
Notifications
You must be signed in to change notification settings - Fork 284
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Codes sometimes reproducibly don't work with Siri until I toggle the state twice in the Home app - debug help request #754
Comments
Hi, |
Hi again, |
Doesn't bother me. |
I don't know if this is a problem with this plugin or my Broadlink RM Mini 3, but I have finally ruled out the TV and I think I've ruled out Siri. This had been happening quite some time with my previous dumb TV (a Magnavox) and now has happened with our new (hand-me-down) dumb LG TV, and it's more of a problem because CEC on the LG doesn't work (correctly).
PROBLEM: It appears that sometimes the code sent by the Mini doesn't work, and repeated sends of the same code reliably and reproducibly don't work either. The light on the mini flashes and the code in the homebridge log checks out (it is the correct code), so it thinks it is sending a code.
Notable details:
WORKAROUND: When the problem happens, I can open up the home app and manually toggle the button twice. The first tap synchs the actual power state with the home button state so that it is accurate. The second tap actually changes the power state of the TV (e.g. if I am trying to turn off the TV, I turn it "on" in the home app [and the TV remains on] and then I turn it off in the home app [and the TV actually turns off]). Every subsequent Siri on/off command then works as expected and I am unable to reproduce the problem even if I intentionally put the TV power state and the home app button power state out of synch.
Since this has now happened with 2 different TV's, I no longer think that it is a failure of the TV to correctly respond to the code. I feel like it must be that either the Mini is screwing up the code or the plugin is somehow showing the right code in the log, but it differs from the actual code sent.
Here is the accessory in the config:
Note, I have 2 mini's, that's why the host is set.
I am creating this issue to see if anyone has any debug suggestions. How can I confirm that the mini is actually sending the correct code, aside from what's in the homebridge log?
Additional Information
To be transparent, I am technically equating 2 different situations with the 2 TVs, because I didn't want to complicate things, but I think that there is additional information that may provide a clue to the root of the problem. I never actually had discrete on/off codes for the Magnavox TV. Instead, I simply had the toggle code for both the on and the off codes:
And I created a shortcut in node-red for the workaround:
SHORTCUT FOR THE WORKAROUND: This is essentially the same workaround as above, but since both on and off are set to toggle, it only needs to issue the opposite command once. I implemented the shortcut in node-red. Using node-red's homekitd node, I created a separate "TV toggler" button which retrieves the state of the homebridge TV button and issues the opposite command. E.g. if I'm trying to turn off the TV and the home button says it's off, it issues the on command (which turns the TV off because they're both the toggle code).
Insight
Since the config for the old Magnavox TV had the same toggle code for both on and off, this rules out the possibility that the plugin is sending the opposite code (but reporting in the log that it is sending the intended code). So I have no reason to believe that it is sending the opposite code.
Since the light on the mini flashes, it seems that the mini at least things it is sending a code. I just have no way to confirm it is sending the code.
The physical TV remote always works and there is nothing obstructing the line of sight between the mini and the TV, so either the mini is sending the wrong code or it thinks it is sending a code but it is not.
My intuition tells me that since this only seems to happen when the state is out of synch between the home app and the mini knows nothing about that, the problem must be with the plugin. I should actually test this using the broadlink app. If I can get a discrete code in the broadlink app to work when the siri-initiated command doesn't, that should rule out an issue with the mini itself.
Since I cannot intentionally reproduce the problem, my guess is that it has something to do with the initial state of the plugin after a homebridge restart. Though I don't know if the way that I create the synch issue is important (e.g. I could stand in front of the emitter, push the physical button, use the physical remote). I will have to see if I can determine a way to reproduce the issue...
The text was updated successfully, but these errors were encountered: