-
Notifications
You must be signed in to change notification settings - Fork 14
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
Attempting this on Raspberry Pi #1
Comments
@CaptBeard I have been working on trying to turn this work into a Home Assistant custom component and what I have been finding is bluetooth low energy has varying levels of support. I am guessing that is output from the nodeJS version, which basically creates a shell with the command
Based on what I am reading, you may need to restart the bluetooth service or the user does not have bluetooth permissions. It is also possible that the formatting is different between versions or, most likely, I messed something up. Let me know if the output looks of |
@Thrilleratplay It looks like it sort of works on the pi.
This is where it stops and I have to break it and run again. |
I think I see what the issue is. The output is different and regular expression does not take into account lines starting with " [bluetooth]# ". The easier way to work around this would be on line 47 of index.js to remove that string in the sanitize function. It would look something like: const sanitize = (str) => ransi(str).replace(/\[bluetooth\]\# /g, '').replace(/\u0001\u0002/g, '').replace(/\r/g, ''); That may take some tweaking as I haven't tested it. Currently I am busy at work and will not have time to test this on any of my pi's for a while. I hope this helps in the meantime. Additionally, make sure you run |
Thanks for making this POC.
I'm in the process of trying to make something to read my two Govee devices and then port that to home bridge.
I'm having an issue getting this to run on my rPi.
I ran it with debug on and I'm getting this:
[ '',
undefined,
index: 0,
input: 'Waiting to connect to bluetoothd...',
groups: undefined ]
Waiting to connect to bluetoothd...
[ '',
undefined,
index: 0,
input: '[bluetooth]# [NEW] Controller B8:27:EB:FA:38:19 rpi [default]\n[bluetooth]# ',
groups: undefined ]
[bluetooth]# [NEW] Controller B8:27:EB:FA:38:19 rpi [default]
[bluetooth]#
Looks like it freezes after it turns on the BT controller.
Any help? TIA
The text was updated successfully, but these errors were encountered: