My emulator prints output only 0

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

My emulator prints output only 0

AuCcH
In Or. chip
I coded like below
CHIP Or {
    IN a, b;
    OUT out;

    PARTS:
    Not(in=a, out=nota);
    Not(in=b, out=notb);
    And(a=nota, b=notb, out=w);
    Not(in=w, out=out);
}

but the HW Emulator make output only 0

Also In And.chip
I coded like this

CHIP And {
    IN a, b;
    OUT out;

    PARTS:
    Nand(a=a, b=b, out=c1);
    Not(in=c1, out=out);
}

It also prints ouput 0

What shoud I do?
Reply | Threaded
Open this post in threaded view
|

Re: My emulator prints output only 0

WBahn
Administrator
Does your Not chip work?
Reply | Threaded
Open this post in threaded view
|

Re: My emulator prints output only 0

AuCcH
Yeah, maybe does not work. All of the values of out are 0. So Simultor makes message that tells "Comparison failure
Reply | Threaded
Open this post in threaded view
|

Re: My emulator prints output only 0

AuCcH
In reply to this post by WBahn
 I'll try again. If it doesn't work, then I'll post message