On Sun, 20 Jan 2013 15:28:17 +0100, =?ISO-8859-15?Q?J=F6rg_Hoppe?=
<
j_h...@t-online.de> wrote:
>>When the decision was made to decommission it, I wrote a LIGHTS
>>program and added it to the system startup, which amused some
>>of the operators.
>Would you hand it over? The SimH behind my panel could use some light
>effect programs in the near future.
I don't know if I still have it. If I do, it's on media that I
can't access easily.
The LIGHTS UUO wasn't supported for the KL, which had no front
panel. On the KI, the LIGHTS UUO only controlled the lights of
the data switchs -- that's one row of 36 lights.
The program worked by using the LIGHTS UUO in a loop that set a
pattern in the lights, sleeping for a fraction of a second (say
about 200 milliseconds), then changing the pattern slightly. This
can create the illusion of moving lights. The ROT and LSH
instructions get used a lot.
One simple pattern is a single light that moves down row and then
"jumps" back to the beginning when it reaches the end. It looks
like single light that goes round and round. A slightly different
pattern is to have the light "bounce" back and move the other way
when it reaches the end of the row. A variation on either of
these is to increase the number of lit bulbs with each loop. So
first one light seems to travel the length of row. At the end it
travels the other direction, but now it's two lights. It reverses
again and becomes three lights. Eventually more bulbs are lit
than not, and it appears to be a dark spot moving back and forth.
This can be reversed to start with one unlit bulb and reducing the
number of lit bulbs with each iteration. All pretty simple stuff.
My program had several different patterns. Every two or three
minutes it would change and pick another one at random. From time
to time I would add a new pattern.