From 93a0858d2f6cb959af078fc7a28e74ad7be4cd57 Mon Sep 17 00:00:00 2001 From: Stefan Holst Date: Mon, 16 Jan 2023 17:37:41 +0900 Subject: [PATCH] oai and aoi pin handling fix --- src/kyupy/techlib.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/kyupy/techlib.py b/src/kyupy/techlib.py index 21c82a6..0ceb8cc 100644 --- a/src/kyupy/techlib.py +++ b/src/kyupy/techlib.py @@ -31,7 +31,8 @@ class TechLib: """Returns a pin list position for a given node kind and pin name.""" if kind[:3] in ('OAI', 'AOI'): 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), ('MUX21', ('S', 'S0'), 2), ('MX2', ('S0',), 2),