BINSIC plotting working

At the risk of being attacked as an enemy of all that is good, I have to confess to being less than riveted by the Olympics, so far. So I have made far more productive use of my time in seeking to recreate the computing experience of 30 years ago – by working some more on BINSIC – Binsic Is Not Sinclair Instruction Code, my reimplementation of Sinclair ZX81 BASIC.

I have finally got PLOT and UNPLOT to work – not on the same screen as ordinary output, but on a separate graphics console.

Game of Life on BINSIC graphics consoleAs the above – from Conway’s Game of Life –  shows, this has all the sophistication and élan of the original ZX81 experience!

It’s just in the Git repo now (at Github under mcmenaminadrian) but an executable JAR will follow shortly.


Relive the ZX81 experience on your desktop

BINSIC – my reimplementation of ZX80 or ZX81 (Timex Sinclair 1000 or 1500 for US readers) BASIC is now available for download in binary form – look at the page on the site: Binsic Is Not Sinclair Instruction Code.

It comes with Conway’s Game of Life for the authentic black and white text based feel too.

(Source code is also available here)

Progress with BINSIC

BINSIC – Binsic Is Not Sinclair Instruction Code – my effort to re-implement Sinclair ZX80/ZX81 BASIC as a domain specific language via Groovy (and eventually a runnable Java JAR file), is making more progress.

ZX80 + bubble TV = modernist bliss (p1120918)
ZX80 + bubble TV = modernist bliss (p1120918) (Photo credit: acb)

Right now it supports:

IF ... THEN ... ELSE
FOR ... TO ... STEP ... NEXT
DIM A(x, y, z) (and array derefencing)

Still one or two difficult areas to get through and I have had to make one compromise – unlike on the ZX80 one cannot have a variable and an array with the same letter designation – just too difficult to implement on Java/Groovy.

But, it’s getting there…

Another software death march begins…

I have a new software project now … BINSIC … Binsic Is Not Sinclair Instruction Code.

Sinclair (Photo credit: mofetos)

Instead Binsic is my attempt to reimplement Sinclair’s ZX80/ZX81 BASIC (with a few pieces that were deeply frustrating through their absence all those years ago) as domain specific language using Groovy.

I have spent a fair bit of yesterday and today on this and have not got very far as yet … not even enough to pin up a few dozen lines of code on GitHub.

I have been spending my time trying to get the PRINT command to work. And, well, it doesn’t. I can print some things, but generally only by imposing constraints on the language that were not there in BASIC and so are self-defeating.

And I haven’t even begun to think seriously about how I can tackle the line number problem.

In the meantime, if you know about Groovy and DSLs, you could help me enormously by having a look at this question I have posted on StackOverflow.

A reason why kids don’t do programming any more?

As I write this, in the next room my two daughters are playing with their Wii, with the eldest using her Andorid phone to provide incidental music. It’s a not untypical Saturday morning scene in millions of homes I imagine.

In here I am contemplating one of the legacies of my teenage years – the desire to write a computer program for no other reason than I enjoy it.

The immediate problem I face with the current piece of code is user interface related and that does make me wonder if one of the reasons kids have lost interest in programming is (alongside the awful way they are taught about computers) the sheer hideousness of UI code.

Back in the days of Sinclair (or BBC) BASIC things could be made to appear on the screen by simply specifying their cartesian co-ordinates and issuing a PLOT command or similar.

So, I could get back from my A level maths class and plot the graphs of the functions we’d been discussing in a few lines of code. I could write, and graphically represent, the behaviour of heat quanta in a molecular grid with just a few hours work.

Now I would have to set aside a day to do the graph from scratch or use somebody else’s code. The heat quanta representation boggles the mind.

I can understand why the makers of the Raspberry Pi seem to be recreating the BBC Micro environment alongside the electronics: all this UI code just gets in the way of helping kids build useful software.