ruundii/bthidhub

Question: Switching hosts on non-apple keyboards

Anonymous1893 opened this issue · 3 comments

Does anyone know how to switch devices using this hub?

I can't find it anywhere in the documentation.

Once I can actually use the project again, I'll look at making this customisable. If you're familiar with Python, it shouldn't be difficult to look through the code and put in some kind of hack in the meantime.

Honestly don’t have much experience with large scale python stuff like this, but if i come up with a hack i’ll be sure to share it here. Appreciate you carrying this repo while the dev is MIA.

Not sure I'd call it large scale (probably <1000 lines). :P

At a quick glance, the switch happens here:

bthidhub/hid_devices.py

Lines 68 to 69 in c979471

if tm == b'\xff':
self.device_registry.bluetooth_devices.switch_host()

If you print out the value of tm when pressing the desired button, you can probably just copy that value into the if statement and get it working... in theory...