p.konrad wrote
Hi
I tried it the same way but I didn't get rid of the comparison failures deleting the .hack file.
Could it be that decrementing R0 directly causes the problem?
Directly decrementing R0 will cause comparison failure. You can prevent this by putting '*' in the R0 column in the .cmp file.
| RAM[0] | RAM[1] | RAM[2] |
|**********| 0 | 0 |
|**********| 0 | 0 |
etc.
Better would be to copy RAM[0] to RAM[3] and use it as your counter.
--Mark