default.map applied when deleting lines

Bug #526977 reported by Yonas Uikblath
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Pystromo
Invalid
Undecided
Unassigned

Bug Description

I'm using a normal N52 under Ubuntu 9.10, and have followed the popular guide of installing pystromo.

Every time I use 'sudo ./pystromo-remap.py –m config/default.map' after cd'ing to the right directory my layout wont be applied. The terminal acts like it should be (jumping down one line and its blank). My layout only gets applied if I let the terminal be, go to default.map and delete a huge bunch of lines and then save the file. All keys work after that and it seems it doesnt care about me deleting a chunk of them.

i.e
First it wont work like this:
KEY_TAB:KEY_P
KEY_Q:KEY_W
KEY_W:KEY_R
KEY_E:KEY_A
KEY_R:KEY_F

After deleting down to this it works:
KEY_TAB:KEY_P
KEY_Q:KEY_W

How come the layout wont be loaded in the first place without me having to delete keys (which just makes very little sense to me)?

Revision history for this message
Raumkraut (raumkraut) wrote :

Unless you specify certain command-line arguments, the remapper will read in the mapping file only once at startup. Using the command you specified in the bug report, altering the mapping file while the remapper is running should not have any effect.
The program can take a few moments to start everything up, perhaps you're being a bit too impatient? :)

Could you try running the remapper with an additional `-vvv` option? The output of that will tell us if it's receiving the keyboard commands, and what it's trying to do with them.
It would probably also be useful to see the mapping file that you're trying to use.

Revision history for this message
Yonas Uikblath (wikbladjonas) wrote :

undain@YonasAu:~/.config/pystromo$ sudo ./pystromo-remap.py –m config/default.map -vvv

Using output: <lib.devices.OutputDevice object at 0x8d6510c>
Loading mappings
Traceback (most recent call last):
  File "./pystromo-remap.py", line 169, in <module>
    keymap = loadMappings()
  File "./pystromo-remap.py", line 65, in loadMappings
    print '; '.join(options.maps)
TypeError

I bet I am doing something very wrong. If so, excuse me (still very new to Linux, but struggles to learn it)

Revision history for this message
Yonas Uikblath (wikbladjonas) wrote :

This is bugging me out ..........
I got it to work, finally. I dont know HOW. I started from scratch, did all the steps and then I unplugged the N52 after configuring the default.map by starting it from Terminal. When it was done and I saved, I ran the 'sudo ./pystromo-remap.py -m default.map' it said it was busy. Figuring it was the Terminal calling to default.map I saved the file and closed down the terminal. Ran earlier command, said it was busy. I unplugged and plugged back in the N52, used 'sudo ./pystromo-remap.py -m default.map' again and touche:

undain@YonasAu:~/.config/pystromo$ ./pystromo-remap.py -m default.map
/home/undain/.config/pystromo/lib/mapping.py:554: DeprecationWarning: object.__init__() takes no parameters
  tuple.__init__(self, *args, **kwargs)
/home/undain/.config/pystromo/lib/mapping.py:648: DeprecationWarning: object.__init__() takes no parameters
  tuple.__init__(self, *args, **kwargs)
/home/undain/.config/pystromo/lib/mapping.py:501: DeprecationWarning: object.__init__() takes no parameters
  tuple.__init__(self, *args, **kwargs)
1234

Those '1234' was me typing to test. Now I'm just gonna close down this terminal, make further changes and see how it goes.

Revision history for this message
Yonas Uikblath (wikbladjonas) wrote :

... it's all working flawlessly now!

It seems it doesn't matter if the Terminal that ran './pystromo-remap.py -m default.map' is active or not, only if the python process is.

Thank you, a LOT for making this program! I ... It's simply amazing! No more arseing with Linux's Nostromo Driver.

I bow down to you Raumkraut. The N52 will not rest any more on the desktop from now on.

Revision history for this message
Raumkraut (raumkraut) wrote :

That TypeError was... odd, to say the least. I've no idea what was going on there.
Glad you got it working in the end though. :)

Changed in pystromo:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.