This is probably a silly question, but if you are attempting to drive two pins with the same signal, at the same time and the same phase, why do you need TWO pins?
This is probably a silly question, but if you are attempting to drive two pins with the same signal, at the same time and the same phase, why do you need TWO pins?
Charles Linquist
As I stated, I am driving 2 seperate h-bridges...each bridge has 2 inputs. I have a total of 4 inputs to both h-bridges and want to always drive 2 pins at any one time.
if I want my robot to turn right I need to drive
'ex: not actual code...
rightwheelfw var portb.0
rightwheelrs var portb.1
leftwheelfw var portb.2
leftwheelrs var portb.3
turnright:
high rightwheelrs
high leftwheelfw
pause 50
goto commands
turnleft:
high rightwheelfw
high leftwheelrs
pause 50
goto commands
In my case though I want to have variable speed control not just HIGH.
This is why I want PWM on 2 pins at the same time.
Padawan-78
there's some PIC which give you 2 different CCP module and allow that.
There's also some PIC with ECCP (even a 12F615), which can be used to drive in half bridge/Full bridge mode + few feature such as dead band time. 18F2431/4431 are some good example.
http://ww1.microchip.com/downloads/e...Doc/39616C.pdf
depending your expected PWM frequency, Darrel's Muti_SPWM could be used
http://www.pbpgroup.com/modules/wfse...p?articleid=12
Timer interrupt is another way to go.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Bookmarks