[go: up one dir, main page]

Arduino binary USB keyboard

I don’t know many (or any) people who think of characters and words in binary, but that might just be a limitation on my end. If you prefer binary, maybe this is something for you. If you just want to geek out, you’re welcome to stay here too.

Using a 2-button macro-keyboard and some Arduino code, you can tap in binary and have the keyboard enter ASCII characters.

View on YouTube

Hardware

I used a 2-button keyboard of my own design, you can make one with a Pro Micro board too. It’s essentially the same setup as the basic 3-button board, just with 2 buttons. I also have 2 RGB LEDs on the board, but that’s optional.

Software

The code is written in Arduino C++, using the FastLED and Keyboard libraries.

Code on Github

For practicing, it shows the binary code first, then when you have all 7 bits, it backspaces and replaces it with the actual character. Tabs (7 ASCII) are replaced with 6 tabs (for the Twitter reply UI). Control characters other than tab or return are ignored.

I used a random online ASCII / binary table as a reference.

Sidenotes

Random comments …

  • The codes uses 7-bit binary, which covers most needs.
  • Typing in binary is weird.
  • The video was recorded with OpenCamera on Android, which messed up audio synchronization.
  • It turns out, a binary keyboard isn’t that practical. #shrug

Comments / questions

There's currently no commenting functionality here. If you'd like to comment, please use Mastodon and mention me ( @hi@johnmu.com ) there. Thanks!

Related pages