Comparison failure at line 1

Posted by gs99 on
URL: http://nand2tetris-questions-and-answers-forum.52.s1.nabble.com/Comparison-failure-at-line-1-tp4026071.html

I’m testing my own chip and get “Comparison failure at line 1” after initial Single Step.

The .hdl file starts:
CHIP CtlZ16 {
    IN in[16], z;
    OUT out[16];

    PARTS:
    CtlZ(in=in[0], z=z, out=out[0]);


The .tst file starts:
load CtlZ16.hdl,
output-file CtlZ16.out,
compare-to CtlZ16.cmp,
output-list z%B1.1.1 in%B1.16.1 out%B1.16.1;

set z 0,


When I Single Step, it executes the first command, stopping at line set z 0,
Message appears: Comparison failure at line 1

I continue stepping. Output looks good.
At the end, another message appears: End of script – Comparison failure at line 1.

Can you say why the error message appears?