add naming and pin-order reverse option
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Thu, 10 Jun 2021 21:06:08 +0000 (22:06 +0100)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Thu, 10 Jun 2021 21:06:08 +0000 (22:06 +0100)
src/spec/ifaceprint.py
src/spec/interfaces.py

index 7ac7a26f9d03c56c7edc27806baf0866bb213545..4a4104f41ded15c4acef89733e56dc6e62ec9909 100644 (file)
@@ -22,6 +22,17 @@ def create_sv(fname, pins):
                         (woffs+width-scale*12, hoffs+height-scale*12),
             stroke=svgwrite.rgb(255, 255, 16, '%'),
             stroke_width=scale/10.0))
+
+    dwg.add(dwg.text("Libre-SOC ls180",
+                       insert=(woffs+width/2-scale*5, woffs+height/2),
+                     fill='white'))
+    dwg.add(dwg.text("In collaboration with LIP6.fr",
+                       insert=(woffs+width/2-scale*5, woffs+height/2+scale),
+                     fill='white'))
+    dwg.add(dwg.text("Cell Libraries by Chips4Makers",
+                       insert=(woffs+width/2-scale*5, woffs+height/2+scale*2),
+                     fill='white'))
+
     for i, pin in enumerate(pins['pads.west']):
         ht = hoffs + height - (i * scale) + scale*0.5
         dwg.add(dwg.line((woffs-scale*2, ht-scale*0.5),
index f66e474d4a9d8a52a7768e920da50e753bf3e99e..744f80333985aadb1163fc24bb06e954f83a6ad0 100644 (file)
@@ -64,7 +64,8 @@ class PinGen(object):
         self.fname = fname
 
     def __call__(self, suffix, offs, mux,
-                 start=None, limit=None, spec=None, origsuffix=None):
+                 start=None, limit=None, spec=None, origsuffix=None,
+                 rev=False):
         bank = offs[0]
         pf = self.pinfn(suffix, bank)
         print "pf", suffix, bank, pf
@@ -80,6 +81,9 @@ class PinGen(object):
         sk = "%s:%s" % (self.fname, str(suffix))
         print "pingroup pre", sk, pingroup
         pingroup = pingroup[start:limit]  # see comment in spec.pinfunctions
+        if rev:
+            # reverse order of pingroup
+            pingroup.reverse()
         print "pingroup post", sk, pingroup
         if self.pinouts.byspec.has_key(sk):
             self.pinouts.byspec[sk] += pingroup