vikeys - terminal app for keymap editing (tmk/ergodox)
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
I've been playing with a curses based terminal tool to edit keymap.h files in the tmk firmware and have reached a stage where it's almost useable .
I wanted to see if anyone else would be interested in such a tool and/or have ideas for functionality?
Consider it an early alpha. I have only tested it on OS X using iTerm. Terminal.app should also work but mouse support wont work so well there. I have tried to think about Windows users but it hasn't been tested there.
Right now it only has support for the ErgoDox keyboard layout and loading/writing of tmk firmware header files but it should be easy to add support for other firmwares and keyboards if anyone is interested.
Loading and saving works, but right now you can't edit the action definitions.
If you try it, please make sure to back up your original .h file if you save with the same name, the tool will rewrite the file completely in a not so human friendly format.
More information can be found here:
https://github.com/CJNE/vikeys
Questions, comments and suggestions are welcome
Screenshot of it's current state:
I wanted to see if anyone else would be interested in such a tool and/or have ideas for functionality?
Consider it an early alpha. I have only tested it on OS X using iTerm. Terminal.app should also work but mouse support wont work so well there. I have tried to think about Windows users but it hasn't been tested there.
Right now it only has support for the ErgoDox keyboard layout and loading/writing of tmk firmware header files but it should be easy to add support for other firmwares and keyboards if anyone is interested.
Loading and saving works, but right now you can't edit the action definitions.
If you try it, please make sure to back up your original .h file if you save with the same name, the tool will rewrite the file completely in a not so human friendly format.
More information can be found here:
https://github.com/CJNE/vikeys
Questions, comments and suggestions are welcome
Screenshot of it's current state:
- damorgue
- Location: Sweden
- Main mouse: MX500
- Favorite switch: BS, MX Green and MX Clear
- DT Pro Member: -
- Contact:
Looks neat. I believe a few have tried this in the past. Does it support macros, strings and more advanced layer functionality?
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
Right now you can't edit actions, that's what i'm working on at the moment.
It will be possible to construct any kind of action, such as macros and all types of layer functionality. If you look at the screenshot you can see the list of actions that were parsed from the .h file, the plan is to make them editable and have a way to add/delete.
It will be possible to construct any kind of action, such as macros and all types of layer functionality. If you look at the screenshot you can see the list of actions that were parsed from the .h file, the plan is to make them editable and have a way to add/delete.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
Very interested! I can't test for Ergodox support but I'll play around with it and let you know how it goes.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
I'm going to be using TMK for a custom 65% at some point in the near future. The layout will be something like this except properly put together:
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
I can add a layout for it when i get a chance, or you can do one and send to me
Here's how it's done: https://github.com/CJNE/vikeys/blob/mas ... yboards.js
Every number represents a key, null means blank space. The "resolution" needed depends on how many different key sizes you
have, and how accurately it should be displayed.
Here's how it's done: https://github.com/CJNE/vikeys/blob/mas ... yboards.js
Every number represents a key, null means blank space. The "resolution" needed depends on how many different key sizes you
have, and how accurately it should be displayed.
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
I've thought of making something graphical like this to aid my cunning with Soarer's Converter and Controller. But then I remember I'm not a programmer. I like playing in Interface Builder, but then comes the hard part…
Anyway, good luck with this. Hasu's great library has me stumped, but there's great features in there looking for liberation into the hands of riffraff like me. Tap triggers and layer locks are the ones I'd really like to play with. I'm beginning to get into it with his ADB converter, but Soarer's was a faster learning experience for me.
Anyway, good luck with this. Hasu's great library has me stumped, but there's great features in there looking for liberation into the hands of riffraff like me. Tap triggers and layer locks are the ones I'd really like to play with. I'm beginning to get into it with his ADB converter, but Soarer's was a faster learning experience for me.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
I've been meaning to learn Node, so I might give it a try.CJNE wrote:I can add a layout for it when i get a chance, or you can do one and send to me
Here's how it's done: https://github.com/CJNE/vikeys/blob/mas ... yboards.js
Every number represents a key, null means blank space. The "resolution" needed depends on how many different key sizes you
have, and how accurately it should be displayed.
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
I've been meaning to take a look at Soarers firmware but i haven't had the chance so far, it's something i'd like to add support for. But first i'll make it possible and easy to make use of all the functionality in TMK's action functions
I did consider a Cocoa app at first but i really like to do as much as possible in the terminal, and it is a nice challenge
I did consider a Cocoa app at first but i really like to do as much as possible in the terminal, and it is a nice challenge
- Muirium
- µ
- Location: Edinburgh, Scotland
- Main keyboard: HHKB Type-S with Bluetooth by Hasu
- Main mouse: Apple Magic Mouse
- Favorite switch: Gotta Try 'Em All
- DT Pro Member: µ
Soarer's uses NVRAM on the Teensy to store configuration, so you can edit on the fly. I think Hasu's requires a rebuild on every edit. Soarer's tools for making changes are command line based (and open source, unlike the firmware itself, which will be eventually). I edit text files, then hit a couple of commands in Terminal, and the deed is done. But it could use a more visual, interactive and forgiving interface.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
You could also consider parsing the JSON output from keyboard-layout-editor.com as input. That would be nice for quickly prototyping layouts. Maybe you'll see a pull request from me soon... Just thinking aloud here, don't mind me...
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
Cool, will take a look at that sitescottc wrote:You could also consider parsing the JSON output from keyboard-layout-editor.com as input. That would be nice for quickly prototyping layouts. Maybe you'll see a pull request from me soon... Just thinking aloud here, don't mind me...
Aha, that would require a different approach but maybe it could be made to look and work the same... interesting!Muirium wrote:Soarer's uses NVRAM on the Teensy to store configuration, so you can edit on the fly.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
I found a bug! I'm working away at trying to add my own layout but I'm getting sleepy so I think I'll continue tomorrow.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
Yep, nothing serious though. When drawing the matrix you have a hard-coded number of keys (I'm guessing the amount the Ergodox has ) which means that it throws confusing errors when trying to load other keymaps. I've sent a pull request.
- uberben
- Location: Canada
- Main keyboard: Modified Kinesis Essential
- Main mouse: Logitech M570
- DT Pro Member: -
This looks awesome, CJNE! I'm about to pick up my Kinesis controller replacement project again (using TMK) and was wanting to do something similar to this. If it hasn't been done already, I'll see what I can do to make it fit the Kinesis.
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
uberben: Thanks! Let me know if you need any assistance with adding a layout for the Kinesis (has not been done).
Making some progress on action editing, it mostly works now but there are still some UX things to do, and macros are missing.
Here's the current state:
Making some progress on action editing, it mostly works now but there are still some UX things to do, and macros are missing.
Here's the current state:
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
How can you define keys that aren't a multiple of 0.5U? Like Caps Lock or ANSI enter, for example?
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
You can, in theory, increase the resolution by making the layout array bigger. But there is also a limit in screen resolution so unless you have a very big terminal window you probably won't be able to see the difference anyway...
For the ergodox layout each 1U is represented by 2x2 array entries, so a 1.5U key would be 3x2, 2U is 4x2 etc.
To get 0.25U resolution you would have to double the sizes, and double again to get 0.125U resolution.
It will be a lot of work to type it in but it wont affect performance, it's parsed only once..
Did that make sense?
For the ergodox layout each 1U is represented by 2x2 array entries, so a 1.5U key would be 3x2, 2U is 4x2 etc.
To get 0.25U resolution you would have to double the sizes, and double again to get 0.125U resolution.
It will be a lot of work to type it in but it wont affect performance, it's parsed only once..
Did that make sense?
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
Ohh, I see. I misunderstood what was happening there, then. And the layout is only used for figuring out the physical wiring of rows/columns?
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
Cool! Thanks for the tip.
I'm still encountering a couple of bugs (on Linux, if that makes a difference):
- If the terminal window is maximised onscreen, I can't click some keys on the right hand side
- After putting a layout in keyboards.js, assigning all of the keys some values and hitting "save", it crashes. I can't remember the error and don't have my laptop around right now to check, but I believe it was "cannot read length of undefined". Might be another ergodox-specific magic number, perhaps?
Any ideas?
I'm still encountering a couple of bugs (on Linux, if that makes a difference):
- If the terminal window is maximised onscreen, I can't click some keys on the right hand side
- After putting a layout in keyboards.js, assigning all of the keys some values and hitting "save", it crashes. I can't remember the error and don't have my laptop around right now to check, but I believe it was "cannot read length of undefined". Might be another ergodox-specific magic number, perhaps?
Any ideas?
-
- Location: Sweden
- Main keyboard: HHKB Pro 2
- Main mouse: MS IntelliMouse Explorer 3
- Favorite switch: MX Brown
- DT Pro Member: -
The first problem will need some testing, haven't tried on Linux yet but i plan to do so soon
I have pushed a fix for the other problem to github just now, i think it should work!
I have pushed a fix for the other problem to github just now, i think it should work!
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
Great! I'll test the second part but it takes quite some time because I need to assign all 70 keys.
- scottc
- ☃
- Location: Remote locations in Europe
- Main keyboard: GH60-HASRO 62g Nixies, HHKB Pro1 HS, Novatouch
- Main mouse: Steelseries Rival 300
- Favorite switch: Nixdorf 'Soft Touch' MX Black
- DT Pro Member: -
Saving works now! But loading doesn't: "cannot read length of undefined"
Edit: Now it does! You've got a pull request.
Edit: Now it does! You've got a pull request.
- HaaTa
- Master Kiibohd Hunter
- Location: San Jose, California, USA
- Main keyboard: Depends the day
- Main mouse: CST L-TracX
- Favorite switch: Fujitsu Leaf Spring/Topre/BS/Super Alps
- DT Pro Member: 0006
- Contact:
Interesting...
I may have to look at this later. If it looks usable I don't mind writing patches for Linux support.
I may have to look at this later. If it looks usable I don't mind writing patches for Linux support.