View Single Post
Posts: 42 | Thanked: 27 times | Joined on Jun 2010
#305
The python script with the notifications and setxkbmap configuration gives me an error. I can use it by manually writing the number 4 on it.

This is the output:

Code:
ERROR:dbus.connection:Exception in handler for D-Bus signal:
Traceback (most recent call last):
  File "/usr/lib/pymodules/python2.5/dbus/connection.py", line 214, in maybe_handle_message
    self._handler(*args, **kwargs)
  File "./keyboard.py", line 34, in connected
    keybId = re.search("ID (\\d+), Name: \"" + KEYBOARDNAME, str(testi)).group(1)
AttributeError: 'NoneType' object has no attribute 'group'
Also, the keyboard disconnects randomly, so I added to the python script a line to launch again the dbus-send when it detects that the keyboard disconnected:
Code:
dbus-send --system --print-reply --dest=org.blue  /org/bluez/${NUMERO}/hci0/dev_${MAC_TECLAT} org.bluez.Input.Connect
Obviously the disconnection has nothing to do with the script, but has anyone experienced it? I have to test more my keyboard (arrived today at home) to know when and why that happens...