AI summary by TwinMind

The Art of the Bodge: How I Made The Emoji Keyboard

Tom Scott

17m 15s

Why Windows for Coding

  • Uses Windows despite being techie: cheaper, enables bodging
  • Bodging = British term for patching together temporary repairs
  • Clumsy, inelegant, but works as long as someone maintains it
  • Apollo 13 square peg/round hole example as greatest bodge in history

TV Show Experience and Bodging Background

  • Worked on TV show with Colin Furze (YouTube creator, mobility scooter land speed record holder) and Charles Yarnold (micro electronics, made Obama's Christmas tree with online customizable lights)
  • Role: bridge between physical fabrication and digital world
  • Built smartphone app for remote control horse steering
  • 16-hour days, 7 days/week, prototypes had to work for one filming day
  • AutoHotkey was primary bodging tool

AutoHotkey Overview

  • Sometimes detected as virus due to capabilities
  • Originally simple: wait for key press, start program/type text/execute key commands
  • Example: F10 key makes game character spin 180° and fire
  • Expanded capabilities: read files, pixel color detection, call Windows DLLs, regular expressions
  • Terrible scripting language inspired by Visual Basic
  • Used for skydiver parachute release control on TV show
  • Greatest TV show bodge: voice synthesizer + Sibelius on Mac remote controlled by AutoHotkey on Windows PC via remote desktop + Chrome commands over Wi-Fi

Emoji Background and History

  • World loves emoji despite individual preferences
  • Emoji headlines get significantly more clicks
  • Made emoji-only messenger with Matt (cameraman) - high initial usage, quickly abandoned
  • Movie studios bidding on emoji pitch for nearly $1 million

Unicode and Emoji Development

  • Originally Japanese innovation due to extra space in text encoding
  • Pictures in text without bandwidth of actual images
  • Unicode Consortium standardized global text encoding
  • Added Japanese emoji as "glyphs" to maintain two-way compatibility
  • Apple quietly added emoji for Japanese iPhone market
  • Viral explosion when users discovered "piles of poo" emoji
  • Americans confused by Japanese-designed emoji (cherry blossom, riceball vs burrito)
  • Original ~100-150 emoji designed decades ago for Japan only

Modern Emoji Expansion

  • Unicode Consortium forced to bodge in new emoji
  • Flag system: country abbreviation letters combine into flags
  • Skin tone modifiers added (yellow/white defaults problematic)
  • Zero Width Joiner creates family combinations from individual characters
  • Shift key enables family combinations on this keyboard
  • Wingdings included (levitating man in business suit from American decision)
  • Current ~1,200-1,300 emoji across 214 keyboards

Physical Keyboard Construction

  • Considered full Unicode keyboard but would need hundreds of keyboards
  • All emoji fit on 214 keyboards
  • Sticker printing/alignment on keys challenging
  • 14 USB keyboards connected through USB hubs to Windows machine

Programming Challenge: Multiple Keyboard Detection

  • Windows treats all 14 keyboards as single input device
  • AutoHotkey couldn't distinguish between keyboards
  • Low-level Windows APIs available but complex
  • Discovered Lua Macros from flight simulator community

Lua Macros Solution

  • Flight simmers build accurate cockpits with 100+ switches
  • Lua Macros: modified Lua programming language with keyboard detection functions
  • Full programming language capabilities
  • Successfully detected individual keys from individual keyboards

Key Mapping Algorithm

  • Get each key's code (number sent to OS)
  • List codes top-left to bottom-right, ignoring complex keys (enter, control)
  • Formula: key position + (total keys × keyboard number)
  • Example: 5th key on 2nd keyboard = position 4 + (94 × 1) = item 98
  • Lua counts from 1 (not 0 like other languages) - caused 30-minute debugging delay

Emoji Output Challenge

  • No emoji keys on regular keyboards
  • Windows Alt + numeric keypad for special characters (IBM PC/BIOS/DOS legacy)
  • Extended to Unicode: Alt + plus + Unicode code point
  • Registry tweak enables Unicode input
  • Works in rich text boxes (Word) but not plain text (web browsers, Twitter)

Final Bodging Solution

  • Two-program system:
    1. Lua Macros: intercepts keypress, calculates emoji number, saves to file, presses F24 key
    2. AutoHotkey: listens for F24, reads file, looks up emoji, types emoji
  • F24 key exists for backwards compatibility but not on physical keyboards
  • AutoHotkey uses low-level Windows functions, works in any text field
  • File-based communication between programs

TwinMind

Get summaries like this for your own meetings

TwinMind takes notes in the background during meetings, lectures, and calls, then writes the summary for you.

Free plan to get started

No bot joins your calls

Phone, desktop & Chrome apps

Your next meeting, summarized like this

TwinMind listens in the background and turns meetings, lectures, and calls into searchable notes you can chat with. Start free.

Available on phone, desktop & Chrome

Your next meeting, summarized like this

TwinMind listens in the background and turns meetings, lectures, and calls into searchable notes you can chat with. Start free.

Available on phone, desktop & Chrome

Your next meeting, summarized like this

TwinMind listens in the background and turns meetings, lectures, and calls into searchable notes you can chat with. Start free.

Available on phone, desktop & Chrome