Motor Driver problem when uploading new sketch

Status
Not open for further replies.

jacko91

Active member
Hey,
I have a T3.5 with an motor driver (MC33926). The interface is with two pwms. The problem: when uploading a new sketch while driving the motor, the motor spins full speed for couple of ms.
After looking at the pwm pins with the Oszi I found the following:
DS1Z_QuickPrint9.png

blue: the line with is driven with pwm.
yellow: other pwm line which is held low.
The moment the pwm stops is when I upload the new sketch. Depending of the last pwm state, the pin is held low or high. If high the motor will spin full speed for a couple of ms, which is not really something practical.
Any explanaitions why the teensy stops pwm, holds the last pwm state for a couple ms and then pulls both high?

Thanks
 
Try adding a pull down resistor, say 4k7 to the pin. During the upload the Teensy pin will float which might generate the observed effect.
 
Hey,
thanks, I tried that. But same issue. In the Oszi image above, when the pwm stops and before the yellow line gets pulled up, in this intersection a pullup wont change the states of the pins. So I guess the teensy actively keeps the yellow line low and the pwm line to the last pwm state.
 
Status
Not open for further replies.
Back
Top