added stepgen for pwm generation