|
/**
* 4-way 16-bit multiplexor.
* out = a if sel==00
* b if sel==01
* c if sel==10
* d if sel==11
*/
CHIP Mux4Way16 {
IN a[16], b[16], c[16], d[16], sel[2];
OUT out[16];
PARTS:
// Put your code here:
Mux16(a=a[0..15],b=b[0..15],sel=sel[0],out=out1[0..15]);
Mux16(a=c[0..15],b=d[0..15],sel=sel[0],out=out2[0..15]);
Mux16(a=out1[0..15],b=out2[0..15],sel=sel[1],out=out[0..15]);
}
when I tried to load my hdl file to the program, the feedback at the bottom indicated out1[0..15]: sub bus of an internal node may not be used. Does this mean that I should do the 16 ways separately instead of combining them as a bus?
|