Keyboard re-mapping (key binding)

More
08 Nov 2011 15:27 #14675 by ioiotutu
Hi,
is it possible remap some commands keys?

I need to swap arrow-left/arrow-right (X moving) with arrow-up/arrow-dn (Y moving). Is there a config file for this?

Thanks,
Michele

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 16:49 #14677 by BigJohnT
AFAIK you have edit axis.py to change keyboard mapping. Are you wanting to do this because your machine jogs backwards?

John

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 16:57 - 08 Nov 2011 16:58 #14678 by andypugh
ioiotutu wrote:

is it possible remap some commands keys?


I think so.
linuxcnc.org/docs/html/gui_axis.html#r1_11_4

Though I don't know if that allows you to re-map keys which are already allocated. I also have no idea what the correct syntax is, but you can probably just copy the program lines from inside Axis.
Last edit: 08 Nov 2011 16:58 by andypugh.

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 17:14 #14680 by ioiotutu
Thanks,
when i'm in front of the machine i see Y axis: moving right + direction, moving left - direction. X axis moving to me + direction and far to me - direction.
Home position is right - up (far to me).

I hope you understand my bad english!

So when push arrow key i need:

arrow-right -> Y +
arrow-left -> Y -
arrow-up -> X-
arrow-down -> X+

where can i find axis.py?

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 17:29 #14683 by BigJohnT
Normally when you stand in front of a XYZ machine the X axis is the one that goes left/right, the Y in/out, the Z up,down. Normal machines X+ jogs the tool to the right and Y+ jogs the tool away from you and Z+ jogs the tool up. I say tool because some machines move the spindle in XY and some move the material in XY but relative to the material the tool movement is what you want to move in the correct directions.

Unless you have some strange machine... do you have a photo of it?

John

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 17:39 #14685 by ioiotutu
Here is the photo.

If i stay left side all is ok, but usually i stay in front and i confuse me with jog.
Attachments:

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 17:49 #14686 by ioiotutu
here is a scheme.
Attachments:

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 19:01 #14690 by BigJohnT
Ok, that makes sense the machine is correct but you don't stand in the conventional position. Have you give any thought to using a joy pad to jog with instead of lugging the keypad to the machine? Otherwise you would have to modify axis.py to change the key bindings. I scanned through the 3400 lines of code and nothing jumped out at me.

John

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 19:50 #14694 by andypugh
BigJohnT wrote:

Otherwise you would have to modify axis.py to change the key bindings. I scanned through the 3400 lines of code and nothing jumped out at me.


Is this thing on?
www.linuxcnc.org/component/option,com_ku.../lang,english/#14678

Please Log in or Create an account to join the conversation.

More
08 Nov 2011 21:48 #14701 by BigJohnT
Andy's suggestion to use .axisrc is better than my not so well thought out answer. If it exists, the contents of ~/.axisrc are executed as Python source code just before the AXIS gui is displayed. Putting your changes in .axisrc they won't get overwritten at the next upgrade...

John

Please Log in or Create an account to join the conversation.

Time to create page: 0.103 seconds
Powered by Kunena Forum