Re: Internal pin to bus
Posted by
cadet1620 on
URL: http://nand2tetris-questions-and-answers-forum.52.s1.nabble.com/Internal-pin-to-bus-tp4026005p4029910.html
true and
false can be used on the right side of any "=". This connects the pin, or all the pins if it is a bus, to one or zero.
Examples:
SomePart(a=true, ... ); // Single-bit input 'a' set to 1
SomePart16(a=true, ...); // 16-bit input 'a' all bits set to 1
SomePart16(a[0..6]=false, a[7]=true, a[8..15]=false, ...); // 16-bit input 'a' set to 128 decimal
--Mark