View previous topic :: View next topic |
Author |
Message |
Salenko
Joined: 08 Sep 2008 Posts: 84
|
why PWM signal for the stepper driver (L297) ? |
Posted: Mon Oct 13, 2008 1:55 pm |
|
|
Hi,
this may be a silly question, in the datasheet of the L297, the Clock signal (generated by the microcontroller) has a duty near the 100%, is this the PWM signal ? ,cause I read that the PWM is generated by the L297 >>> L298>>> Stepper motor.
I wrote a C code to generate this clock signal with a duty of 50% using the CCP (compare mode) associated with timer, will this run correctly in reality?
thanks in advance |
|
|
Ttelmah Guest
|
|
Posted: Mon Oct 13, 2008 2:40 pm |
|
|
This is the steper clock. Has nothing to do with PWM. It is actually a -ve logic signal, with just a narrow active pulse. The system steps, on the rising edge of the pulse, and it's width is unimportant. You will want to change the frequency of this pulse, to change the speed of the motor.
Best Wishes |
|
|
Salenko
Joined: 08 Sep 2008 Posts: 84
|
|
Posted: Tue Oct 14, 2008 12:59 am |
|
|
Ttelmah wrote: | This is the stepper clock. Has nothing to do with PWM. It is actually a -ve logic signal, with just a narrow active pulse. The system steps, on the rising edge of the pulse, and it's width is unimportant. You will want to change the frequency of this pulse, to change the speed of the motor.
Best Wishes |
hi Ttelmah ,
thank you for your answer, so the duty of the clock signal do not affect the speed of the stepper , I´m using a clock with a 50% duty cycle , would this change anything in the stepper motor behaviour (apart from its frequency as you said which do not change with the width of high level pulse) compared to a stepper with a clock with almost 100% duty cycle ? |
|
|
FvM
Joined: 27 Aug 2008 Posts: 2337 Location: Germany
|
|
Posted: Tue Oct 14, 2008 1:17 am |
|
|
With almost 100% duty cycle, you are referring to the sketched waveform in the datasheet? If you read the datasheet thoroughly, you'll find no specification regarding the clock waveform, expect a minimum low time. Thus the curious look of the waveform actually means nothing. It's also clear from the functional description of the chip. Strictly speaking, a minimum high time of the clock signal is missing from the specification.
Regards,
Frank |
|
|
Salenko
Joined: 08 Sep 2008 Posts: 84
|
|
Posted: Fri Oct 17, 2008 12:01 am |
|
|
FvM wrote: | With almost 100% duty cycle, you are referring to the sketched waveform in the datasheet? If you read the datasheet thoroughly, you'll find no specification regarding the clock waveform, expect a minimum low time. Thus the curious look of the waveform actually means nothing. It's also clear from the functional description of the chip. Strictly speaking, a minimum high time of the clock signal is missing from the specification.
Regards,
Frank |
thank you Frank for your remarks ! |
|
|
|