https://gopher.floodgap.com/gopher/gw?a=gopher%3A%2F%2Fthelambdalab.xyz%2F1cuneiforth%2F
___ _ ___ _ _
/ __| _ _ _ ___(_) __|__ _ _| |_| |_
| (_| || | ' \/ -_) | _/ _ \ '_| _| ' \
\___\_,_|_||_\___|_|_|\___/_| \__|_||_|
--=[ A programming puzzle ]=--
You and your team of 23rd century archaeologists have been digging for
days with no result, but it seems your efforts have finally been
rewarded. You stand before what looks to be a rusty shipping container
with large letters scratched into its side. The letters read:
"The Archive of Late 20th Century Computing"
Giddy with excitement, you wrench open the door and step inside.
The container is filled with crumbling plastic boxes. Inspecting a
few, they appear to be packed full of optical disks of some
kind. Picking one such disk out at random, you see that it has a label
affixed to the front. Happily you find that you can understand the
text - your study of the languages of the ancients has paid off,
it seems.
Roughly translated, the label reads as follows...
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
"This disk contains FORTH, an early interactive environment for
writing and running computer programs.
"The data on this disk is engraved as a series of bits, or zeros (0)
and ones (1), in a clockwise spiral, starting from the outer rim, and
can be read with an optical microscope.
"The first 350'208 bits on this disk contain a document, encoded as a
black and white bitmap image, 684 pixels in width and 512 pixels in
height. The bits correspond to pixels as follows:
bits: 0 1 683
v v v
+--------------------------+
| | | ... ... | |
|--------------------------|
684->| | ... |
|--------------------------|
| |
| |
| |
| |
|--------------------------|
349524->| | ... ... | |<-350207
+--------------------------+
"That document explains how to interpret the rest of the bits."
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Intrigued, you immediately take the disk back to your field office
and, using your trusty OptoScanner 5000 (tm) you extract the bits
from the disk:
[disk.img]
You decide to spend the rest of the afternoon getting this ancient
software running again!
--=[ What is this? ]=--
Cuneiforth is my attempt to write a self-contained FORTH computing
environment for the "single page" Chifir computer conceived by Nguyen
and Kay [1] as part of their Cuneiform system for software
preservation. With the information above, it should hopefully be
possible for someone with a modest amount of programming experience to
extract the bitmap document from the binary disk image (linked above),
program an emulator to emulate the Chifir machine it describes, and
use it to get the FORTH system contained in the image running.
If this sounds at all like fun to you, I'd love it if you gave this
a try! The Chifir machine is explicitly designed to be easy to
describe and emulate, but that doesn't necessarily mean that it is.
The proof of the pudding is in the eating, as they say.
As additional motivation, Cuneiforth is designed to be extensible and
programmable from within. It has a small built-in help system, a
built-in editor, and built-in instructions for setting up persistent
storage. It's far from perfect, but you might find it's a fun toy to
mess around with and write programs for, even after you've solved the
puzzle.
That said, Cuneiforth is only a hobby project and I not a professional
programmer. If you are looking for a well-designed VM-based computer
to build real things, Uxn/Varvara [6] or DuskOS [5], are _far_ more
likely to be what you want.
Anyway, if you do give this puzzle a go, please let me know how you
get on! You can either leave a comment in the guestbook below or just
email me at plugd@thelambdalab.xyz. I'm very curious to learn whether
it's even possible for you to get this running with only the
disk image and the "label" text above!