Lua Plugins — first fully playable release, not optimized but all working
This release makes the Lua plugin system usable: the bundled example apps
actually work, controls respond, errors are visible, and launching plugins no
longer reboots the device.
What's new
- No more reboot between apps. Plugins now open and close instantly,
returning straight to the plugin list. No waiting for a restart every time
you try something. - Smarter Back button. A quick press of Back is now available to the
plugin itself (for example, to cancel a screen and go back one step). To
leave a plugin for good, just hold Back for about 1.5 seconds. - New look for the plugin browser. Cleaner panels, multi-line
descriptions that adapt to the text, and a dedicated icon for the Plugins
entry in the Apps menu. - Plugin errors are easy to see. If something goes wrong in a plugin, you
get a readable message on screen with the line that caused it, and the full
details go to the serial/USB console — perfect while developing your own
plugins. - Developer logging. Plugins can print messages to the serial console
(tagged with the plugin name), so you can trace what a plugin is doing step
by step.
The bundled plugins
| Plugin | What it does |
|---|---|
| Hello World | The minimal starting template: text on screen, exit with Select or a long Back press |
| Snake | Classic snake inside a bordered play area, with score and a saved high score |
| Breakout | Brick breaker with a paddle, ball and bricks — playable on e-ink |
| Sudoku Full | A complete Sudoku game: navigate the grid, open the number pad, fill the puzzle |
| Todo List | A persistent to-do list saved on the SD card |
To use them: copy the .lua files from the plugins/ folder to the
/custom/ folder on the SD card, then open Apps → Plugins.
What was fixed
- Plugins used to close instantly. Hello World (and some examples) exited
on the very first frame. They now wait for you. - Launching a plugin could trigger an action by itself. If you were still
holding the button used to open a plugin, the plugin could interpret it as
a press (for example, Todo List added an item by itself). Launch presses
are now ignored. - Sudoku froze when picking a number. The number pad would stop
responding. Number selection now works. - Graphics drawn off-screen. Text and shapes could be drawn outside the
screen, filling the log with errors. All drawing is now kept inside the
panel. - Game controls felt dead. Snake and Breakout only reacted every half
second. Buttons now respond immediately, and the games move at a proper
speed. - Sudoku Full crashed at startup. The puzzle generator used too much
memory; it now uses a pre-built puzzle and starts reliably. - Plugin logs were invisible. Messages from plugins now actually appear on
the USB/serial console, with errors reported line by line.
A note about e-ink (please read)
The screen is an e-ink display, which physically updates at roughly one frame
per second. That means fast games look choppy — this is the display
technology, not a bug. To make games feel responsive anyway:
- Buttons are sampled very often, so holding a direction key steers
immediately; - Hold a button for about half a second rather than tapping it quickly,
so the device is sure to catch it.
The bundled games are tuned for this and work well as relaxed, slower-paced
games. If you write your own plugin, keep these two habits in mind.