Had this many
there is a allen key socket in the drive motor you can wind shut.
You need to pop the sunroof control cover iirc.
My car didn't come with a winder so I always kept a t-bar socket
drive and the right sized key in the boot.
Before manually winding it and after you checked the fuse:
Try turning the knob to the extreme left and right positions
and then pushing it/keeping it pressed it each position.
Generally jiggling it around like that got it working sometimes.
The problem is a design fault in the control unit means
that it sometimes "forgets" which position it's in and
the system fails safe.
The safest thing to do is never change position
without the ignition on and always leave it full open,
fully closed or fully tilted when switching off.
Try not to use the keyfob open/close unless you really have to.