HW 2 - Text Entry Device

From CS294-84: Interactive Device Design
Jump to: navigation, search

Early Chorded key set; Photo by Erik Pitti on Flickr

Consider these instructions to be a work in progress until 9/5!


This is an individual assignment.

You will build a text-entry device that only uses discrete input components. The device will send characters to a connected PC over a serial connection. At a minimum, the device has to cover the lower-case alphabet and the space character, so you can type complete phrases such as "hello world".


The reading for this week included examples of various text entry techniques: multi-tap, T9, five-key (direction pad), or chording. Choose one of these techniques and build a working text entry device. This will involve the following steps:

  • Design a key layout: you may want to use momentary switches, or construct your own switches using wire and copper tape.
  • Wire switches to your Boarduino microcontroller.
  • Write C code for the Boarduino (using the Arduino IDE) to read switch states and interpret switch states . This may require taking into account timing (for timeouts in multi-tap) or the states of multiple switches (e.g., for chording).
  • Output characters via a serial connection to an attached computer.
  • Five-key input requires you to write display logic on the computer as well (e.g., to show the user which key is currently selected). Multi-tap and T9 can also benefit from intermediate feedback to help users disambiguate between multiple options or show them the current interpretation of the input so far.

We suggest you first breadboard your circuit, then figure out how to mount the switches and how the user actuates them.

Turn in instructions

Create a Wiki Page for this assignment

Begin by creating a new wiki page for this assignment. Go to your user page that you created when you made your account. You can get to it by typing the following URL into your browser:


Replace FirstName and LastName with your real first and last names. This will take you to the page you created for yourself when you created your wiki account. Log into the wiki, then look for your name on the top line of the page - clicking on the name will take you to your user page, too. If you have trouble accessing this page, please check that you created your wiki account properly.

Edit your user page to add a link to a new wiki page for this assignment. The wiki syntax should look like this:

[[Homework2-FirstNameLastName|Homework 2]]

Again replace FirstName and LastName with your name. Look at my user page for an example. Then click on the link and enter the information about your assignment. You should upload the files described below and describe any extra functionality you implemented and want us to review.

Write up your project on this wiki

On the Homework2-FirstNameLastName page you just created, write 1-3 paragraphs about your implementation:

  • what text entry technique you chose and why
  • how you implemented character recognition (i.e., how your Arduino code works)
  • how you constructed the physical device
  • Include images (How to include images). At a minimum:
    • A photo of the final device you constructed.
    • Include a wiring diagram - we using recommend using Fritzing. Use our custom Fritzing Parts for the Boarduino. Alternatively, you can submit a hand-drawn diagram.
  • Reflection: what you learned from this assignment (also let us know if this was too easy or too hard)
  • Record a short video of you typing the phrase "hello world" or "device design". Make sure your video shows both your actions and the text appearing on screen at the same time. (How to include video)

One you are finished editing the page, add a link to it at the bottom of the page with your full name as the link text. The wiki syntax will look like this: *[[Homework2-FirstNameLastName|FirstName LastName]]. Hit the edit button for the last section to see how I created the link for my name.

Turn in your code using the Class Revision Control System

You'll receive an invite to a subversion repository from "Berkeley HCI on Unfuddle", a hosted subversion service. Once you've created your account, change into a working directory and check out your personal HW2 repository with:

svn checkout 
berkeleyhci_devicedesign/assignments/hw2/<username> hw2

(all on one line)

Where <username> is your berkeley email id as recorded in bearfacts (it's one of: aijiay, alice.z.wang, amypavel, bruckner, bryan, cthompson, dcheng090, dhaas, haojun.liu, hassan_elahi, jaheller, jj.liu, kuldeep, mark.fuge, mozzi, nahmane, paredes, peggychi, petercheng00, ross.yeager, ryanrho, sean.yhc, sh_cheng, shiry, srubin, taeil2, valkyrie, vivek.rao, weiwu)

Then add your files with svn add and commit them with svn commit.

Only check in your source files (.ino for Arduino, .pde for Processing) - don't check in any binaries. Feel free to check in images, but keep them <2mb each. Don't check in videos.

If you're new to Subversion, you may want to start with a GUI client like Versions on OS X or TortoiseSVN on Windows.

Extra Credit

  • If you are ambitious, you can build a mouse using two quadrature encoders and a button; then write software that moves a cursor on the PC screen to select letters on the screen as in a soft keyboard.
  • Alternatively, you can use a microcontroller that supports a USB HID profile (e.g., the Arduino Leonardo or the Teensy) to directly emulate a keyboard and type into any application (not just the serial window)

Links to Finished Assignments

Add your submission below this line.