Re: Some Generic Questions
Posted by cadet1620 on
URL: http://nand2tetris-questions-and-answers-forum.52.s1.nabble.com/Some-Generic-Questions-tp4032480p4032485.html
There is no way for a program to halt the Hack CPU. (The hardware "reset" signal does halt the CPU by holding the PC at 0.)
In project 12 you will be writing the "OS" for the Hack computer in the Jack language. It includes Sys.halt() which is documented as "halts the program execution". The implementation of Sys.halt() is simply a while(true) loop.