Read a value from the nerve connected to your central nervous system (CNS) and relay it to the nerve connected to your arm (ARM), clamping the value so that it never goes below -120 or above 50. Repeat ad infinitum.
Since this task takes place inside a network you control— that is, your own body— it is not necessary to leave no trace. Your EXAs should be written to operate indefinitely.
Note that #NERV is a hardware register, not a file. You can use it directly in your code like any other register.
For more information about the phage see "Debugging the Phage" in the first issue of the zine.
XA (global)
LINK 800
MARK LOOP
COPY #NERV X
TEST X < -120
TJMP CLAMP_DOWN
TEST X > 50
TJMP CLAMP_UP
COPY X M
JUMP LOOP
MARK CLAMP_DOWN
COPY -120 M
JUMP LOOP
MARK CLAMP_UP
COPY 50 M
JUMP LOOP
XB (global)
LINK 800
LINK 1
LINK 1
LINK 1
LINK 1
MARK LOOP
COPY M #NERV
JUMP LOOP
Cycles | Size | Activity |
---|---|---|
241 | 23 | 6 |