google / gf180mcu-pdk

PDK for GlobalFoundries' 180nm MCU bulk process technology (GF180MCU).
https://gf180mcu-pdk.rtfd.io
Apache License 2.0
364 stars 53 forks source link

MOSFET Multipliers not accounted for, in SPICE Simulation #88

Closed nataraj-pinakapani closed 1 year ago

nataraj-pinakapani commented 1 year ago

Expected Behavior

For a MOSFET, when m=2 is specified in the SPICE Netlist, the drain current in saturation must be almost twice compared to m=1 In the given SPICE netlist I(VD2) must be twice I(VD1)

Actual Behavior

I(VD2) and I(VD1) are almost the same. This means the drain current remains the same irrespective of the value of m.

Steps to Reproduce the Problem

SPICE Netlist

sch_path: /home/nataraj/projects/designmyic/cad/gf180mcu_invoke/xschem/sch_lib/nmos_3p3_test.sch .subckt nmos_3p3_test XM1 D G GND GND nmos_3p3 L=1u W=1u nf=1 ad='int((nf+1)/2) W/nf 0.18u' as='int((nf+2)/2) W/nf 0.18u' pd='2int((nf+1)/2) (W/nf + 0.18u)' ps='2int((nf+2)/2) (W/nf + 0.18u)' nrd='0.18u / W' nrs='0.18u / W' sa=0 sb=0 sd=0 m=1

XM2 D2 G GND GND nmos_3p3 L=1u W=1u nf=2 ad='int((nf+1)/2) W/nf 0.18u' as='int((nf+2)/2) W/nf 0.18u' pd='2int((nf+1)/2) (W/nf + 0.18u)' ps='2int((nf+2)/2) (W/nf + 0.18u)' nrd='0.18u / W' nrs='0.18u / W' sa=0 sb=0 sd=0 m=2

V1 G GND 2 .save i(v1) VD1 D GND 3.3 .save i(vd1) VD2 D2 GND 3.3 .save i(vd2) **** begin user architecture code

.include /home/nataraj/projects/designmyic/cad/pdk/share/pdk/gf180mcuC/libs.tech/ngspice/design.spice .lib /home/nataraj/projects/designmyic/cad/pdk/share/pdk/gf180mcuC/libs.tech/ngspice/sm141064.spice typical

.control save all op print i(vd1) print i(vd2) .endc

** end user architecture code .ends .GLOBAL GND .end

Specifications

nataraj-pinakapani commented 1 year ago

1

msaligane commented 1 year ago

Any updates on this issue?

@proppy @mithro @bmurmann

d-m-bailey commented 1 year ago

@nataraj-pinakapani My understanding is that XM1 has L=1u W=1u nf=1 m=1 which corresponds to one physical device with L=1u W=1u XM2 has L=1u W=1u nf=2 m=2 which corresponds to 4 physical devices each with L=1u W=0.5u

Do you get the same results with L=1u W=1u nf=1 m=2 which corresponds to 2 physical devices each with L=1u W=1u

nataraj-pinakapani commented 1 year ago

Hi, Sorry. I didn't work in the GF PDK for sometime now. I will check it again in the first week of August. Thanks for checking.

Regards, Nataraj

On Wed, 19 Jul 2023 at 16:51, Mehdi Saligane @.***> wrote:

Any updates on this issue?

@proppy https://github.com/proppy @mithro https://github.com/mithro

— Reply to this email directly, view it on GitHub https://github.com/google/gf180mcu-pdk/issues/88#issuecomment-1642344941, or unsubscribe https://github.com/notifications/unsubscribe-auth/AW3FYOGYNXFOCEY4PIASHATXQ77ARANCNFSM6AAAAAARMOKNYA . You are receiving this because you authored the thread.Message ID: @.***>

-- Cheers Natu

ChrisZonghaoLi commented 1 year ago

FYI this problem is now solved.

d-m-bailey commented 1 year ago

@ChrisZonghaoLi Great!

What was the resolution?

ChrisZonghaoLi commented 1 year ago

@ChrisZonghaoLi Great!

What was the resolution?

  • a fix to ngspice?
  • a change to netlist parameters?
  • simulation parameters?
  • fix to the mos models?

Hi Mitch, I think the original issue might be the parameter m was not declared in the spice model somehow. According to @atorkmabrains the new repo (https://github.com/mabrains/globalfoundries-pdk-libs-gf180mcu_fd_pr/tree/main/models) has the issue addressed (both ngspice and xyce models). We had this issue also discussed in Slack (https://open-source-silicon.slack.com/archives/C03R1GRP9LG/p1689280547619049?thread_ts=1689217859.856629&cid=C03R1GRP9LG).

d-m-bailey commented 1 year ago

Thanks @ChrisZonghaoLi. @proppy @mithro Do you want to close this since it appears to be resolved?

atorkmabrains commented 1 year ago

@FaragElsayed2 Is that done?

FaragElsayed2 commented 1 year ago

@atorkmabrains Yes

atorkmabrains commented 1 year ago

@FaragElsayed2 Link to PR?

FaragElsayed2 commented 1 year ago

@atorkmabrains https://github.com/mabrains/globalfoundries-pdk-libs-gf180mcu_fd_pr/pull/152

atorkmabrains commented 1 year ago

@d-m-bailey @ChrisZonghaoLi Closing this ticket as it’s already addressed.