You could, in theory, describe all parameters of preprocessors macros as other macros and only getting content from literals and concatenations. That's quite interesting, almost like interpreting each macro as combination row/col in a normal source code file. I though about only taking such parameters and evaluating them later, but I couldn't come up with the discipline writing it this way. All in all it forces to always create different variants of basic commands like IF and so. I think about reducing it even more, giving only DEC for decrementing, NIL for null checks and JMP for jump on zero parameter. I'll backup my current work and alter it a bit to have exactly those commands under the hud. Maybe I can also replace the current FINF/FINFDP macros and simply them in notation to get a better overview about what's possible.

Cool stuff you can read on Wikipedia - learn a lot by what's theoretically possible and then notice that it's REALLY possible by implementing on your own. It's amazing what you can teach such a thing with only decrementing, checking and conditional jumping. The more I code using them, the more it becomes reality that I'll be able to a LEGO computer on a mechanical base but NXT-controlled input (you don't want to input the million commands it requires, trust me...). Only thing I don't know is how to archieve a comfortable memory system. A pure Turing machine is no real option since it requires just too many memory cells to make bigger programs. Instead, I'm thinking about another system of complete bytes as single cell with input/output "ports" to decrement and check it's value for null. That's relatively simply I think and could solve the seemingly common "where the put all the gears..." problem. Then you just need a machine in the middle that take control signals from the NXT - possibly with some memory cells on it's own you'd need to navigate to an absolute memory address.

Maybe it's a good idea to work more on how to combine the interfaces between NXT and other memory cells... Well, that's again too futuristic in terms of music. Let's put that idea away and do something different for diversities sake (though it might not last so long...).

No comments: