I know this is an ancient post.... but here's my "solution" to this problem, just for a giggle...
START
set ram2 1 # Start with output 1
wait:
tsteq op1[1000] 1 # Test each output has been on for required time
set op1 0 # and turn them off when expired
tsteq op2[1000] 1
set op2 0
tsteq op3[1000] 1
set op3 0
tsteq op4[1000] 1
set op4 0
tstlt cts ram1 # check the time now against the "next station" time
goto wait # loop, just checking outputs until it is
rotl ram2 1 ram2 # Select the next output
tstgt ram2 8 # if it has stepped past station 4 (1, 2, 4, 8)
set ram2 1 # then reset to station 1
set allouts ram2 # set all the outputs
add cts 5 ram1 # Add your required wait time
goto wait # and return to the wait loop
end
This is set to 1 second pulses (the [1000] in each output test), and 5 seconds per output (the "add cts 5" line), but can be changed to whatever. This is fast so you can observe it in operation.
Question to CAI:
why can't we use a variable in the time field?
It would be great to be able to have
TSTEQ OP1[UROM1] 1
SET OP1 0
for a easily altered variable time delay! (if not UROM1 then at least a RAM or VAR)
The compiler permits it, but the code doesn't run.