Uri Shaked
02/18/2025, 5:52 PMTim Edwards
02/18/2025, 8:22 PMsky130/magic/sky130.tcl
lines 6829 and following define how to draw the SONOS device. This is really just the standard MOSFET drawing routine with a few different dimensions:
proc sky130::sky130_fd_bs_flash__special_sonosfet_star_draw {parameters} {
set newdict [dict create \
gate_type nsonos \
diff_type ndiff \
diff_contact_type ndc \
plus_diff_type psd \
plus_contact_type psc \
poly_type poly \
poly_contact_type pc \
sub_type psub \
id_type dnwell \
id_surround 1.355 \
min_effl 0.185 \
min_allc 0.26 \
]
set drawdict [dict merge $sky130::ruleset $newdict $parameters]
return [sky130::mos_draw $drawdict]
}
It presumably needs a value added to newdict
gate_to_diffcont <something> \
The default is 0.145 (see line 61), so you need to measure the amount by which the device is in error and add that to 0.145 and it should then be drawn correctly.Uri Shaked
02/18/2025, 9:21 PMTim Edwards
02/18/2025, 9:24 PMUri Shaked
02/19/2025, 6:22 AM