Hello,
(no load and no demagnetization winding)
for magnetizing the primary winding, the single MOSFET pulls the terminal to ground. Current starts to increase linearly together with magnetic flux inside the ferrite. Next the MOSFET is switched off and the gate is discharged, and the drain source voltage starts to rise. Once the body diode is in reverse bias the drain-source voltage drops back to ~0 V and a reverse current goes through the primary which discharges to 0 A right until the MOSFET is switched back on again.
So at the transition from on to off of the MOSFET the current completly reverses, but the primary voltage stays mostly the same, since the current change is positive except at the transition.
Now, to my understanding this is not right behaviour. The change of polarity after switching the MOSFET off should mean that the primary inductance has a reverse voltage but the current should still be positive and start discharging towards 0 A.
How could there possibly be negative current?
Since there is no demagnetization winding the core should saturate, could that explain the negative current? Could there be a problem with the measurement at the 3 Ohm shunt resistor at the source pin?