lib = Library.create(rootlib, 'LibreSOCMem')
- cell = Cell.create(lib, 'real_sram')
+ cell = Cell.create(lib, 'spblock_512w64b8w')
with UpdateSession():
cell.setAbutmentBox(Box(
- u(0.0), u(0.0), u(110.0), u(100.0),
+ u(0.0), u(0.0), u(110.0), u(2.5),
))
nets = {
'*': Net.create(cell, '*'),
'clk': Net.create(cell, 'clk'),
- 'vdd': Net.create(cell, 'vdd'),
- 'vss': Net.create(cell, 'vss'),
+ #'vdd': Net.create(cell, 'vdd'),
+ #'vss': Net.create(cell, 'vss'),
}
- for name, qty in (('a', 8),
- ('d', 63),
- ('q', 63),
+ for name, qty in (('a', 9),
+ ('d', 64),
+ ('q', 64),
('we', 8),
):
for i in range(qty):
x = 0.135*20
wid = 0.135 / 2
step = wid*10
- for name, qty in (('a', 8),
- ('d', 63),
- ('q', 63),
+ for name, qty in (('a', 9),
+ ('d', 64),
+ ('q', 64),
('we', 8),
):
for i in range(qty):
tech, net, 'pimplant',
((0.115,0.195),(0.115,0.365),(0.285,0.365),(0.285,0.195),(0.115,0.195)),
)
- net = nets['vss']
- createRL(
- tech, net, 'pwell',
- ((-0.12,-0.32),(-0.12,1.92),(1.72,1.92),(1.72,-0.32),(-0.12,-0.32)),
- )
- createRL(
- tech, net, 'metal1',
- ((0.0,0.0),(0.0,0.48),(1.6,0.48),(1.6,0.0),(0.0,0.0)),
- )
if False:
- Vertical.create(
- net, tech.getLayer('metal1.pin'),
+ net = nets['vss']
+ createRL(
+ tech, net, 'pwell',
+ ((-0.12,-0.32),(-0.12,1.92),(1.72,1.92),(1.72,-0.32),(-0.12,-0.32)),
+ )
+ createRL(
+ tech, net, 'metal1',
+ ((0.0,0.0),(0.0,0.48),(1.6,0.48),(1.6,0.0),(0.0,0.0)),
+ )
+ if False:
+ Vertical.create(
+ net, tech.getLayer('metal1.pin'),
+ u(0.8), u(1.6), u(0.0), u(0.48),
+ )
+ pin = Vertical.create(
+ net, tech.getLayer('metal1'),
u(0.8), u(1.6), u(0.0), u(0.48),
)
- pin = Vertical.create(
- net, tech.getLayer('metal1'),
- u(0.8), u(1.6), u(0.0), u(0.48),
- )
- net.setExternal(True)
- NetExternalComponents.setExternal(pin)
- createRL(
- tech, net, 'active',
- ((0.12,0.2),(0.12,0.36),(0.28,0.36),(0.28,0.2),(0.12,0.2)),
- )
- createRL(
- tech, net, 'active',
- ((0.9625,0.3075),(1.0375,0.3075),(1.0375,0.3825),(0.9625,0.3825),(0.9625,0.3075)),
- )
- createRL(
- tech, net, 'contact',
- ((0.1675,0.2475),(0.2325,0.2475),(0.2325,0.3125),(0.1675,0.3125),(0.1675,0.2475)),
- )
- createRL(
- tech, net, 'contact',
- ((0.9675,0.3125),(1.0325,0.3125),(1.0325,0.3775),(0.9675,0.3775),(0.9675,0.3125)),
- )
+ net.setExternal(True)
+ NetExternalComponents.setExternal(pin)
+ createRL(
+ tech, net, 'active',
+ ((0.12,0.2),(0.12,0.36),(0.28,0.36),(0.28,0.2),(0.12,0.2)),
+ )
+ createRL(
+ tech, net, 'active',
+ ((0.9625,0.3075),(1.0375,0.3075),(1.0375,0.3825),(0.9625,0.3825),(0.9625,0.3075)),
+ )
+ createRL(
+ tech, net, 'contact',
+ ((0.1675,0.2475),(0.2325,0.2475),(0.2325,0.3125),(0.1675,0.3125),(0.1675,0.2475)),
+ )
+ createRL(
+ tech, net, 'contact',
+ ((0.9675,0.3125),(1.0325,0.3125),(1.0325,0.3775),(0.9675,0.3775),(0.9675,0.3125)),
+ )
net = nets['*']
createRL(
tech, net, 'active',
((1.105,3.8),(1.4375,3.8),(1.4375,2.2),(0.9625,2.2),(0.9625,3.8),(1.105,3.8)),
)
- net = nets['vdd']
- createRL(
- tech, net, 'nwell',
- ((-0.12,1.92),(-0.12,4.32),(1.72,4.32),(1.72,1.92),(-0.12,1.92)),
- )
- createRL(
- tech, net, 'metal1',
- ((0.0,3.52),(0.0,4.0),(1.6,4.0),(1.6,3.52),(0.0,3.52)),
- )
if False:
- Vertical.create(
- net, tech.getLayer('metal1.pin'),
+ net = nets['vdd']
+ createRL(
+ tech, net, 'nwell',
+ ((-0.12,1.92),(-0.12,4.32),(1.72,4.32),(1.72,1.92),(-0.12,1.92)),
+ )
+ createRL(
+ tech, net, 'metal1',
+ ((0.0,3.52),(0.0,4.0),(1.6,4.0),(1.6,3.52),(0.0,3.52)),
+ )
+ if False:
+ Vertical.create(
+ net, tech.getLayer('metal1.pin'),
+ u(0.8), u(1.6), u(3.52), u(4.0),
+ )
+ pin = Vertical.create(
+ net, tech.getLayer('metal1'),
u(0.8), u(1.6), u(3.52), u(4.0),
)
- pin = Vertical.create(
- net, tech.getLayer('metal1'),
- u(0.8), u(1.6), u(3.52), u(4.0),
- )
- net.setExternal(True)
- NetExternalComponents.setExternal(pin)
- createRL(
- tech, net, 'active',
- ((0.52,3.6),(0.52,3.76),(0.68,3.76),(0.68,3.6),(0.52,3.6)),
- )
- createRL(
- tech, net, 'active',
- ((0.9625,3.5675),(1.0375,3.5675),(1.0375,3.7825),(0.9625,3.7825),(0.9625,3.5675)),
- )
- createRL(
- tech, net, 'active',
- ((0.1625,3.6025),(0.2375,3.6025),(0.2375,3.6775),(0.1625,3.6775),(0.1625,3.6025)),
- )
- createRL(
- tech, net, 'contact',
- ((0.5675,3.6475),(0.6325,3.6475),(0.6325,3.7125),(0.5675,3.7125),(0.5675,3.6475)),
- )
- createRL(
- tech, net, 'contact',
- ((0.9675,3.5725),(1.0325,3.5725),(1.0325,3.6375),(0.9675,3.6375),(0.9675,3.5725)),
- )
- createRL(
- tech, net, 'contact',
- ((0.9675,3.7125),(1.0325,3.7125),(1.0325,3.7775),(0.9675,3.7775),(0.9675,3.7125)),
- )
- createRL(
- tech, net, 'contact',
- ((0.1675,3.6075),(0.2325,3.6075),(0.2325,3.6725),(0.1675,3.6725),(0.1675,3.6075)),
- )
+ net.setExternal(True)
+ NetExternalComponents.setExternal(pin)
+ createRL(
+ tech, net, 'active',
+ ((0.52,3.6),(0.52,3.76),(0.68,3.76),(0.68,3.6),(0.52,3.6)),
+ )
+ createRL(
+ tech, net, 'active',
+ ((0.9625,3.5675),(1.0375,3.5675),(1.0375,3.7825),(0.9625,3.7825),(0.9625,3.5675)),
+ )
+ createRL(
+ tech, net, 'active',
+ ((0.1625,3.6025),(0.2375,3.6025),(0.2375,3.6775),(0.1625,3.6775),(0.1625,3.6025)),
+ )
+ createRL(
+ tech, net, 'contact',
+ ((0.5675,3.6475),(0.6325,3.6475),(0.6325,3.7125),(0.5675,3.7125),(0.5675,3.6475)),
+ )
+ createRL(
+ tech, net, 'contact',
+ ((0.9675,3.5725),(1.0325,3.5725),(1.0325,3.6375),(0.9675,3.6375),(0.9675,3.5725)),
+ )
+ createRL(
+ tech, net, 'contact',
+ ((0.9675,3.7125),(1.0325,3.7125),(1.0325,3.7775),(0.9675,3.7775),(0.9675,3.7125)),
+ )
+ createRL(
+ tech, net, 'contact',
+ ((0.1675,3.6075),(0.2325,3.6075),(0.2325,3.6725),(0.1675,3.6725),(0.1675,3.6075)),
+ )
net = nets['*']
createRL(
tech, net, 'active',