![]() |
Re: Motors and the High Port Numbers
The servo power on the pwm output pins comes from the backup battery.
|
Re: Motors and the High Port Numbers
If you run those pwms on interrupts, does anything go wrong?
How about high priority interrupts? Can the function run fast enough? |
Re: Motors and the High Port Numbers
Quote:
I think the Pwm's 13-16 are hardware generated from pins called CCP1, CCP2,... I don't understand how these can be affected by the software? The values are in software but if the software is slow to execute then the value just won't change really fast. |
Re: Motors and the High Port Numbers
Quote:
Any interrupts, interrupt the software timing these pulse widths, but the software doing the timing doesn't know this. Just like none of your other regular code is ever aware an interrupt has occurred. So the software happily generates what it thinks is a neutral pulse of 1.5ms, but any interrupt handler that pops in, suspends the execution of your code, does it's thing, and returns control will extend or stretch the time of your pwm pulse by the amount of time it took to service that interrupt. So instead of a 1.5ms pulse, for example, you'll end up with a 1.8ms pulse. And your robot drives away. |
| All times are GMT -5. The time now is 21:00. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi