6 key keyboard? - Page 1
Forum section: electronics / projects

author: devin23b
author_rank: Newbie
timestamp: February 07, 2017, 07:03:42 am
content: I was thinking of making, (just for fun) a keyboard that has only 6 keys. 5 shift keys and single blank letter key. You type by using the shift keys in a binary form for example if you didn't hit any shift keys you get an "A". (00000=A) or if you hit 00001 you get B, and so on. what would be best way to do this??Key to shift presses00000=A00001=B00010=C00011=D00100=E00101=F00110=G00111=H01000=I01001=J01010=K01011=L01100=M01101=N01110=O01111=P10000=Q10001=R10010=S10011=T10100=U10101=V10110=W10111=X11000=Y11001=Z11010=space11011=Period11100=Comma11101=Forward Slash11110=Colon11111=Quotation Mark

author: Codebird
author_rank: Regular Contributor
timestamp: February 07, 2017, 07:08:14 am
content: You have invented the chording keyboard. Several such products exist, aimed at either mobile use, or users with disabilities that prevent the use of a normal keyboard.Best way? There are a few 8-bit micros with built-in USB device interfaces. Though I do get the impression that low-level USB is a tricky thing to program. Complicated standard.

author: ataradov
author_rank: Super Contributor
timestamp: February 07, 2017, 07:13:22 am
content: They also assign easy-to-hold patterns to most commonly used letters.There are (were?) also software emulators that do the same thing with normal keyboards.I tried this with normal keyboard a long time ago, just for fun. And it was not fun at all.

author: devin23b
author_rank: Newbie
timestamp: February 07, 2017, 08:10:01 am
content: Is there a way to do this with shift registers or something?

author: ataradov
author_rank: Super Contributor
timestamp: February 07, 2017, 08:13:31 am
content: Quote from: devin23b on February 07, 2017, 08:10:01 amDo what with shift registers? I'm pretty sure any micro will have 5 GPIOs. Why would you need a shift register?

author: devin23b
author_rank: Newbie
timestamp: February 07, 2017, 08:31:16 am
content: only shift reg. would you absolutely need a micro for this?

author: ataradov
author_rank: Super Contributor
timestamp: February 07, 2017, 08:34:35 am
content: If you want to connect it to the computer, then yes, you will need a micro. Shift registers are not some magical things that can do everything.But before you do anything, you need to figure out how you will latch the input. It is impossible to press two or more buttons at the same time, so you need to signal when input is ready.

author: Berni
author_rank: Super Contributor
timestamp: February 07, 2017, 08:35:49 am
content: Unless you have an ancient computer that still has a LPT port yes.

author: ataradov
author_rank: Super Contributor
timestamp: February 07, 2017, 08:42:05 am
content: Well, you can do a simple UART transmitter using a shift register. You will need a level shifter as well. Finding a computer with serial interface is still a relatively easy task.But it is really not worth the effort, since there are $1 MCU with USB interface.

author: Cupcakus
author_rank: Contributor
timestamp: February 08, 2017, 08:24:51 am
content: I've used a PIC18F for custom keyboards in the past, you can get them cheap in dip packages and keyboards use the very simple USB HID interface, there are piles of example code on the web. You'll need a crystal and few ceramic caps, and a USB connector, a few lines of code and off you go.Heck, I even used it to give a Commodore Pet a USB port:https://mobile.twitter.com/Cupcakus/status/548271460439965696

author: tszaboo
author_rank: Super Contributor
timestamp: February 08, 2017, 09:38:00 am
content: Get an Arduino Leonardo, that has keyboard mode so easy, a 10 year old could do this.

author: PA0PBZ
author_rank: Super Contributor
timestamp: February 08, 2017, 10:03:32 am
content: Ah, the Microwriter:https://en.wikipedia.org/wiki/Microwriter

author: firehopper
author_rank: Frequent Contributor
timestamp: February 08, 2017, 06:39:13 pm
content: a teensy could do it pretty easily too.

author: Fungus
author_rank: Super Contributor
timestamp: February 08, 2017, 07:10:13 pm
content: Quote from: PA0PBZ on February 08, 2017, 10:03:32 amMy first thought, too.An Arduino Leonardo* would be the easiest way to do this. Shouldn't be more than about 20 lines of code. I bet if you google "arduino leonardo chording keyboard" you'll find something.(*Or a "Pro Micro" - which is just a very small Leonardo)