
This post was updated on .
Thanks Mark!
That works, but for some of the more complex chips I am running into really long code. Is there any way to loop internal pins, or create an array of internal pins without doing it all in an external program and copying and pasting the lines? Below I have shown an example. Is there any way syntaxwise to make this program smaller?
Thanks again,
IN a[16], b[16], tofu;
OUT out[16];
PARTS:
Foo(in = tofu, out = n0);
Foo(in = tofu, out = n1);
Foo(in = tofu, out = n2);
Foo(in = tofu, out = n3);
Foo(in = tofu, out = n4);
Foo(in = tofu, out = n5);
Foo(in = tofu, out = n6);
Foo(in = tofu, out = n7);
Foo(in = tofu, out = n8);
Foo(in = tofu, out = n9);
Foo(in = tofu, out = n10);
Foo(in = tofu, out = n11);
Foo(in = tofu, out = n12);
Foo(in = tofu, out = n13);
Foo(in = tofu, out = n14);
Foo(in = tofu, out = n15);
Moo(a = a[0], b = n0, out = x0);
Moo(a = a[1], b = n1, out = x1);
Moo(a = a[2], b = n2, out = x2);
Moo(a = a[3], b = n3, out = x3);
Moo(a = a[4], b = n4, out = x4);
Moo(a = a[5], b = n5, out = x5);
Moo(a = a[6], b = n6, out = x6);
Moo(a = a[7], b = n7, out = x7);
Moo(a = a[8], b = n8, out = x8);
Moo(a = a[9], b = n9, out = x9);
Moo(a = a[10], b = n10, out = x10);
Moo(a = a[11], b = n11, out = x11);
Moo(a = a[12], b = n12, out = x12);
Moo(a = a[13], b = n13, out = x13);
Moo(a = a[14], b = n14, out = x14);
Moo(a = a[15], b = n15, out = x15);
Moo(a = b[0], b = tofu, out = y0);
Moo(a = b[1], b = tofu, out = y1);
Moo(a = b[2], b = tofu, out = y2);
Moo(a = b[3], b = tofu, out = y3);
Moo(a = b[4], b = tofu, out = y4);
Moo(a = b[5], b = tofu, out = y5);
Moo(a = b[6], b = tofu, out = y6);
Moo(a = b[7], b = tofu, out = y7);
Moo(a = b[8], b = tofu, out = y8);
Moo(a = b[9], b = tofu, out = y9);
Moo(a = b[10], b = tofu, out = y10);
Moo(a = b[11], b = tofu, out = y11);
Moo(a = b[12], b = tofu, out = y12);
Moo(a = b[13], b = tofu, out = y13);
Moo(a = b[14], b = tofu, out = y14);
Moo(a = b[15], b = tofu, out = y15);
Sho(a = x0, b = y0, out = out[0]);
Sho(a = x1, b = y1, out = out[1]);
Sho(a = x2, b = y2, out = out[2]);
Sho(a = x3, b = y3, out = out[3]);
Sho(a = x4, b = y4, out = out[4]);
Sho(a = x5, b = y5, out = out[5]);
Sho(a = x6, b = y6, out = out[6]);
Sho(a = x7, b = y7, out = out[7]);
Sho(a = x8, b = y8, out = out[8]);
Sho(a = x9, b = y9, out = out[9]);
Sho(a = x10, b = y10, out = out[10]);
Sho(a = x11, b = y11, out = out[11]);
Sho(a = x12, b = y12, out = out[12]);
Sho(a = x13, b = y13, out = out[13]);
Sho(a = x14, b = y14, out = out[14]);
Sho(a = x15, b = y15, out = out[15]);
