Simple model of a hall sensor, i.e. measuring the angle of the flange (w.r.t. the optional support), multiplying by the number of pole pairs p to obtain the electrical angle, and adding a correction term i.e. the initial angle of the flange phi0.
Additionally, the Boolean commutation signals for m
phases are generated,
i.e. an ouput yC[k] = true
when the angle is within [-pi/2, +pi/2] of the orientation of phase k.