Jonathan Pallant's Monotron: An Arm Cortex-M4 Microcomputer Powered by Embedded Rust

Pallant's retro-inspired microcomputer is programmed entirely in Embedded Rust - including its own upcoming BASIC-like programming language.

Gareth Halfacree
6 years agoRetro Tech

Jonathan Pallant has created a microcomputer with a difference: powered by an Arm Cortex-M4 processor, the system's software is written entirely in Embedded Rust — while offering games with joystick control, loading from an SD card, MIDI connectivity, and analog VGA video output.

"I wanted to make a 1980s style home computer using an inexpensive Cortex-M4 devkit," Pallant writes of his inspiration for the project. "Can you generate VGA from this board? In colour? How about handle a PS/2 keyboard? Load applications? Let the user write BASIC programs? Generate audio? More importantly, can you do all this in pure Embedded Rust, with no C or C++ in sight?"

The answer, it turns out, is "yes" on all fronts. Now in Revision 0.7, the Monotron — as the machine is called — boasts a wealth of features: an Atari-compatible joystick port and PS/2 keyboard, driven by a secondary Microchip ATmega microcontroller, provide control over software and games loaded from an SD card; there's an on-board real-time clock (RTC), a feature missing from most home computers of the eight- and even 16-bit eras; there's MIDI in and out for music work, along with an analog audio output; and video is handled by an analog VGA output.

"I can load games and programs from the SD card into the 24KiB of free Application RAM. You can interact with these games via the PS/2 Keyboard and Joystick," Pallant writes. "I can play simple games (like Snake) and play three channels of 8-bit wavetable audio simultaneously. I've even got a 6502 Emulator running a copy of 6502 Enhanced BASIC, if you want to go old school!"

Pallant's work on the project isn't done, however. The to-do list includes the addition of a second joystick port with Sega Mega Drive/Genesis pad compatibility, fixes for the parallel port, and the creation of a dedicated programming language dubbed Monotronian. "It allows line editing like BASIC," Pallant explains, "[but] has fewer magic keywords (like BASIC's INPUT) and instead has more functions (like C or Python) — [and is] all written in pure Rust."

More information on the Monotron is available on Pallant's project page.

Gareth Halfacree
Freelance journalist, technical author, hacker, tinkerer, erstwhile sysadmin. For hire: freelance@halfacree.co.uk.
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles