Tuesday, 14 April 2020

New commands

I want to add 3 commands, which I think are quite neat, and I've only ever seen on this machine (the British machine, the CPC464).

They are EVERY AFTER and a means for resetting them. They are timers, that call a procedure either on a regular basis, or after a one off event. So on a CPC you'd write something like

EVERY 40,0 GOSUB 1000

Which would GOSUB 1000 every 40 ticks, which on the CPC is 50th of a second using timer 0. AFTER does the same thing, except it just fires once. I'll probably use CLEAR <n> to reset/clear the timer. You do have to be quite careful because of problems with code not being predictable. But it'll be quite useful.

So adding this will push it from version 0.69b to 0.70 and then I'll add the RPL() compiler which will push it to 0.80

No comments:

Post a Comment

Breaking change

We all make mistakes. One early mistake I made was copying (partly) the old thing in Microsoft BASIC where you didn't have to declare ...