Anyone have a barebones example of generating PWM using PropBASIC?
Mickster
Posts: 2,694
I need to drive a motor and I have it somewhat working but not perfectly. Using "Countera Mode 32"
Regards,
Mickster
Regards,
Mickster
Comments
You probably want to use mode 48 (DUTY) instead of 32 (PWM).
The PWM mode creates pulses that are very narrow and will not drive a motor very well.
This code will use a speed from 0 to 255
P.S. I haven't tried the code above, but it should be close.
Bean
[/code]
Regards,
Mickster
I realize that this is low frequency stuff but, in this application I need to LPF it and generate a +/- 10v motor command.
Regards,
Mickster
-Mike