Best wire node


This code from block 1100 is loaded into node 614. Michael prompted me to write and test this version. It's the best we know: fastest and least power since its infinite loop does not include an instruction fetch. But it is not the shortest or simplest.

The word ether on the last line expects to load RAM. So one word of program must be compiled (. . . .).

init

The infinite loop has 2 unexts in the same instuction word: one in slot 2, another in slot 3. The first will count 3ffff down to 0 and discard the 0. The second will find 3ffff as its count and decrement it. Then the first will find 3fffe and count it down to 0. This repeats indefinitely, a wonderful application of the circular return stack.

The loop will repeat 256,143 times with one unext delay and then an extra unext delay is required.

The last instruction is loaded from the ether comm port. Its execution is never finished. The p register still has the comm port address. If the ether port was one of the data transfer ports, @p or !p could be used to save a register. That is, save the code required to load it. That's not possible in this instance: ether loads from left; data transfers from down to up.