Real-Time Multi-Tasking (Multi-Threaded) BASIC programming language

Wizardry designed 3 generations of customer-purposed industrial control boards for one important customer.
The most recent 2 versions are user-programmable using a real-time multi-tasking (multi-threaded) BASIC programming language.
"Real-time" refers to the language's support for interrupts from sources such as:
Logic-inputs
Timers.
Pulse-counters.
A2D (Analog-to-Digital) measurements.
Messages received from the LAN (Local Area Network).
Various error events.
"Multi-tasking" refers to the language's support simultaneous execution of multiple threads:
Fork-like task creation passes variable-environment to new task.
All tasks share global ('public') variables.
Tasks have local ('private') variables.
Atomic asignment of variables.
Atomic operations on timers, hardware counters.
Wizardry wrote a Compiler in C / BISON / YACC to extend this language, with features like:
Syntax checking with clear error messages.
Hides line-numbering from programmer (line#s are required by legacy target machines).
Allows meaningful labels & variable names, & hides many other details of the language.
Provides macro functionality.
Allows manipulation of old programs, such as conversion from line-numbers to line-labels.
Makes management & refactoring of large programs feasible.
Very simple code example:
	' --------------------------------------------------------------
	' INITIALIZE & WAIT FOR INVERTER TO GET READY
	' --------------------------------------------------------------
	autostart			'this program automatically starts on powerup/reset

	task goto BlinkLights		'start a thread to blink a light

InitLoop
	DRIVE(1)=0
	SPEED(1)=0
	DRIVECLEAR(1)
	IF DRIVEERROR(1) THEN GOTO InitLoop

	' --------------------------------------------------------------
	' LOOP FOREVER, STARTING & STOPPING MOTOR
	' --------------------------------------------------------------
MainLoop

	' ACCELERATE TO 1500 RPM, THEN WAIT 5 SECONDS
	PRINT "STARTING"
	DRIVE(1)=1
	SPEED(1)=1500
	GOSUB WaitForAtSpeedSub
	WAIT 5000

	' STOP, WAIT 5 SECONDS, THEN START WHOLE SEQUENCE AGAIN
	PRINT "STOPPING"
	SPEED(1)=0
	GOSUB WaitForAtSpeedSub
	WAIT 5000
	GOTO MainLoop

	' --------------------------------------------------------------
	' SUBROUTINE TO WAIT UNTIL AT-SPEED, THEN PRINT A MESSAGE & RETURN
	' --------------------------------------------------------------
WaitForAtSpeedSub
LoopingUntilAtSpeed
	IF DRIVEATSPEED(1)=0 THEN GOTO LoopingUntilAtSpeed
	PRINT "AT-SPEED ", SPEED(1)
	RETURN

	' --------------------------------------------------------------
	' TASK TO BLINK A LIGHT
	' --------------------------------------------------------------
BlinkLights
	T#=100				'time-on & time-off is this many milliseconds
	L#=32				'this output controls the light
loopBlinkLights
	TURNON L#
	WAIT T#
	TURNOFF L#
	WAIT T#
	goto loopBlinkLights