Saturday, 14 March 2015

Time saving Keyboard shortcuts for the PC

It's been quite a while since my last post but sometimes life throws you a curved ball and changes your focus for a time.  Anyway this little project came about due to a friend at work having to replace his PC keyboard but not being able to find one with single pre-programmed buttons for copy and paste, as did his current one, and I said " I can do that with an Arduino".

So the idea was to use an Arduino Leonardo clone that can emulate a mouse or keyboard and then program the keyboard sequences to be triggered from the press of a button.  Initially I was going to do just the copy, cut and paste but as I was going to use the standard 5cm x 5cm Seeedstudio PCB service I thought I could add some more buttons.

I decided to do a PCB with six momentary push buttons, mainly because they were what I had in my box of components.

The botom row, blue, black and white buttons are copy, cut and paste respectively and I assigned the red, amber and green buttons to change the background colour of Excel cells to match the button colour (this was a request from another friend at work who uses Excel a lot)

The buttons could have any combination of key-presses assigned to them I suppose, 'Ctrl+Z' for undo etc.

Circuit Diagram

The connections are a bit out of order due to pinswaps on the PCB!

I used the "Sick of Beige" 50mm x 50mm PCB template from Seeedstudio as I intend to use their Acrylic laser cutting service to create a top and bottom box to house the keyboard.
Keypad Concept

Due to space availability I placed the Leonardo PCB on the underside of the PCB, this did mean that it was a bit fiddly soldering the pins for the Leonardo as I didn't want any pins sticking through the PCB into the body of the switch so solder the pins first and make sure they are flush with the button side surface, NOT protruding.
Make sure the pins don't go too far through.
The pins can be trimmed

Everything is powered by the USB lead plugged into the PC and there is an optional SMD or 3mm TPH LED on the button side that connects to a PWM capable IO pin, I set this to indicate power at 7% duty cycle and then pulse to 78% duty cycle for 50mS whenever a key is pressed.

I've ordered the acrylic tops and bottoms from Seeedstudio but they've yet to arrive.

All the files, including the Eagle schematic, PCB, gerber files and the sketch are here.

No comments:

 Time for another post. A while ago I bought a new Oscilloscope, a RIGOL DHO914, but this scope doesn't have WiFi built in just a LAN co...

Popular Posts