To combine gates :
Or(And(x,y), z);
or
a = and(x,y);
b = or (a,z);
Same difference.
You can call each function with whatever vars you want :
a = and(x,y);
b = and(!y,z);
c = or(a,b);
And don't be too quick to use C logical operators to do the heavy lifting for you. If you're doing anything interesting with circuit sims you'll want more than 2 possible values for signals. Think X (undefined), Hi-Z, D and D' if you're doing some sort of test pattern generation and so on.



LinkBack URL
About LinkBacks


