kiwi-cam / homebridge-broadlink-rm

[This fork supports TV accessories] Broadlink RM Mini and Pro plugin for homebridge: https://github.com/nfarina/homebridge
Apache License 2.0
302 stars 96 forks source link

Expected Behavior When Two RM4 Pros are Active? When They are Rediscovered? (+ enhancement?) #686

Open shanemcw opened 7 months ago

shanemcw commented 7 months ago

Describe the bug What is the expected behavior when two RM4 Pros are active? When They Are Swapped Out?

To Reproduce Have two RM4 Pros visible to the Broadlink App. Test action of both active, test functionality when they are powered off and on independently, and does the Home functionality function?

Expected behavior Unknown—this ticket is to ask. Observed behavior is documented below.

Additional context

What is the intended/expected behavior when two RM4 Pros are active?

Observations:

  1. When one is active and working, plug in another one and set it up. Both now appear in the Broadlink app.
  2. Operate a device with the Home app via the Homebridge RM4 Pro plugin.
  3. The newly-added RM4 Pro device is now the one sending RF signals and the controlled device responds.
  4. The original RM4 Pro now does not send RF signals.
  5. Unplug the newly-added RF-sending RM4 Pro.
  6. The Homebridge plugin responds the RM4 Pro device connection has been lost.
  7. Attempt to operate a device with the Home app via the Homebridge RM4 Pro plugin.
  8. The original active RM4 Pro does not send RF signals.
  9. Unplug that original RM4 Pro.
  10. The Homebridge plugin responds the original RM4 Pro device connection has been lost.
  11. Plug back in the original RM4 Pro.
  12. The Homebridge plugin responds the RM4 Pro device connection has been found again.
  13. Attempt to operate a device with the Home app via the Homebridge RM4 Pro plugin.
  14. The original active and newly re-discovered RM4 Pro does not send RF signals.

At this step, looks like there is a bug there—not passing control back to the newly re-found device.

What is the expected behavior? Is this a bug?

Thanks for any counsel!

Note: A restart restores functionality in the above state.

shanemcw commented 7 months ago

Potential enhancement to support a multi-RM4 Pro use case:

RM4 Pro #1 downstairs, IR line of sight to the living room TV, close to the downstairs RF-controlled blinds, RM4 Pro #2 upstairs, IR line of sight to the bedroom TV, close to the upstairs RF-controlled blinds.

I.e., add an optional specification for each object in the accessories array that, when specified, indicates which single one of potentially multiple RM4 Pro devices to route the commands for it.

An optional default specification at the platform level of which of the potentially multiple RM4 Pros to use for routing when not specified at the accessory level.