Good news, everybody! I have finally figured out what the issue was that prevented Engine BASIC from being booted from an SD card on the H3 (Orange Pi) platform.
I have thus added the H3 platform to the daily build script, and you can find ready-to-use SD card images on the daily build page with the prefix basicengine-firmware-h3-
. These work on the Orange Pi Lite, but should also work on the Orange Pi One (I'm only 99% sure because I have misplaced mine; a new one is on the way). It may work on other Allwinner H3-based systems as well, but YMMV. I have only lightly tested it, but it runs the SHMUP
demo, so it can't be that bad.
The Orange Pi is a stonking great platform for our purposes. It solves numerous issues that many people had with the original BASIC Engine:
- You can just buy it online, no soldering required.
- HDMI video and audio output
- full USB keyboard support, no more hunting for PS/2 compatibility
- full Micro-SD compatibility, no more issues with cards that don't support SPI
And that's just the stuff that already works. The sheer amount of RAM alone provides massive potential for future development. Some examples of things that were not possible before:
- PNG image (de)compression needs 32k of RAM for the sliding window. We just don't have that much to spare on the ESP8266. On the OPi, it's a drop in the ocean.
- File system check. Seriously, you cannot check a FAT file system on an ESP8266, there is not enough memory.
- a full Lua API (I have just implemented the video commands today)
- space to load your own machine code programs
- high-resolution video modes with 24-bit colors
Beyond the size of the RAM, the hardware also provides other features that make things possible that cannot happen on the original design:
- Support for USB gamepads should be easy (keyboard HID already works).
- The SoC contains a metric ass-ton of built-in devices that can be mapped to the expansion connector for the hardware people to tinker with; GPIO, PWM, timers, UARTs, SPI, I2S, I2C, you name it.
- a widely-used CPU instruction set (ARM32) that is actually fun to program for
- ridiculously fast processor, over 10x as fast as the ESP8266
Despite all that muscle it maintains the virtues of the BASIC Engine:
- super-simple OS (only a couple of kLOC) based on Charlie Smurthwaite's allwinner-bare-metal framework
- Dirt. Cheap. (I just ordered an Orange Pi PC and Orange Pi One for a combined 20 Euros, plus 6 Euros shipping.)
- No restrictions whatsoever. Write a GPU driver in BASIC. I dare you.
- more open-source than the ESP8266, everything is open from the moment the first instruction loaded from the SD card is executed
At all that comes on top of the fact that it's infinitely easier for me to develop for this platform. No more shuffling around of data and code between various more or less restricted types of memory. Everything is RAM, everything can be accessed the same way. No need to worry where to get a 256-byte buffer from. No god-damn direct-mapped cache! What a relief!
Basically, the only catch is that it's an off-the-shelf system. But I could not build a better one if I tried. Get one. You will not regret it.