diff options
author | David Shah <dave@ds0.me> | 2018-12-14 13:41:28 +0000 |
---|---|---|
committer | David Shah <dave@ds0.me> | 2019-03-22 10:31:54 +0000 |
commit | 1780f42b9a7854a8a7bf1f2d6589d3d35f133f87 (patch) | |
tree | 2e668d93ac8b58b908ef32667f689b5a5718af60 /ice40/examples/floorplan/floorplan.py | |
parent | 0118ac00c45c725a42b16697d1ac975f1be6f3b9 (diff) | |
download | nextpnr-1780f42b9a7854a8a7bf1f2d6589d3d35f133f87.tar.gz nextpnr-1780f42b9a7854a8a7bf1f2d6589d3d35f133f87.tar.bz2 nextpnr-1780f42b9a7854a8a7bf1f2d6589d3d35f133f87.zip |
ice40: Add examples folder including floorplan example
Signed-off-by: David Shah <dave@ds0.me>
Diffstat (limited to 'ice40/examples/floorplan/floorplan.py')
-rw-r--r-- | ice40/examples/floorplan/floorplan.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ice40/examples/floorplan/floorplan.py b/ice40/examples/floorplan/floorplan.py new file mode 100644 index 00000000..85c53ccd --- /dev/null +++ b/ice40/examples/floorplan/floorplan.py @@ -0,0 +1,5 @@ +ctx.createRectangularRegion("osc", 1, 1, 1, 4) +for cell, cellinfo in ctx.cells: + if "ringosc" in cellinfo.attrs: + print("Floorplanned cell %s" % cell) + ctx.constrainCellToRegion(cell, "osc") |