|
|
@ -31,7 +31,8 @@ class TechLib: |
|
|
|
"""Returns a pin list position for a given node kind and pin name.""" |
|
|
|
"""Returns a pin list position for a given node kind and pin name.""" |
|
|
|
if kind[:3] in ('OAI', 'AOI'): |
|
|
|
if kind[:3] in ('OAI', 'AOI'): |
|
|
|
if pin[0] == 'A': return int(pin[1]) - 1 |
|
|
|
if pin[0] == 'A': return int(pin[1]) - 1 |
|
|
|
if pin[0] == 'B': return int(pin[1]) + int(kind[4]) - 1 |
|
|
|
if pin == 'B': return int(kind[3]) |
|
|
|
|
|
|
|
if pin[0] == 'B': return int(pin[1]) - 1 + int(kind[3]) |
|
|
|
for prefix, pins, index in [('HADD', ('B0', 'SO'), 1), |
|
|
|
for prefix, pins, index in [('HADD', ('B0', 'SO'), 1), |
|
|
|
('MUX21', ('S', 'S0'), 2), |
|
|
|
('MUX21', ('S', 'S0'), 2), |
|
|
|
('MX2', ('S0',), 2), |
|
|
|
('MX2', ('S0',), 2), |
|
|
|