I’ve tried to import a Infineon nmos model to Qspice (.spi spice model - can be read with .txt extension)
Model work ok as long as it’s used as X type device. When used as MN or seleced as library for NMOS it no longer works correctly.
I wanted to use it a MN device because of Qspice power loss calculation feature.
Is it possible ?
No. The MN or MP type device is a MOSFET device, which is one of the SPICE standard devices, like a resistor (R), capacitor (C), etc. The X-device is a sub-circuit, which is used to read the .subckt model like the one provided on the Infineon website. Sub-circuit (.subckt) is just a circuit with many standard devices in a netlist format, which is basically a hierarchy.
What you did was to take advantage of the M-device symbol, forcing it to a X-device as its pin order generally matches the .subckt pin order for the manufacturer’s MOSFET sub-circuit model. This saves time by avoiding the need to recreate a symbol for the sub-circuit FET model.
Referring to Qspice HELP in .option, note 8 states: “.option savepowers computes the true power dissipation while ignoring displacement currents.” For a MOSFET, it computes not only drain dissipation but also includes gate dissipation.
For sub-circuits, you have to use the traditional method (measure I and V) to calculate their power.