cancel
Showing results for 
Search instead for 
Did you mean: 

pwm signal for stepper motor

feres
Associate II
Posted on April 26, 2013 at 12:53

hi,

I found a problem to generate a PWM signal like this one: 

0690X00000602xzQAA.jpg

i thought that we can do this with TIM1 by insertion of a DEAD TIME but when i inserted a dead time i obtained a signal lîke this one: 0690X00000602y0QAA.jpg

can someone help me plz ?

3 REPLIES 3
Posted on April 26, 2013 at 13:31

Homework? [DEAD LINK /public/STe2ecommunities/mcu/Lists/STM32Discovery/Flat.aspx?RootFolder=/public/STe2ecommunities/mcu/Lists/STM32Discovery/PWM%20for%20stepper%20motor%208337&FolderCTID=0x01200200770978C69A1141439FE559EB459D75800084C20D8867EAD444A5987D47BE638E0F&TopicsView=https://my.st.com/public/STe2ecommunities/mcu/Lists/STM32Discovery/AllItems.aspx&currentviews=29]https://my.st.com/public/STe2ecommunities/mcu/Lists/STM32Discovery/Flat.aspx?RootFolder=%2fpublic%2fSTe2ecommunities%2fmcu%2fLists%2fSTM32Discovery%2fPWM%20for%20stepper%20motor%208337&FolderCTID=0x01200200770978C69A1141439FE559EB459D75800084C20D8867EAD444A5987D47BE638E0F&TopicsView=https%3A%2F%2Fmy%2Est%2Ecom%2Fpublic%2FSTe2ecommunities%2Fmcu%2FLists%2FSTM32Discovery%2FAllItems%2Easpx¤tviews=29

Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..
feres
Associate II
Posted on April 26, 2013 at 14:00

Haha no Clive it's not a homework 🙂 a project. we have to control a stepper motor. i need these signals :\

Posted on April 26, 2013 at 20:17

No mention of frequency, or period/duty

At 1 KHz, use two channels in PWM and alternate 0 and 80% ON time between channels at the update interrupt. Would give you a 500 Hz, 2 phases, 800 us ON1, 200 us OFF, 800 us ON2, 200 us OFF, with a 2000 us CYCLE
Tips, buy me a coffee, or three.. PayPal Venmo Up vote any posts that you find helpful, it shows what's working..