Skip to content
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

Hub disconnects on first write? #16

Open
coezbek opened this issue Jun 15, 2020 · 0 comments
Open

Hub disconnects on first write? #16

coezbek opened this issue Jun 15, 2020 · 0 comments

Comments

@coezbek
Copy link

coezbek commented Jun 15, 2020

When connecting to the MoveHub on Raspi 4 it seems that upon first write the MoveHub disconnects (LED starts white blinking after solid blue). Any idea why this could be?

INFO:BLE Event Q.0:Connected to device Idas gitare:00:16:53:B4:DC:8F
INFO:robot.6:Waiting for peripheral motor_r to attach to a port
DEBUG:robot.6:starting peripheral message loop
DEBUG:robot.6:peripheral msg: hub_btn.1 attach
DEBUG:bricknil.sockets:{"hub": "robot", "peripheral_type": "Button", "peripheral_name": "hub_btn", "peripheral_port": 255, "message": "Activate button reports: port 255"}
DEBUG:BLE Event Q.0:Got msg: Activate button reports: port 255 = [0, 1, 2, 2]
DEBUG:BLE Event Q.0:Got msg: req mode info on 255 = [0, 33, 255, 1]
INFO:robot.6:Waiting for peripheral motor_r to attach to a port
DEBUG:bleak.backends.bluezdbus.discovery:dev_00_16_53_B4_DC_8F, 00:16:53:B4:DC:8F (-67 dBm), Object Path: /org/bluez/hci0/dev_00_16_53_B4_DC_8F
Traceback (most recent call last):
  File "list_ports_boost_hub.py", line 38, in <module>
    start(system)
  File "/usr/local/lib/python3.7/dist-packages/bricknil/bricknil.py", line 214, in start
    ble.run()
  File "/usr/local/lib/python3.7/dist-packages/bricknil/bleak_interface.py", line 52, in run
    self.loop.run_until_complete(self.asyncio_loop())
  File "/usr/lib/python3.7/asyncio/base_events.py", line 584, in run_until_complete
    return future.result()
  File "/usr/local/lib/python3.7/dist-packages/bricknil/bleak_interface.py", line 75, in asyncio_loop
    await device.write_gatt_char(char_uuid, msg_bytes)
  File "/usr/local/lib/python3.7/dist-packages/bleak/backends/bluezdbus/client.py", line 252, in write_gatt_char
    self.loop
txdbus.error.RemoteError: org.bluez.Error.Failed: Not connected
INFO:robot.6:Waiting for peripheral motor_r to attach to a port
INFO:robot.6:Waiting for peripheral motor_r to attach to a port
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant