comice-control-center
comice-control-center copied to clipboard
some bluetooth error?
pear@PearBook-Air:~/comice-control-center$ ./comice-control-center
cat: /sys/class/bluetooth/hci0/rfkill3/state: No such file or directory
Traceback (most recent call last):
File "./comice-control-center", line 71, in do_activate
connection_box = ConnectionsBox()
File "/home/pear/comice-control-center/comicecontrolcenter/widgets/connection_box.py", line 65, in __init__
bluetooth = BluetoothInformation()
File "/home/pear/comice-control-center/comicecontrolcenter/functions/bluetooth_information.py", line 17, in __init__
powered_on = int(result)
ValueError: invalid literal for int() with base 10: ''
Maybe I did something wrong?
same issue for me too @alxb421
For me at least the problem was here: the state of BT is getting this file /sys/class/bluetooth/hci0/rfkill3/state, in my case i had no rfkill3. So I went to the folder and looked what rfkill do I have. Turns out I have rfkill2 there so you just change that in python file.
Hi guys! @alxb421 @kyrus7 @Dyrkon I'm a noob in terms of Bluetooth... I'm trying to understand the rfkill concept.
Can you share me the full path of bluetooth state file? In my case is /sys/class/bluetooth/hci0/rfkill3/state
but can be different in your machines or devices. So with that data i can improve the code to recognize better the state of the bluetooth.
You can open a file manager (nautilus, thunar, etc... or with terminal using cat
command). And view the content of something similar in the folder /sys/class/bluetooth/<device>/<userspace>/
and find inside the state file the value saved on it.
Regards!
For me at least the problem was here: the state of BT is getting this file /sys/class/bluetooth/hci0/rfkill3/state, in my case i had no rfkill3. So I went to the folder and looked what rfkill do I have. Turns out I have rfkill2 there so you just change that in python file.
could you please Dyrkon explain to me how did you do that step by step? thanks in advance
pear@PearBook-Air:~/comice-control-center$ ./comice-control-center cat: /sys/class/bluetooth/hci0/rfkill3/state: No such file or directory Traceback (most recent call last): File "./comice-control-center", line 71, in do_activate connection_box = ConnectionsBox() File "/home/pear/comice-control-center/comicecontrolcenter/widgets/connection_box.py", line 65, in __init__ bluetooth = BluetoothInformation() File "/home/pear/comice-control-center/comicecontrolcenter/functions/bluetooth_information.py", line 17, in __init__ powered_on = int(result) ValueError: invalid literal for int() with base 10: ''
Maybe I did something wrong?
if you modify the file ~/comice-control-center/comicecontrolcenter/functions/bluetooth_information.py on line 14, this """cat /sys/class/bluetooth/hci0/rfkill2/state"""
to this " ""cat /sys/class/bluetooth/hci0/rfkill*/state"""
and updating all BT services should work
also u can modify the hci0
for hci*
because the BT controllers in Linux normaly have this prefix
Fixed!