Author Topic: Pressure sensitive switches  (Read 9750 times)

0 Members and 1 Guest are viewing this topic.

Offline veclock

  • Thread Starter
  • Posts: 4
Pressure sensitive switches
« on: Tue, 09 February 2016, 10:58:16 »
Hey! I'm planning to build a keyboard instrument, and was going to use Cherry MX switches.
I was thinking about modding them to be velocity sensitive. I've seen some examples using a smaller button underneath, which is triggered
by the Cherry switch.

But, the best solution for my purpose would be to have an analog switch. I've come across Topre keyboards, but I haven't found any separate keys to buy. It's very easy to find separate cherry switches.

I'd like to ask you if you know what keys I could use? I also need to make my own keycaps, but that shouldn't be a problem. The keycaps would be around 2-3 cm wide, hexagonal. Cherry switches are small enough for this purpose, but they can only sense on/off, or in best case, velocity sensing with some modification. Is there any equivalent switch that is also fully analog / pressure sensitive?

Thanks in advance! :)

Offline FrostyToast

  • Litshoard
  • * Exquisite Elder
  • Posts: 2368
  • Location: Canada
Re: Pressure sensitive switches
« Reply #1 on: Tue, 09 February 2016, 11:08:11 »
Topre switches have an entirely different construction than cherry switches and cannot be put in custom keyboards unless you do a lot of work. Topre switches are quite delicate things and are partially reliant on how they are mounted and attached to the keyboard to work.
Because of the use of capacitance to detect a keystroke you would need insanely good tolerances to ensure they work properly. Additionally, the force curve of topre isn't very suitable for analog due to the bump.
I have seen an analog cherry mod done once but it's a lot of effort.
Here is a video on this exact mod you want to do with cherry my blacks. Actually, I don't think that video has ever been posted here... Odd since it's such a genius mod.
Quote from: elton5354
I don't need anymore keyboards


Offline qwack

  • Posts: 310
  • Location: ISO FR
Re: Pressure sensitive switches
« Reply #3 on: Wed, 10 February 2016, 10:08:03 »
Integrating Hall effect sensors can work, but:

1. that's gonna be expensive
2. you'll need to be sure that everything is properly calibrated in software

I only used four analog keys on my numpad experiment (I'm Matt_ on DT, second link in jacobolus' post). That was fun, but I am not sure that this is the best solution for your project if you want a large number of pressure-sensitive keys.

Pure Pro w/MX Red - [review]

Offline Bromono

  • Wanabe Cicerone
  • * Destiny Supporter
  • Posts: 1115
  • Location: The Alamo's Basement
  • HHKB > Your Opinion
« Last Edit: Wed, 10 February 2016, 11:32:53 by Bromono »

Offline Findecanor

  • Posts: 5038
  • Location: Koriko
Re: Pressure sensitive switches
« Reply #5 on: Wed, 10 February 2016, 12:16:49 »
Do the keys have to be pressed straight down?
The way digital claviers work is that each key is on a lever. There are two switches underneath - one closer to the lever and one further away. This means that in each stroke the switch closest to the lever will be pressed first. The velocity of the stroke is calculated from the time difference between the two actuations.

Perhaps you could cut off the bottom "knob" on a Cherry MX switch. The bottom of the slider goes there. Then mount another switch underneath that that the slider would push on. There would be two springs... so you would want to use very light ones.
🍉

Offline jacobolus

  • Posts: 3661
  • Location: San Francisco, CA
Re: Pressure sensitive switches
« Reply #6 on: Wed, 10 February 2016, 12:31:56 »
[Side note: It’s funny and kind of cute to use the French word clavier to disambiguate instead of something like musical keyboard, here on a site focused on computer keyboards. Probably a bit obscure though; lots of folks have no idea what clavier means.]

I find music keyboards aren’t all that effective at pressure/velocity sensing, compared to what’s theoretically possible. It’s too bad there aren’t more people building musical instruments out of hall effect or similar sensors and linear computer-keyboard type switches.

Offline veclock

  • Thread Starter
  • Posts: 4
Re: Pressure sensitive switches
« Reply #7 on: Wed, 10 February 2016, 14:28:21 »
http://www.pcwaishe.cn/article-14568-16.html

https://deskthority.net/workshop-f7/analog-numpad-with-hall-effect-sensors-t11191.html

http://technabob.com/blog/2012/11/26/analog-wasd-keyboard-mod/

First one seems very insteresting. Wonder if there are any videos of it in action, and also if there's any shops that sells them.

Integrating Hall effect sensors can work, but:

1. that's gonna be expensive
2. you'll need to be sure that everything is properly calibrated in software

I only used four analog keys on my numpad experiment (I'm Matt_ on DT, second link in jacobolus' post). That was fun, but I am not sure that this is the best solution for your project if you want a large number of pressure-sensitive keys.

Yes, Hall effect can work. What about capacitive switches?

1. Yes, but it might be worth it as long as it's below 1500 USD.
2. Yes, either I write my own software and hand calibrate everything brute force style, or I find a switch with built in pressure sensing,
so that all switches will be the same, and also so I don't have to make the mod myself.

The keys will be packed together in a grid. Wonder if the magnets in the Hall effect switch will affect each other?

Yes, I understand that four keys was easy to make. I'm going to have 310 keys in a grid. :D

https://m.reddit.com/r/MechanicalKeyboards/comments/38ohm1/computex_2015_topre_shows_off_realforce_prototype/

http://techreport.com/news/28415/topre-latest-keyboards-are-colorful-sensitive-to-pressure

Dunno if analog though?

Yes, these would be ideal, but doesn't seem like I can buy separate Topre keys? And it has been stated that these are very hard to implement in a DIY keyboard... :/

Do the keys have to be pressed straight down?
The way digital claviers work is that each key is on a lever. There are two switches underneath - one closer to the lever and one further away. This means that in each stroke the switch closest to the lever will be pressed first. The velocity of the stroke is calculated from the time difference between the two actuations.

Perhaps you could cut off the bottom "knob" on a Cherry MX switch. The bottom of the slider goes there. Then mount another switch underneath that that the slider would push on. There would be two springs... so you would want to use very light ones.

Yes, they will be pressed straight down, since they are arranged in a grid and not on a row. I've seen an example with this kind of velocity sensing, they used a small tactile switch underneath the Cherry.
But they also created their own PCBs and stuff. They used two layers of PCBs. Seems pretty hard since I don't know anything about electronics (yet).

I might use their approach, but I want to investigate pressure sensitivity since they would allow for more sound effects like after touch and such. Velocity sensing is better than nothing though, if pressure sensitivity turns out to be too hard. But I think I've come to the right place for my questions. :)

Offline Pinkachu

  • Posts: 20
  • Location: Philadelphia
Re: Pressure sensitive switches
« Reply #8 on: Wed, 10 February 2016, 15:57:26 »
[Side note: It’s funny and kind of cute to use the French word clavier to disambiguate instead of something like musical keyboard, here on a site focused on computer keyboards. Probably a bit obscure though; lots of folks have no idea what clavier means.]

I find music keyboards aren’t all that effective at pressure/velocity sensing, compared to what’s theoretically possible. It’s too bad there aren't more people building musical instruments out of hall effect or similar sensors and linear computer-keyboard type switches.

actually, loads of r&d has gone into clavier technology over the past few years and there are some that are taking MIDI to further bit levels to get more than 128 levels of velocity and some keyboards that are taking advantage of this advanced protocol. The mechanisms are large enough to *not* put them in a typing keyboard, but the technology exists - and depending on what your intended application was in the end, this is a possible way to look at it - clever thinking!

Offline Findecanor

  • Posts: 5038
  • Location: Koriko
Re: Pressure sensitive switches
« Reply #9 on: Wed, 10 February 2016, 16:42:03 »
Anyway, because you are making your own relatively large keycaps then maybe velocity sensing could be done with having two switches side by side under the key. I think that only one switch could be mounted properly though because of between stem and slider when mounting the keycap.
The second stem would be offset in height and hammered by the keycap instead of guided. Alternatively, one of the switches would be topless (parts exposed) to allow the stem to be mounted under the keycap before you press the keycap onto the other switch.
My first thought though was to use two Cherry MX-compatible switches of different manufacture with different actuation points but I am unsure about the differences being big enough for accurate sensing.

But yes, pressure sensing would be nicer.
At CeBit last year, a Taiwanese company called Adomax showed off prototypes of their own analogue optical "Flaretech" switch but I have not heard anything about it since then. It requires surface-mounted optical components.
If it had been available to buy, it might have been suitable for your project.
« Last Edit: Wed, 10 February 2016, 16:45:57 by Findecanor »
🍉

Offline jacobolus

  • Posts: 3661
  • Location: San Francisco, CA
Re: Pressure sensitive switches
« Reply #10 on: Wed, 10 February 2016, 17:10:49 »
actually, loads of r&d has gone into clavier technology over the past few years and there are some that are taking MIDI to further bit levels to get more than 128 levels of velocity and some keyboards that are taking advantage of this advanced protocol. The mechanisms are large enough to *not* put them in a typing keyboard, but the technology exists
Link?

I only know about the music keyboards I’ve seen, which are all >10 year old designs, or the couple dozen 10–30 year old patents I skimmed one time.

Offline crickclackman

  • Posts: 44
Re: Pressure sensitive switches
« Reply #11 on: Wed, 10 February 2016, 17:50:01 »
http://www.pcwaishe.cn/article-14568-16.html

https://deskthority.net/workshop-f7/analog-numpad-with-hall-effect-sensors-t11191.html

http://technabob.com/blog/2012/11/26/analog-wasd-keyboard-mod/

First one seems very insteresting. Wonder if there are any videos of it in action, and also if there's any shops that sells them.

Integrating Hall effect sensors can work, but:

1. that's gonna be expensive
2. you'll need to be sure that everything is properly calibrated in software

I only used four analog keys on my numpad experiment (I'm Matt_ on DT, second link in jacobolus' post). That was fun, but I am not sure that this is the best solution for your project if you want a large number of pressure-sensitive keys.

Yes, Hall effect can work. What about capacitive switches?

1. Yes, but it might be worth it as long as it's below 1500 USD.
2. Yes, either I write my own software and hand calibrate everything brute force style, or I find a switch with built in pressure sensing,
so that all switches will be the same, and also so I don't have to make the mod myself.

The keys will be packed together in a grid. Wonder if the magnets in the Hall effect switch will affect each other?

Yes, I understand that four keys was easy to make. I'm going to have 310 keys in a grid. :D

https://m.reddit.com/r/MechanicalKeyboards/comments/38ohm1/computex_2015_topre_shows_off_realforce_prototype/

http://techreport.com/news/28415/topre-latest-keyboards-are-colorful-sensitive-to-pressure

Dunno if analog though?

Yes, these would be ideal, but doesn't seem like I can buy separate Topre keys? And it has been stated that these are very hard to implement in a DIY keyboard... :/

Do the keys have to be pressed straight down?
The way digital claviers work is that each key is on a lever. There are two switches underneath - one closer to the lever and one further away. This means that in each stroke the switch closest to the lever will be pressed first. The velocity of the stroke is calculated from the time difference between the two actuations.

Perhaps you could cut off the bottom "knob" on a Cherry MX switch. The bottom of the slider goes there. Then mount another switch underneath that that the slider would push on. There would be two springs... so you would want to use very light ones.

Yes, they will be pressed straight down, since they are arranged in a grid and not on a row. I've seen an example with this kind of velocity sensing, they used a small tactile switch underneath the Cherry.
But they also created their own PCBs and stuff. They used two layers of PCBs. Seems pretty hard since I don't know anything about electronics (yet).

I might use their approach, but I want to investigate pressure sensitivity since they would allow for more sound effects like after touch and such. Velocity sensing is better than nothing though, if pressure sensitivity turns out to be too hard. But I think I've come to the right place for my questions. :)

I think the first one is just a prototype.

Offline jacobolus

  • Posts: 3661
  • Location: San Francisco, CA
Re: Pressure sensitive switches
« Reply #12 on: Wed, 10 February 2016, 17:53:38 »
I think the first one is just a prototype.
I have no idea what you’re responding to. You quoted a message which was made up of like 5 separate responses. Would you mind editing your post to quote more selectively?

Offline Pinkachu

  • Posts: 20
  • Location: Philadelphia
Re: Pressure sensitive switches
« Reply #13 on: Wed, 10 February 2016, 20:20:45 »
I only know about the music keyboards I’ve seen, which are all >10 year old designs, or the couple dozen 10–30 year old patents I skimmed one time.

http://support.casio.com/storage/en/manual/pdf/EN/008/PX5_midi_EN.pdf

P15 at the bottom

I don't know what mechanism they are using (other than that they are using 3 sensors per key) and I don't know how to look up patents, but if you're familiar with that sort of thing, check out whatever these guys are using. Instead of values 0-127, it can put out values from 0-16,255

Not analog, but pretty darn close when those values are within 1" travel or whatever it is...

Offline jacobolus

  • Posts: 3661
  • Location: San Francisco, CA
Re: Pressure sensitive switches
« Reply #14 on: Wed, 10 February 2016, 20:27:55 »
That just tells you velocity at a single fixed position in the stroke though.

That’s great if you want to implement the same behavior as a piano. A switch which could read out the precise position at a relatively high cycle frequency could potentially let you do a lot more though.

Offline Pinkachu

  • Posts: 20
  • Location: Philadelphia
Re: Pressure sensitive switches
« Reply #15 on: Wed, 10 February 2016, 20:52:35 »
That just tells you velocity at a single fixed position in the stroke though.

That’s great if you want to implement the same behavior as a piano. A switch which could read out the precise position at a relatively high cycle frequency could potentially let you do a lot more though.

oh, I see what you're saying. Like if you had a typewriter but instead of the arm swinging a letter at the page, it pulled a potentiometer around it's axis so you could get a sweep throughout the stroke of the key? I don't see how this would be possible in a small device unless it's optical. Optical seems to be the way to go here. They aren't 100% precise but they can get pretty darn close without being terribly expensive. That woudl be a cool keyswitch type instead of mechanical (and whether we like to admit it or not, membrane keys are mechanical in nature...) Instead of a contact closing a circuit, you could have a threshold (editable?) that when the key gets to a certain distance (optically) then it actuates. It would also make the actuation/reset points exactly in the same spot...

That's a bit off topic and tangential, but a cool idea... has anyone had this idea already? (I often invent things that already exist...)

Offline jacobolus

  • Posts: 3661
  • Location: San Francisco, CA
Re: Pressure sensitive switches
« Reply #16 on: Wed, 10 February 2016, 23:45:02 »
Could be optical, hall effect sensor + magnet, capacitive sensing with a piece of metal (this is how Topre switches work; also IBM model F but with those the flipper feet don’t move continuously through the stroke), force sensor under a spring, ...
« Last Edit: Wed, 10 February 2016, 23:47:38 by jacobolus »

Offline veclock

  • Thread Starter
  • Posts: 4
Re: Pressure sensitive switches
« Reply #17 on: Thu, 11 February 2016, 06:54:12 »
Anyway, because you are making your own relatively large keycaps then maybe velocity sensing could be done with having two switches side by side under the key. I think that only one switch could be mounted properly though because of between stem and slider when mounting the keycap.
The second stem would be offset in height and hammered by the keycap instead of guided. Alternatively, one of the switches would be topless (parts exposed) to allow the stem to be mounted under the keycap before you press the keycap onto the other switch.
My first thought though was to use two Cherry MX-compatible switches of different manufacture with different actuation points but I am unsure about the differences being big enough for accurate sensing.

But yes, pressure sensing would be nicer.
At CeBit last year, a Taiwanese company called Adomax showed off prototypes of their own analogue optical "Flaretech" switch but I have not heard anything about it since then. It requires surface-mounted optical components.
If it had been available to buy, it might have been suitable for your project.

Flaretech sounds very insteresting! From what I can find on Google, it has analog output. Which is exactly what I need. But there isn't much info to be found, I'm not sure these can be bought separately... :/

Could be optical, hall effect sensor + magnet, capacitive sensing with a piece of metal (this is how Topre switches work; also IBM model F but with those the flipper feet don’t move continuously through the stroke), force sensor under a spring, ...

Yes, these are the options. Question is which of these options do exist as a ready to buy switch, which I can place a keycap on and hook up to an Arduino or similar.

I've seen some DIY force sensor: http://www.instructables.com/id/How-to-Make-a-Ridiculously-Cheap-Analog-Pressure-S/ But I can imagine this would require alot of calibration, which could cause various problems. Best case scenario is to find manufactured components.

There are of course force sensors ready to be bought, but then I have to hook them up with a switch that feels nice to press. If I go for keyboard switches I know what they will feel like, and I know they will not break very easily.

I'm interested in the capacitive option too, haven't read much about it yet..

Thanks for all the answers and keep posting! :)

Offline HaaTa

  • Master Kiibohd Hunter
  • Posts: 794
  • Location: San Jose, CA, USA
  • Kiibohds!
    • http://kiibohd.com
Re: Pressure sensitive switches
« Reply #18 on: Fri, 12 February 2016, 18:13:44 »
Afaik, no they do not. Velocity sensors would likely be the easiest to find. And in terms of keyboard-like switches, I haven't really seen anything recently (other than vaporware).

Personally, I may start doing some research into the capacitive side for my own stuff as it's the easiest to get the cost down. Fun fact, I designed KLL around analog switches for whenever someone came out (or I had to build one myself).

Another option might be to start with a simple touch screen/surface and see if you can get 3d positioning out of it. One of the problems with this however is the refresh rate/polling of multiple locations. But this is a problem for any switch you choose. The more locations you have to sense from, the longer it takes to process every single position (do any noise/debounce cleaning and act on that data).


If you just need velocity, then this is easier. You just need two different thresholds to look for (might even be able to program a hardware comparator for this). For example, have two separate touch panels with different detection heights and then correlate them. As long as the panels support some sort of multi-touch this would be the easiest way to do what you want. Then you can just put whatever switch you want on top and stick some sort of dielectric thing to trigger the cap sense on the touch screens.

Hope this helps. Feel free to PM me (or find me on IRC) if you want.
Kiibohd

ALWAYS looking for cool and interesting switches
I take requests for making keyboard converters (i.e. *old keyboard* to USB).

Offline veclock

  • Thread Starter
  • Posts: 4
Re: Pressure sensitive switches
« Reply #19 on: Fri, 19 February 2016, 03:43:29 »
Afaik, no they do not. Velocity sensors would likely be the easiest to find. And in terms of keyboard-like switches, I haven't really seen anything recently (other than vaporware).

Personally, I may start doing some research into the capacitive side for my own stuff as it's the easiest to get the cost down. Fun fact, I designed KLL around analog switches for whenever someone came out (or I had to build one myself).

Another option might be to start with a simple touch screen/surface and see if you can get 3d positioning out of it. One of the problems with this however is the refresh rate/polling of multiple locations. But this is a problem for any switch you choose. The more locations you have to sense from, the longer it takes to process every single position (do any noise/debounce cleaning and act on that data).


If you just need velocity, then this is easier. You just need two different thresholds to look for (might even be able to program a hardware comparator for this). For example, have two separate touch panels with different detection heights and then correlate them. As long as the panels support some sort of multi-touch this would be the easiest way to do what you want. Then you can just put whatever switch you want on top and stick some sort of dielectric thing to trigger the cap sense on the touch screens.

Hope this helps. Feel free to PM me (or find me on IRC) if you want.

Hi HaaTa!

Have you begun researching capacitive stuff yet? :)

I found two kickstarter projects that can be helpful for me, but it depends on how expensive they are and when they are going to be released...

First one is this, and it touches on your suggestion to get a 3D positioning out of a touch surface. https://www.kickstarter.com/projects/1152958674/the-sensel-morph-interaction-evolved/description

If I can get one of these that are really big, like 70 cm wide, then I'd be able to make some kind of silicone layer with 3D buttons that I place on top of it. This would be the coolest solution, because then I'd be able to get not only pressure sensitivity but also other effects like vibrato.

The other one I found is this one: https://www.kickstarter.com/projects/chrisgerding/analog-pushbutton-for-makers-and-creative-control/description
An analog arcade button, which gives analog input. This would be better than a velocity sensitive button, however I don't like the "click" that the button makes, you can clearly hear it in the video. Also I'd have to modify the shape of the button, so I'd most likely only use the sensor. Perhaps it would be possible to use Cherry buttons with custom key caps along with these sensors?

I really hope these products will be available soon, I'm going to read up on it now.
Actually, I'm very surprised that analog push buttons are so hard to find.

Offline Findecanor

  • Posts: 5038
  • Location: Koriko
Re: Pressure sensitive switches
« Reply #20 on: Fri, 19 February 2016, 05:42:18 »
There are of course force sensors ready to be bought, but then I have to hook them up with a switch that feels nice to press.
Yep. I heard of force-sensitive resistors on another forum yesterday.
You would mount each one on a circuit board with a spring on top. Then as the spring is pressed, the pressure both up and down would increase.
There are some older, cheaper key switches that work that way but with membranes. The so called "Amstrad switch" is one example. Otherwise, they can be found mostly in electronic typewriters and not in computer keyboards.
I have also never seen one that is a discrete component.
🍉

Offline HaaTa

  • Master Kiibohd Hunter
  • Posts: 794
  • Location: San Jose, CA, USA
  • Kiibohds!
    • http://kiibohd.com
Re: Pressure sensitive switches
« Reply #21 on: Fri, 19 February 2016, 20:22:16 »
Hi veclock, not yet. I'm still mainly working on KType related firmware things (i.e. http://input.club/), so I only get to work on fun side projects when my eyes can't take LEDs anymore :P.

Right now, my side-project is a force curve gauge. I've finished the initial hardware and firmware, just putting together some of the client side software. So once I start posting proper force curves I'll be able to looking at cap sense again :D
Kiibohd

ALWAYS looking for cool and interesting switches
I take requests for making keyboard converters (i.e. *old keyboard* to USB).