Re: Input descriptor

Posted by cadet1620 on
URL: http://nand2tetris-questions-and-answers-forum.52.s1.nabble.com/Input-descriptor-tp3469861p3470387.html

Veiniuks wrote
Trying to implement a single input to a two input gate and get an "unknown variable:in" error

Tried:

IN a;
OUT out;
PARTS:
"Gate Name"(a=a, b=a, out=out)

Any tips would be appreciated.  Thank you in advance for your time.
The "unknown variable:in" message is coming from the test script file.  It expects that your implementation of the chip has the same IN and OUT names as the provided stub file.  You want to write:
    IN in; 
    OUT out;
    PARTS:
    "Gate Name"(a=in, b=in, out=out);

--Mark