Author Topic: First project: Isn't quite a keyboard  (Read 7548 times)

0 Members and 1 Guest are viewing this topic.

Offline c1223

  • Thread Starter
  • Posts: 13
First project: Isn't quite a keyboard
« on: Wed, 28 December 2016, 14:36:07 »
I'm building a controller for a particular application (QLab) that I use at work. It will have 5 keys which will interface with this application via USB MIDI. As the application is run on two computers at the same time, each key will be connected to two Teensy 3.2s which will each be connected to a computer. That means I'll be able to fire both applications in sync (as a redundant system).

At this stage I'm designing the PCB that I'm going to be used. The next step will most likely be designing the frame etc... I'm most likely going to get a metal enclosure made I think. It all depends on the price. However, this is where I need your help. I'm a complete newbie when it comes to all of the mech keyboard terminology.

  • I want to include RGB LEDs under each of the keys, so I'm looking to get the Gateron RGB switches (which I believe are milky white). As I understand, the general size and pin locations are basically a copy of the Cherry MX switches. As I understand, there are four different mounting types:



    Is there any reason not to use the first (i.e. square)? What are the others for?
  • I want one of the keys to be larger (think like the backspace or right shift key). What size should the frame mount hole be? Will I need stabilisers (how do they work?) and will this affect the PCB layout?

I think that's all for now. I'm trying to draw a design at the moment, so will return with that which hopefully will be more helpful.

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #1 on: Wed, 28 December 2016, 16:12:56 »
Is there any reason not to use the first (i.e. square)? What are the others for?
The three other cutouts allow the switch top to be removed, that way, you can easily change springs or stems.

I want one of the keys to be larger (think like the backspace or right shift key). What size should the frame mount hole be? Will I need stabilisers (how do they work?) and will this affect the PCB layout?[/li][/list]
You need stabilizers for any keys wider than 1.75u. The backspace is 2u (twice as wide as regular keycap) and therefore requires a stabilizer. The right shift is 2.75u. While you could probably use a 2u keycap without a stabilizer, the right shift would be quite annoying to press without one.

To make your own custom plate, go to the keyboard layout editor, configure your layout and copy the output in the raw data tab. Then go to swill's builder, paste the raw data in the plate layout field, choose your switch cutout and click draw my CAD!!!.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #2 on: Thu, 29 December 2016, 10:55:14 »
Thanks for the great resource!

I don't want the keys to sit so high so my plan is to put a piece of metal that surrounds all the keys. As I understand, the standard 1U keycaps are 0.750", or 19.05mm square. How much space should I leave between the keycap and this other metal plate?

Thanks

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #3 on: Thu, 29 December 2016, 11:02:31 »
So basically you don't want floating keys but, rather, a border around the keys. You got it right with the measures and, since the keycaps are wider on the bottom side, you just need a hole larger than that. It's a matter of personal preference, I can suggest you to print on paper various squares of different areas, sit a keycap in the middle of them and choose the one you like the most.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #4 on: Thu, 29 December 2016, 11:45:36 »
OK great thanks. Will have a look at my options. Here's the design as it stands if you're interested:



Offline xondat

  • i'm not a star
  • * Maker
  • Posts: 5366
  • Location: United Kingdom
Re: First project: Isn't quite a keyboard
« Reply #5 on: Thu, 29 December 2016, 11:57:13 »


Green is 3mm, blue is 7mm





Hopefully that helps

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #6 on: Thu, 29 December 2016, 12:59:14 »
OK great thanks. Will have a look at my options. Here's the design as it stands if you're interested:


Show Image

Looking forward to see more.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #7 on: Fri, 30 December 2016, 11:07:51 »
Thanks for those images - very helpful.

Next question - for the 2U key, what stabiliser should I be looking at? Is there a PCB mount and plate mount version? If I'm going to have a plate and a PCB which should I get?


Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #8 on: Fri, 30 December 2016, 13:50:18 »
Next question - for the 2U key, what stabiliser should I be looking at? Is there a PCB mount and plate mount version? If I'm going to have a plate and a PCB which should I get?
Cherry makes either plate and PCB mounted stabilizers. Costar makes plate mounted stabilizers alone.
You could use any as long as your plate supports the related cutout, swill's builder will do that for you.

Here's some pictures.

Cherry PCB mounted stabilizers.


Cherry plate mounted stabilizer.


Costar stabilizers.



Alternatively. You can discard your 2u keycaps and go for 1.75u which wouldn't need any stabilizer.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #9 on: Fri, 30 December 2016, 19:53:53 »
OK great. I'll probably get the panel mount ones. I'll probably have to double check the spacing for the components on the PCB around the 2U key.


Offline Findecanor

  • Posts: 5036
  • Location: Koriko
Re: First project: Isn't quite a keyboard
« Reply #10 on: Fri, 30 December 2016, 20:24:00 »
The stabilisers can be a bit tricky. Even the plate-mounted stabilisers protrude a bit under the plate and can interfere with components on the PCB.

With Costar-style stabilisers the wire has to be on the side of the LED cutout in the switch. The Costar stabilisers do not sit in holes centred on the center-line with the switch but slightly offset from it. That offset has to be towards the side where the LED goes.

With Cherry-style plate-mounted stabilisers, the wire is practically on the PCB. So there can't be anything on the PCB around the switch and a little bit to the sides. The switch orientation does not matter, though.

BTW, that PCB of yours has quite a few components on it. Are you doing debouncing in hardware?
Most of us do it in firmware on the microcontroller: One simple way to do it is to scan the matrix every millisecond and wait for a signal that is stable for at least five milliseconds (five samples) - but you could use a longer debouncing time.

I don't want the keys to sit so high so my plan is to put a piece of metal that surrounds all the keys. As I understand, the standard 1U keycaps are 0.750", or 19.05mm square. How much space should I leave between the keycap and this other metal plate?
When I have built keyboard cases, I have used the rule of thumb: (19.05 - width of keycap) / 2.
With most keycaps being 18 mm wide, that yields about 1/2 mm of spacing around each group of keys.
That should provide the same spacing between border and keycap as between keycap and keycap.

However, I have made my keyboard cases by hand and adjusted things along the way...
« Last Edit: Fri, 30 December 2016, 20:42:23 by Findecanor »

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #11 on: Sat, 31 December 2016, 03:32:00 »
If you're going for Cherry PCB mounted stabilizers then you need to predispose holes for them to be installed.
Diameters are shown in the following image, note that they are expressed in inches.
156528-0
The A distance for a 2u stabilizer is 23.88 mm (0.94'')
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #12 on: Sun, 01 January 2017, 14:23:53 »
Thanks for the great replies.

I have room on the PCB to move the components, so I could leave the appropriate space for the single 2U key. I'll have a look around and see what keycaps available, but as you say, 1.75U might be a lot easier as I don't need the stabiliser.

The components on the PCB are mainly WS2811 chips which control RGB LEDs along with one buffer for logic level conversion. The diodes are all there because the keys will be connected to two different Teensys, so there needs to be protection. There will be debouncing done on the Teensy as well.


Offline kolec94

  • Posts: 111
Re: First project: Isn't quite a keyboard
« Reply #13 on: Sun, 01 January 2017, 16:07:10 »
Thanks for the great replies.

I have room on the PCB to move the components, so I could leave the appropriate space for the single 2U key. I'll have a look around and see what keycaps available, but as you say, 1.75U might be a lot easier as I don't need the stabiliser.

The components on the PCB are mainly WS2811 chips which control RGB LEDs along with one buffer for logic level conversion. The diodes are all there because the keys will be connected to two different Teensys, so there needs to be protection. There will be debouncing done on the Teensy as well.
why not ws2812b's and why 2 teensy's
« Last Edit: Sun, 01 January 2017, 16:10:43 by kolec94 »

kbparadise v60 blues

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #14 on: Sun, 01 January 2017, 16:09:35 »
I would recommend a shorter key because stabilizers are evil, they need a lot of space around the switch. I couldn't measure, but I think there's risk a stabilizer's NPTHs would overlap the Teensies' PTHs.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #15 on: Sun, 01 January 2017, 17:21:58 »
I'm not entirely sure if the WS2812Bs fit under the Gateron RGB switches? I've got a few sitting around anyway, so I'll get the switches and have a look.

I've actually now moved the Teensys, and they're mounted underneath the circuit board anyway.



The reason for two is that I need to connect these keys to two computers at the same time. As far as I'm aware, that isn't possible with just the one Teensy.

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #16 on: Mon, 02 January 2017, 03:45:00 »
I'm not entirely sure if the WS2812Bs fit under the Gateron RGB switches?
New batches of Gateron KS-3 (Cherry MX clones) support SMD LEDs, you can tell by the presence of a linear slot on the bottom side of the switch. Although, those slots are made for linear/rectangular LEDs. I'm not sure WS2812Bs would fit since they are square.

I've actually now moved the Teensys, and they're mounted underneath the circuit board anyway.
Is there any particular reason you're using Teensies 3.2? Do they have any feature that you're gonna use? I'm asking out of curiosity.

The reason for two is that I need to connect these keys to two computers at the same time. As far as I'm aware, that isn't possible with just the one Teensy.
I believe so, but you'd ask the gentlemen in the Living PCB Design thread. They would know better.

My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #17 on: Mon, 02 January 2017, 05:54:14 »
Is there any particular reason you're using Teensies 3.2? Do they have any feature that you're gonna use? I'm asking out of curiosity.

The Teensy 3.2 supports interrupts on any digital pin, however the 2.0 only supports 4 interrupts. It's more efficient and reliable to use interrupts rather than polling to monitor for key presses. I know the 3.2 is slightly more expensive, but the price difference isn't so much of a worry.

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #18 on: Wed, 11 January 2017, 05:38:46 »
My Gateron Red with the hole for an SMD LED have arrived. Glad that I didn't use the WS2811B LED as they don't fit underneath the switch.

The PCB design has also been sent off to Dirty PCBs to be made.




Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #19 on: Wed, 11 January 2017, 05:44:15 »
The PCB design has also been sent off to Dirty PCBs to be made.
Do show us when you get it.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #20 on: Mon, 16 January 2017, 07:38:38 »
PCBs have arrived from China.

Top:



Bottom:



As DirtyPCBs offer forwarding from Taobao I decided to get some more switches as they are about US$1 for 8. The Gateron ones I ordered appear to be the wrong ones, but the Cherry ones seems to be right. Not sure whether they're actual Cherry switches, but they seem to have the same mould as the actual RGB ones.





You can see the slot for the SMD LED is a lot smaller.

Lasergist posted my order today, so hopefully that should be here within the next week.

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #21 on: Mon, 16 January 2017, 07:42:48 »
Nice looking PCB.
About the switches, I guess they are an old batch of Gateron KS-3. They support in-switch LEDs though.
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #22 on: Mon, 16 January 2017, 08:05:15 »
Actually just managed to have a chat with the Taobao seller in China. It was mainly a conversation in pictures. He accidentally sent the wrong ones, so we'll see if I get the right ones shipped over. Not too bothered as I have the Cherry ones and also the other Gaterons I ordered before.

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #23 on: Fri, 20 January 2017, 07:49:42 »
A metallic gift from Greece has just arrived....







Time to solder some components on to the board I think.

Offline TalkingTree

  • Posts: 2452
  • Location: Italy (142)
    • My projects
Re: First project: Isn't quite a keyboard
« Reply #24 on: Fri, 20 January 2017, 07:52:09 »
Really polished result. Would you mind me asking who did the laser cut job?
My opensource projects: GH80-3000, TOAD, XMMX. Classified: stuff

Offline c1223

  • Thread Starter
  • Posts: 13
Re: First project: Isn't quite a keyboard
« Reply #25 on: Fri, 20 January 2017, 08:00:39 »
It was Lasergist. Shipping to the UK took 4 days!

Offline Dmytro_Mukhorin

  • Posts: 2
  • Location: Ukraine
Re: First project: Isn't quite a keyboard
« Reply #26 on: Thu, 17 February 2022, 11:04:17 »
Great work! Tell me please, wich program had you used for design your project?
« Last Edit: Thu, 17 February 2022, 11:06:03 by Dmytro_Mukhorin »