move add and sub, shrink alu_hier box
authorLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Fri, 28 Feb 2020 10:08:04 +0000 (10:08 +0000)
committerLuke Kenneth Casson Leighton <lkcl@lkcl.net>
Fri, 28 Feb 2020 10:08:04 +0000 (10:08 +0000)
experiments5/doAlu16.py

index e90a8e9348f3489d5e3b594ae0dd34de3456cd8a..d6e51a45c9ea3866a26906eacbfe7b57ae4e21ee 100755 (executable)
@@ -431,18 +431,18 @@ def alu_hier_place(**kw):
 
   ab = Box( l(    0.0 )
           , l(    0.0 )
-          , l( 1200.0 )
+          , l( 1000.0 )
           , l(  600.0 ) )
 
   UpdateSession.open()
   cell.setAbutmentBox( ab )
 
-  transf = (l(20.0), l(100.0), Transformation.Orientation.ID)
+  transf = (l(50.0), l(100.0), Transformation.Orientation.ID)
   subi = createInstance(cell, "subckt_49_sub", sub)
   place( subi, transf[0], transf[1], transf[2] )
   print "sub place", subi
 
-  transf = (l(520.0), l(100.0), Transformation.Orientation.ID)
+  transf = (l(550.0), l(100.0), Transformation.Orientation.ID)
   addi = createInstance(cell, "subckt_48_add", add)
   place( addi, transf[0], transf[1], transf[2] )
   print "add place", addi
@@ -517,7 +517,7 @@ def alu_hier_route(**kw):
 
   ab = Box( l(    0.0 )
           , l(    0.0 )
-          , l( 1200.0 )
+          , l( 1000.0 )
           , l(  600.0 ) )
 
   cell.setAbutmentBox( ab )
@@ -549,17 +549,17 @@ def alu_hier_route(**kw):
   plugins.RSavePlugin.ScriptMain( **kw )
 
   print "cell", cell, dir(cell)
-  c = cell.getComponentsUnder(0)
-  print "components", c, dir(c)
-  c = cell.getSlaveInstances()
+  c = cell.getComponents()
   print "components", c, dir(c)
+  for child in cell.getInstances():
+      print "child", child
 
   return success
 
 
 if __name__ == '__main__':
-  #success      = add()
-  #success      = sub()
+  success      = add()
+  success      = sub()
   success      = alu_hier_place()
   success      = alu_hier_route()
   shellSuccess = 0