Software motor control implementation

Notes on PWM

Pins with Timer function starting with PM_TAx.x support PWM.

From forum comments, it seems best to select around 10kHz as PWM frequency. “If you go too high then the inductance of the motor starts to have an effect, losing power and making the motor dissipate more heat - this isn't a good idea!. Going too low may make it jerky, so too low isn't good either.”