i tried to design a diff amp using ngspice however im not able to get the simulation. I want to find the gain freq plot. can you please tell what's wrong with my method?
M2/M1 is not configured as current mirror, thus zero bias current.
Also Vin1 and Vin2 are in phase but should be out of phase. Still the same fault as three months before, unless you want to measure common mode rejection.
I have used SPICE netlist entry 35 years ago because we ran the tool on a DEC PDP11 text terminal without graphics capability. Pretty retro to use netlist entry these days...
M2/M1 is not configured as current mirror, thus zero bias current.
Also Vin1 and Vin2 are in phase but should be out of phase. Still the same fault as three months before, unless you want to measure common mode rejection.
I have used SPICE netlist entry 35 years ago because we ran the tool on a DEC PDP11 text terminal without graphics capability. Pretty retro to use netlist entry these days...
Microcap has recently been made public for everyone so it's free without any restriction.It's been used for serious circuit designs by professional engineers now it's free.. https://www.spectrum-soft.com/index.shtm
It's really professional grade SPICE based simulator.
AFAIK, a control section in NGSpice starts with a .control keyword and ends with .endc
Also, have you tried adding a .save all before the control section?
P.S. I have tried MicroCap and it is a great simulator... I was using NGSpice for doing work on the side, but I like the GUI of MicroCap. The only problem that I have with Microcap is I cannot plot things like gm, gds etc as a function of some sweep parameter which I can do with NGSpice.
Not too long ago, I designed the netlist of a chip using text based netlist and Eldo simulator, laid it out using Cadence layout tool suite and taped it out. It was in 350nm. Its good to use text based netlist once in your life. The chip worked albeit with some major tweaking. I could have definitely caught the issue if I had a GUI that could annotate the DC operating points.