
The BASIC Engine - fcambus
https://basicengine.org
======
andrewstuart
Two types of minimal computing - don't get them confused:

There's "pack as much power as you possibly can into a minimal computer" \-
that's raspberry pi.

There also "drive tiny, minimal CPUs to do amazing things at the edge of their
specifications cause it's cool and fun" type minimal computing - that is this
device.

People who don't understand the distinction will always say "Huh? Why is this
interesting? I don't get it.... a raspberry pi is the same size and more
powerful."

If you really want to be knocked out, see how the ESP8266 CPU in this device
is able to generate a wireless NTSC video signal with zero extra components
[https://www.youtube.com/watch?v=SSiRkpgwVKY](https://www.youtube.com/watch?v=SSiRkpgwVKY)
and then the next level Charles Lohr takes it to color
[https://www.youtube.com/watch?v=bcez5pcp55w](https://www.youtube.com/watch?v=bcez5pcp55w)

Put another way, the ESP8266, with nothing more than a wire connected to it,
is able to generate a broadcast TV signals and display 3D graphics on that
broadcast TV signal.

The ESP8266 was also tested by Charles Lohr to have a wireless CPU to CPU
range of 1 kilometer
[https://www.youtube.com/watch?v=ekSsi83-x8M](https://www.youtube.com/watch?v=ekSsi83-x8M)

~~~
rusk
I was a bit _ho hum_ at

 _> is able to generate a wireless NTSC video signal_

But then I read

 _> is able to generate a broadcast TV signals_

and I read it again.

Are you telling me this will actually produce a RF signal that could be picked
up by a 80s era portable television?

That is indeed amazing and I actually wouldn't have thought it possible with a
digital device.

EDIT - Having just watched that video I can say that is truly amazing. That
has made me so happy.

~~~
pjc50
It's not precisely broadcast, it's in the "baseband" region and would require
modulation up to RF frequency to actually transmit over a distance.

See earlier work by Fabrice Bellard:
[https://bellard.org/dvbt/](https://bellard.org/dvbt/) (arguably more
impressive signal processing, but requires a graphics card's high-speed DAC)

~~~
rusk
_> and would require modulation up to RF_

Can you elaborate? Seems to me it's working without any additional analogue
circuitry ...

~~~
pjc50
No, you're right and I'd got my frequency bands wrong, was thinking of 698-806
MHz. 61.5MHz is the broadcast RF band for channel 3, not the baseband.

(I've probably spent too much time around modern radio systems and just
casually assumed that 61MHz was too low to be useful, oops)

~~~
jdietrich
30 to 300MHz still has the ITU designation of "very high frequency". I know
that these days all the sexy stuff is microwave, but the EM spectrum is useful
all the way down to DC. The cave radio system used in the rescue of the Wild
Boars operates down at 87 _kilo_ Hertz. Surface-to-submarine radio systems all
operate below 30kHz.

------
peapicker
Awesome, the Z-Code Infocom game interpreter is derived from the one I
wrote/maintained back in the mid 1990s! :)

~~~
scruffyherder
Jzip? [http://jzip.sourceforge.net/](http://jzip.sourceforge.net/)

~~~
peapicker
That’s me, indeed. I haven’t touched the site in forever. Should probably move
it to github.

~~~
jlebrech
and compile it to webassembly? :)

------
pinewurst
This is super cool - especially note the history =
[https://basicengine.org/history.html](https://basicengine.org/history.html)

~~~
apo
_I thought about it. So what if I’ll present the BASIC Engine to the public,
and some kid comes along and says, "WTF, one GPIO? My dad’s Arduino Uno has
more than that!" And instead of joining the peaceful forces of the BASIC
Salvation Army, she walks by, straight into the arms of a recruiter for a
military equipment manufacturer, spending her life developing drones that kill
innocent people in Central Asia. Would I be able to live with myself after
that?_

I suspect the author is only partially joking here. Having worked with kids on
robotics projects, and seeing the near-total apathy/ignorance to the countless
atrocities being committed by the US government on behalf of its citizens, I
can only wonder how much harm is being done by well-meaning people.

------
AnIdiotOnTheNet
This is really cool, I especially like how commodity most of the parts are.

The 8-bit micro era, for me, was where personal computing really began.
Suddenly the market gave people access to computers at an affordable price
that empowered them to create their own tools[0] with BASIC, which they often
booted directly into. They were simple systems that didn't try to manage your
life for you, or act like you didn't really own them, or give you the safety
scissors version of computing. That sort of experience is sadly quite lacking
today.

And this thing is significantly more powerful than most of those systems, but
still acts like one of them. I think it's great.

[0] And play games. Don't discount the value of that, many a child convinced
their parent to buy them a computer so they could play games and ended up
teaching themselves to program because it was empowering and they could create
their own games.

~~~
blt
Just curious, what other era would even be a candidate?

~~~
wrycoder
Ham radio in the first quarter of the 20th century, when people built their
own transmitters and receivers, winding their own coils and making high
voltage caps out of sheets of glass. Often the station was in a “shack” in the
back yard, because the open cell battery fumes and the noise and ozone of the
spark gap caused an eviction from the house.

Hams have continued this experimentation to the present day. The community was
in danger of aging out, but recently there’s been a connection with the maker
community via WiFi technology, digital tech and sdr.

Happily, hams are finally getting away from Windows and are embracing FOSS.

For example, it’s not too difficult to homebrew a tripod mounted uhf system
and antenna which, when set down outside, will orient itself and track a given
satellite (itself built by hams) and initiate communications through it. You
can’t buy something like that commercially.

------
helipaddi
For anyone interested in building one, one of our user's published the project
as a complete kit including PCBs, parts and stencil. See
[https://aisler.net/p/HVNNCYON](https://aisler.net/p/HVNNCYON)

Disclaimer, co-founder of aisler here but not affiliate with the BASIC engine
project

~~~
Jaruzel
I'm fairly good with a soldering iron, but there's several SMD parts there,
that would probably test me a bit. If this was really to appeal to low-end
hobbyists, it'd all be through-hole parts.

High end hobbyists are already building their own single board computers based
on their own designs.

------
ArtWomb
Seems closer to an Intel i386 in specs, no? To think this is now retailing for
10 euros ;)

In any case, an entire generation of game developers back in the day cut their
teeth on BASIC. And many of the fundamentals of arcade era game design can
still be gleaned from those ancient manuals ;)

Vintage BASIC

[http://www.vintage-basic.net/games.html](http://www.vintage-
basic.net/games.html)

More BASIC Computer Games

[https://archive.org/details/More_BASIC_Computer_Games_1980_C...](https://archive.org/details/More_BASIC_Computer_Games_1980_Creative_Computing)

~~~
pjmlp
Here are some more, there is a nice archive for 8 bit Atari.

[https://www.atariarchives.org/](https://www.atariarchives.org/)

~~~
markdoubleyou
That list is missing one of the formative books of my youth: Dr. Wacko
Presents Atari Basic and the Wiz-Bang Miracle Machine

[https://archive.org/details/ataribooks-dr-c-wacko-
presents-a...](https://archive.org/details/ataribooks-dr-c-wacko-presents-
atari-basic-jjj)

------
dvfjsdhgfv
If you're interested in it, you may want to check Duinomite:
[https://www.olimex.com/Products/Duino/Duinomite/](https://www.olimex.com/Products/Duino/Duinomite/)

The disadvantage of using VGA is that if you actually want to use it for
showing your kids how much fun we had once then, they might not be able to
appreciate it when you connect the device to a large screen - it doesn't look
too nice and a CIRCLE draws a (jagged) ellipse...

~~~
pinewurst
That reminds me of Maximite
([http://geoffg.net/Maximite_Story.html](http://geoffg.net/Maximite_Story.html))
which has similarities to the BASIC Engine.

~~~
dvfjsdhgfv
Duinomite is actually based on Maximite.

As for the Maximite story, I love the grandmother bit ("This program was
originally begun in 1982 by my grandmother, Mrs Verda Spell of Beaumont,
TX...") I was so curious I actually found the author of the original
interpreter and he explained it to me that, alas, it was only a joke.

------
titimoby
This project is just fantastic for me and for the coding club sessions I
organize.

I just have to figure out how to use the usb keyboard mentioned in the
optionnal component and find screens able to show a PAL or NTSC signal.

It is a great and wonderful job, million thanks

------
cgmil
I've read about old books for programming a BBC Micro with BASIC, where the
games were in books written as code you would have to type in yourself. This
book in particular caught my attention:
[http://www.acornelectron.co.uk/eug/revs/collins/Bbc_Micro_Wa...](http://www.acornelectron.co.uk/eug/revs/collins/Bbc_Micro_Wargaming_000.html)

I feel like the answer is obvious but I'm going to ask anyway: if I were to
take the programs from one of these books and code it into this machine, is it
likely to work?

~~~
laumars
That was truly a golden age for computing in my biased opinion.

Anyhow, you're question. Unfortunately no. You'll find that some parts of the
program will work fine but Microsoft BASIC (which is what the Commodores ran
and what this seems loosely based on) weren't entirely compatible with BBC
BASIC.

BASIC in the 80s was a bit like Javascript in the 00s in that every browser
did things did things subtly differently.

As an aside, I was playing on my BBC Micro last night. :)

~~~
vanderZwan
> _BASIC in the 80s was a bit like Javascript in the 00s in that every browser
> did things did things subtly differently._

That leads to the obvious question whether there are there more modernized
BASICs out there now. Is there a standardized ES6 equivalent, perhaps? ;)

~~~
AnIdiotOnTheNet
There are a lot of BASIC languages these days, all subtly different (or
radically, if you count VB.Net). BASIC variations were often quite married to
their purpose, whether that was programming for a specific model of 8-bit
micro, or being embedded in WYSIWYG GUI design tool.

As mentioned by someone else, QBasic is still around, and there's also Gambas
(which is as close to old-school VB as one can get on Linux) if you're looking
to play with something.

------
2sk21
Sorry I really don't get this. Basic is a fun way to get started but why not
simply run it on a Raspberry Pi Zero W?

~~~
dan-robertson
1\. Choose what sort of Raspberry Pi you want. Choose carefully because even
if this doesn’t matter, you think it matters.

2\. Buy that thing and wait for it to be delivered

3\. Decide what Linux distributation you want. Choose carefully because even
if this doesn’t matter, you think it matters.

4\. Download the Linux distribution. Make sure that you don’t accidentally
download one for the wrong architecture...

5\. Somehow work out what to do with a .iso

6\. Start installing Linux distribution (may need to set up network)

7\. Decide on programming language. Choose carefully because even if this
doesn’t matter, you think it matters.

8\. Decide what you want to do

9\. Part of what you want to do is hard/not supported/you don’t know the
“right way”. Figure out how to get round this (if possible)

10\. ???

11\. Congratulations. You have now _started._

~~~
menacingly
I see where you're coming from, but these are gross exaggerations in the vein
of infomercials depicting performing mundane tasks without their product as
nearly impossible.

First, the software could be packaged as an OS image for the pi itself,
eliminating a fair chunk of your list, but second, the alternative presented
on this page is to assemble the hardware from a list that includes resistors.

Surely if you can manage that, you can wrangle an iso.

~~~
jdietrich
There are a whole heap of gotchas that don't seem like a big deal if you're a
savvy adult programmer, but are showstoppers if you're eleven years old and
just getting into proper computing.

The Raspberry Pi is a very useful thing, but Eben Upton will freely admit that
it was the wrong solution for the intended audience. It's just too complex and
too brittle to work as a "modern BBC micro" for educational use. The lessons
learned from RPi led to the BBC micro:bit, a much simpler Cortex M0
development board that has been a roaring success in British schools.

[https://en.wikipedia.org/wiki/Micro_Bit](https://en.wikipedia.org/wiki/Micro_Bit)

The BASIC Engine isn't a suitable educational tool as-is, but it could become
very useful if it's offered as a commercial product with HDMI or VGA output.

------
mwcampbell
I wonder if the 5-bit audio output in this device would be good enough for
some old-school speech synthesis. To go really old-school, maybe something
like the Echo synthesizer [1], which I have fond memories of using on an Apple
IIe at school in the late 80s and early 90s.

[1]:
[http://www.festvox.org/history/klatt/part29.au](http://www.festvox.org/history/klatt/part29.au)

------
brandonmenc
> Wavetable synthesizer

They really mean sample-based:

[https://en.wikipedia.org/wiki/Wavetable_synthesis#Confusion_...](https://en.wikipedia.org/wiki/Wavetable_synthesis#Confusion_with_sample-
based_synthesis_\(S&S\)_and_Digital_Wave_Synthesis)

~~~
Roboprog
So, it doesn’t have a Korg Wavestation built in? :-)

Check out something like Korg iWAVESTATION or u-he Zebralette for something
like wavetable (soft) synths, vs merely 1 or 2 layers of PCM samples possibly
with an envelope generator to fade between layers.

------
ChuckMcM
Very cool. I especially like the video encoder in the static ram chip. That is
a neat hack. I've got a simple HDMI interface in an FPGA that does something
similar but it is 10x the cost.

I expect to see a lot of these sorts of systems in the coming months/years.

------
mpax
While on the subject, handheld Arduino console:
[https://gamebuino.com](https://gamebuino.com)

Has anyone here tried it? I’m thinking of getting one.

~~~
alxmdev
I have a Meta and program little games for it in C. It's a lot of fun to code
for, especially if you like optimizing your code and pushing what you can
achieve within the system's limits. A lot of what you learn doing this applies
to general programming too (reworking calculations to avoid expensive
operations, judicious use of memory, etc.), which is a nice bonus.

~~~
mpax
That’s the idea :)

------
unwiredben
The assembly video
([https://basicengine.org/hardware.html#_assembly](https://basicengine.org/hardware.html#_assembly))
is really neat. I like how he made the SMT ICs easier to test by bringing out
all the pins to nearby pads. That lets you easily test for bridges and good
connections at the cost of board space.

------
Koshkin
I have played with a similar BASIC board [1] - it is indeed a lot of fun and
(unlike RPi) brings back the feel of first personal computers. One can easily
teach a kid programming using such a thing.

[1] [http://geoffg.net/maximite.html](http://geoffg.net/maximite.html)

------
wahern
I didn't realize it at the time, but I first learned to program using BASIC on
the TI-85. BASIC might be a poor language for learning computer science
concepts (or so I've heard others opine), but I haven't encountered a language
that was as approachable and intuitive.

------
pjmlp
Very nice, maybe there could be some inline Assembly as well, BBC Basic style.

In any case very well done!

------
bitwize
Sweet! It's like a fantasy console, but in real life.

------
agumonkey
will they make an esp32 basicstation ? :D

------
nine_k
Basic the language is nostalgic but not exactly great.

I hope Lua might be eventually added.

