Language/Interface for a 5-button device

I'm going to be doing some traveling in the near future where I won't have my laptop available, but I'd still like to be able to play around with programming a bit. I have an MP3 player running the opensource firmware rockbox, and thought I could develop a plugin for it that would be a programming environment that would let me still code some toy programs relatively quickly despite the player only having 6 buttons.

This presents some unique challenges. Ideas so far:

-Keep naming things to a minimum (since typing variable names by selecting letters from a grid would be really burdensome). I'm thinking of just having a 'new variable' option that would give a variable with an autogenerated name (e.g. 'A1'), with the option to edit the name if things start to become too unreadable.

-Programs are state machines. Press a button to make a state (also having autogenerated names, e.g. 'S1'). Each state has a set of button handlers and a particular screen graphic associated with it. Not necessarily scalable to large programs, but should be sufficient for small ones. This way switching what buttons should do and switching what's on screen involves just picking a state from a list.

-Builtin functions to draw a grid of squares, iterate over all of them by row or by column, and the ability to associate state with each square. Squares will automatically have at least one character variable associated with them, and the value stored in it will be drawn inside the square.

I think this would be enough to implement some simple board games like othello, and some toy programs like say a binary clock. But I'm curious if anyone else has ideas or has worked in a similar environment, say trying to make a programming IDE for a cell phone or other limited input device.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Ti calculators

While not strictily limited input, it is a very inconvenient input device.
to allow reasonable programming one of the things they do is have all the key words/built in functions/code editing (page up/down del, insert) selectable from a hierarchal menu, my 85 has 5 buttons for that as well as exit and more to scroll and back up menu levels.

basic programs don't require you to do more than type variable names, numbers and some operators. and those could be typed in with a small pop up keyboard. which would also allow use of more complicated functions that you don't need often.

I imagine an intelligent menu that collected function names (or well names that appear after GOTO statements at least), and variables (anything followed by an assignment operator) would speed things up too.

And if it can play doom, i'm sure it can handle that much.