add ofsset in sine calculation
Allow PWMControl to be initialized with an init() function instead
of using the constructor.