-
Notifications
You must be signed in to change notification settings - Fork 1
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
Error when starting the script (93, 'Protocol not supported') #5
Comments
Hi! Are you running Home Assistant from a Raspberry Pi? If yes maybe you can try this solution: https://support.plugable.com/t/bluetooth-home-automation-switch-btaps1-raspberry-pi-error/8554 |
Sorry for late reply, I was a bit offline :-( I run HA in a VM on a Synology DSM7. Bluetooth is working as i have also some other BT sensors connected to my HA. I am running the latest HA version 2022.2 I also tried now to add the line in the config, but its doesnt change anything. |
This plugin uses a special Bluetooth protocol to communicate with the Timebox called the RFCOMM protocol which does not seem supported in your configuration. If you use Docker to run HA on your Synology NAS, be sure to follow these instructions: https://philhawthorne.com/installing-home-assistant-io-on-a-synology-diskstation-nas/ (see Adding a Bluetooth Radio) If you run HA as a VM, then it may be related to:
Which Bluetooth USB do you use? |
finally I switched from my VM installation to a brand new dedicated x64 HW to run HA OS. I have much more access to my HW now (as expected). And I used your new HACS integration - thanks for that, it makes it much easier. BUT Its still not working :-( same error like before: Traceback (most recent call last): how to check if RFCOMM is availiable? |
Sorry to hear that |
I tried with the internal first. I think its Intel as it's an Intel machine. And also try 2 external usb. But not sure If the externals are used. How could I Set this up? |
You can list your Bluetooth adapters with this command: Unfortunately with the Bluez library it is not easy to select which Bluetooth adapter to use. It think that by default it uses the first available one so the internal one. |
I see one is listed as default, but i think it is only for bluetoothctl commands, not for HomeAssistant.
Then power on external adapter but also force remove Timebox:
At this point the Timebox should display the Bluetooth logo
then restart HomeAssistant (not the computer) from the web UI and try to call the service again |
I dont get it running. When starting the script, taken from the example the following error appears:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 185, in handle_call_service
await hass.services.async_call(
File "/usr/src/homeassistant/homeassistant/core.py", line 1495, in async_call
task.result()
File "/usr/src/homeassistant/homeassistant/core.py", line 1530, in _execute_service
await handler.job.target(service_call)
File "/usr/src/homeassistant/homeassistant/components/script/init.py", line 280, in service_handler
await script_entity.async_turn_on(
File "/usr/src/homeassistant/homeassistant/components/script/init.py", line 384, in async_turn_on
await coro
File "/usr/src/homeassistant/homeassistant/components/script/init.py", line 410, in _async_run
return await self.script.async_run(script_vars, context)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 1243, in async_run
await asyncio.shield(run.async_run())
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 353, in async_run
await self._async_step(log_exceptions=False)
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 371, in _async_step
await getattr(self, handler)()
File "/usr/src/homeassistant/homeassistant/helpers/script.py", line 571, in _async_call_service_step
await service_task
File "/usr/src/homeassistant/homeassistant/core.py", line 1495, in async_call
task.result()
File "/usr/src/homeassistant/homeassistant/core.py", line 1534, in _execute_service
await self._hass.async_add_executor_job(handler.job.target, service_call)
File "/usr/local/lib/python3.9/concurrent/futures/thread.py", line 52, in run
result = self.fn(*self.args, **self.kwargs)
File "/config/custom_components/timebox_mini/init.py", line 288, in handle_action
dev = Timebox(mac)
File "/config/custom_components/timebox_mini/init.py", line 34, in init
self.sock = bluetooth.BluetoothSocket(bluetooth.RFCOMM)
File "/usr/local/lib/python3.9/site-packages/bluetooth/bluez.py", line 155, in init
_sock = _bt.btsocket (proto)
_bluetooth.error: (93, 'Protocol not supported')
The text was updated successfully, but these errors were encountered: