Author Topic: Hello (and assistance needed with custom 60% keyboard)  (Read 2689 times)

0 Members and 1 Guest are viewing this topic.

Offline zanzibar312

  • Thread Starter
  • Posts: 7
Hello (and assistance needed with custom 60% keyboard)
« on: Thu, 22 September 2016, 09:00:20 »
Hello all,
I have been browsing for a few weeks looking for ideas and improvements for an idea I have.
I am looking to make a 60% keyboard with the ability for it to double as a large game pad. (Logitech g13/Razer orbweaver-ish)
148910-0

I have come up with a layout that I like as well as made sure the keycaps I need will be easily sourced. I plan on hard wiring everything to make it easier/cheaper.
My major issue I that I don't know what to use for a controller. My first thought was a teensy board, but after seeing Qaz's GUI mapper https://geekhack.org/index.php?topic=51252.0), I have shifted to an Arduino micro. Since the mapper/firmware works directly with the ATmega32U4.

Basically the "Game Mode" key will act similar to a standard Caps Lock key, but instead of letters as an input I want to use 'F' keys or something similar to map for gaming.

Any tips or advice would be greatly appreciated.
PS: I know I will need a plate for the custom board. I have a 3D printer and access to a desktop CNC mill for creating the plate and potentially making keycaps.


Mod Edit: Moved to MST and edited subject for clarity.
« Last Edit: Fri, 23 September 2016, 03:04:23 by infiniti »

Offline infiniti

  • I <3 KB
  • * Senior Moderator
  • Posts: 2405
  • Location: Thrilla, Manila, Philippines
  • Bob was here
    • PM me and ask for a custom title!
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #1 on: Fri, 23 September 2016, 03:06:22 »
Welcome to Geekhack!

I hope you don't mind but I've moved your post to the Making Stuff Together! sub-forum so that you have better visibility for your project.

Happy Keyboarding!

Offline Tactile

  • Posts: 1435
  • Location: Portland, OR
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #2 on: Fri, 23 September 2016, 08:41:55 »
Well, the Teensy 2.0, the one usually used in keyboards, is based on the ATmega32U4. It's also much more widely used by keyboard hobbyists  than the Arduino Micro  so it would be easier to find programming help & advice.
REΛLFORCE

Offline vextanys

  • Posts: 40
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #3 on: Fri, 23 September 2016, 10:05:06 »
With the Teensy and Pro Micro, you can quite easily make the "game mode" as a joystick (or almost any other HID device) or entirely different key map.
Joystick
* Pro: does not mess with keyboard input - can type in chat while gaming at the same time
* Con: Not all games support joystick input (FPS, RTS and MMOs are the biggest culprits here)
* Note: Earlier Windows versions had trouble with joysticks with no axes - you can just add 2 axes (x,y) which report centered permanently - it is possible to have up-to-128 buttons, though some games may only recognize 32 buttons
* Note: Pro Micro doesnt have a library for Joystick - not too hard to create one to your specs, or find one online

Keyboard Map
* Pro: can remap to F1-F24 and other alternate keys (look for the HID usage tables for the keyboard page 0x07)
* Con: there isnt enough "extra" non-printing/control keys to cover the board
* Note: TMK firmware (and possibly others, I havent checked) can do this as a layer, so its almost entirely done for you :)

Both Teensy and Pro Micro are ATMega32u4's, but the bootloaders are different - the Pro Micro will always have a serial port shown (great for debugging, but untidy when done - I think its possible to burn the bootloader when done, but I've only bricked ProMicro clones this way)

Having experimented with a similar idea, I found that having a standard-ish keyboard layout was easier, as I didnt have to remap the controls in all games to use it - so I have a 1/2 keyboard Orbweaver/G13 style game keyboard (layout was better suited to me, but it only has 1/2 the normal keys of a keyboard)

Offline zanzibar312

  • Thread Starter
  • Posts: 7
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #4 on: Fri, 23 September 2016, 10:10:16 »
Does the Teensy 2.0 have enough pins to do a keyboard similar to the Planck? 12x4 or possibly 12X5 matrix is what I will be looking at for my project.
I have looked into the teensy boards and the only reason I moved away from them was because the 3.2/3.1 no longer use the ATmega hardware, so I couldn't cheat and use a GUI firmware. I have little experience with coding and would love an alternative like the AVR GUI firmware option.


Offline Tactile

  • Posts: 1435
  • Location: Portland, OR
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #5 on: Fri, 23 September 2016, 10:51:52 »
Does the Teensy 2.0 have enough pins to do a keyboard similar to the Planck? 12x4 or possibly 12X5 matrix is what I will be looking at for my project.
I have looked into the teensy boards and the only reason I moved away from them was because the 3.2/3.1 no longer use the ATmega hardware, so I couldn't cheat and use a GUI firmware. I have little experience with coding and would love an alternative like the AVR GUI firmware option.

Maybe this will illustrate it better. Here's a PCB designed specifically for a Teensy 2.0 as a controller. Look up near the "HAN" in "Phantom".

149016-0 
« Last Edit: Fri, 23 September 2016, 10:56:15 by Tactile »
REΛLFORCE

Offline zanzibar312

  • Thread Starter
  • Posts: 7
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #6 on: Fri, 23 September 2016, 14:43:35 »
With the Teensy and Pro Micro, you can quite easily make the "game mode" as a joystick (or almost any other HID device) or entirely different key map.
Joystick
* Pro: does not mess with keyboard input - can type in chat while gaming at the same time
* Con: Not all games support joystick input (FPS, RTS and MMOs are the biggest culprits here)
* Note: Earlier Windows versions had trouble with joysticks with no axes - you can just add 2 axes (x,y) which report centered permanently - it is possible to have up-to-128 buttons, though some games may only recognize 32 buttons
* Note: Pro Micro doesnt have a library for Joystick - not too hard to create one to your specs, or find one online

Keyboard Map
* Pro: can remap to F1-F24 and other alternate keys (look for the HID usage tables for the keyboard page 0x07)
* Con: there isnt enough "extra" non-printing/control keys to cover the board
* Note: TMK firmware (and possibly others, I havent checked) can do this as a layer, so its almost entirely done for you :)

Both Teensy and Pro Micro are ATMega32u4's, but the bootloaders are different - the Pro Micro will always have a serial port shown (great for debugging, but untidy when done - I think its possible to burn the bootloader when done, but I've only bricked ProMicro clones this way)

Having experimented with a similar idea, I found that having a standard-ish keyboard layout was easier, as I didnt have to remap the controls in all games to use it - so I have a 1/2 keyboard Orbweaver/G13 style game keyboard (layout was better suited to me, but it only has 1/2 the normal keys of a keyboard)

I appreciate all the the help y'all have offered. I guess The pro's of a Teensy are significant enough to just use it as a my controller.
I think I will use the keyboard map, and just map the keys how ever. Most of my gaming is done in MMO's or RPG, most of which allow you to map keys to whatever you like, so I don't think I will need to cover the board in "extra" keys. I can simply have 2 "layers" utilizing a locking switch to active "game mode" or "typing mode".

Tactile:
Thank you for the visual. I am new to this, so I was worried about getting the Teensy 2.0 and running out of pin outs, but it seems you can run a 100% keyboard on it. So that will be more than enough to cover my needs. I just have to organize everything sensibly.

Offline vextanys

  • Posts: 40
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #7 on: Mon, 26 September 2016, 06:29:27 »
http://www.keyboard-layout-editor.com/##@@=%0AEsc&=%0A7&=%0A8&=%0A9&=%0A0&=%0A-&=%0A%2F=&=&=&=&=&=&=&=%3B&@=%0ATab&=%0A2&=%0A3&=%0AW&=%0A4&=%0A5&=%0AF&=&=%0AB&=%0AC&=%0AM&=%0AP&=&=%3B&@=%0AAlt&=%0A1&=%0AA&=%0AS&=%0AD&=%0A6&=%0AAlt&=&=%0AO&=%0AY&=&=&_w:2%3B&=%3B&@=%0AShift&=%0AF1&=%0AF2&=%0AF3&=%0AF4&=%0AF5&=%0AShift&=&=&=&=&=&=&=%0AGame%20Mode%3B&@=%0ACtrl&=&=&_w:6%3B&=%0ASpace&_w:2%3B&=&=&=&=

This would be my "Game Mode" layer (build for WoW mainly, cos that's what I can remember)
Easy access to F1-F5 (party targets), number row (hotbar), WASD (default movement) and Shift, Ctrl, Alt (for alternate hotbars/actions). Throw in some shortcuts for bags n stuff. With the bonus of not having to remap in game.

Offline zanzibar312

  • Thread Starter
  • Posts: 7
Re: Hello (and assistance needed with custom 60% keyboard)
« Reply #8 on: Mon, 26 September 2016, 14:23:26 »
I like what you did there, but I prefer to have MANY more hotkeys for spells/abilities at my fingers. (without using modifiers) I am currently using a Logitech G13, and I have grown tired of it. It is old and slow and the membrane keyboards are not as responsive.
I believe I have decided what my layouts will be.

This would be for everyday typing with the "game mode" button accessing a separate layer similar to a FN key, but it will toggle the layer on or off. (so more like caps lock.)
&_a:7&h:2%3B&=ENTER%3B&@=CAPS%20LOCK&=A&=S&=D&=F&=G&=H&=J&=K&=L&_a:5%3B&=%22%0A%0A%0A%0A%0A%0A%27&_a:7%3B&=&=UP%3B&@=SHIFT&=Z&=X&=C&=V&_w:2%3B&=SPACE&=B&=N&=M&_a:5%3B&=.%0A%0A%0A%0A%0A%0A,&_a:7%3B&=LEFT&=DOWN&=RIGHT]http://www.keyboard-layout-editor.com/##@@_a:7%3B&=F1&=F2&=F3&=F4&=F5&=F6&=F7&=F8&=F9&=F10&=F11&=F12&_w:2%3B&=BACKSPACE%3B&@_a:5%3B&=~%0A%0A%0A%0A%0A%0A%60&_a:7%3B&=1&=2&=3&=4&=5&=6&=7&=8&=9&=0&_a:5%3B&=%2F_%0A%0A%0A%0A%0A%0A-&=+%0A%0A%0A%0A%0A%0A%2F=&_a:7%3B&=GAME%20MODE%3B&@=TAB&=Q&=W&=E&=R&=T&=Y&=U&=I&=O&=P&_a:5%3B&={%0A%0A%0A%0A%0A%0A[&=}%0A%0A%0A%0A%0A%0A]&_a:7&h:2%3B&=ENTER%3B&@=CAPS%20LOCK&=A&=S&=D&=F&=G&=H&=J&=K&=L&_a:5%3B&=%22%0A%0A%0A%0A%0A%0A%27&_a:7%3B&=&=UP%3B&@=SHIFT&=Z&=X&=C&=V&_w:2%3B&=SPACE&=B&=N&=M&_a:5%3B&=.%0A%0A%0A%0A%0A%0A,&_a:7%3B&=LEFT&=DOWN&=RIGHT

This would be while gaming. With a separate LED backlighting tied to it.
&_a:7&h:2%3B&=ENTER%3B&@=CAPS%20LOCK&=A&=S&=D&=F&=G&=H&=J&=K&=L&_a:5%3B&=%22%0A%0A%0A%0A%0A%0A%27&_a:7%3B&=&=UP%3B&@=SHIFT&=Z&=X&=C&=V&_w:2%3B&=SPACE&=B&=N&=M&_a:5%3B&=.%0A%0A%0A%0A%0A%0A,&_a:7%3B&=LEFT&=DOWN&=RIGHT]http://www.keyboard-layout-editor.com/##@@_a:7%3B&=F1&=F2&=F3&=F4&=F5&=F6&=F7&=F8&=F9&=F10&=F11&=F12&_w:2%3B&=BACKSPACE%3B&@_a:5%3B&=~%0A%0A%0A%0A%0A%0A%60&_a:7%3B&=1&=2&=3&=4&=5&=6&=7&=8&=9&=0&_a:5%3B&=%2F_%0A%0A%0A%0A%0A%0A-&=+%0A%0A%0A%0A%0A%0A%2F=&_a:7%3B&=GAME%20MODE%3B&@=TAB&=Q&=W&=E&=R&=T&=Y&=U&=I&=O&=P&_a:5%3B&={%0A%0A%0A%0A%0A%0A[&=}%0A%0A%0A%0A%0A%0A]&_a:7&h:2%3B&=ENTER%3B&@=CAPS%20LOCK&=A&=S&=D&=F&=G&=H&=J&=K&=L&_a:5%3B&=%22%0A%0A%0A%0A%0A%0A%27&_a:7%3B&=&=UP%3B&@=SHIFT&=Z&=X&=C&=V&_w:2%3B&=SPACE&=B&=N&=M&_a:5%3B&=.%0A%0A%0A%0A%0A%0A,&_a:7%3B&=LEFT&=DOWN&=RIGHT

I believe this will work. I have toyed around with Metalliqaz's Easy AVR USB keyboard firmware. And noticed the "M1-M12" keys.
Now I just have to edit the Planck layout to match my layout, and start mapping.