Society of Robots - Robot Forum
Software => Software => Topic started by: Hasan999 on March 05, 2010, 03:11:58 PM
-
Axon Microcontroller - using Webbot Library...
When I include an 8 bit Timer for any "bank", it compiles successfully, but the programming doesn't do anything (none of the servos get pulses)
Example:
servosInit(&bank1, TIMER1_COMPAREA);
servosInit(&bank4, TIMER1_COMPAREC);
servosInit(&bank5, TIMER5_COMPAREB);
servosInit(&bank2, TIMER3_COMPAREB);
servosInit(&bank3, TIMER1_COMPAREB);
servosInit(&bank6, TIMER3_COMPAREC);
servosInit(&bank7, TIMER5_COMPAREA);
servosInit(&bank8, TIMER3_COMPAREA);
servosInit(&bank9, TIMER4_COMPAREA);
servosInit(&bank10, TIMER4_COMPAREB);
servosInit(&bank11, TIMER4_COMPAREC);
servosInit(&bank12, TIMER5_COMPAREC);
servosInit(&bank13, TIMER2_COMPAREA); // <-- 8 bit Timer
When I searched for related questions, I got to know that 8 bit Timers have lesser "Steps", please correct me if I'm wrong: the servos can attain 13 specific positions? ..is it like that?
Even if so, I need to use 8 bit Timers (along with all other 16 bit Timers), since I have to have minimum number of servos in each bank* (hence I need more banks, with more Timers).
*otherwise, the servos do not hold tight ! (1 servo per bank = perfect)
Need help to get the 8-bit Timers work..
Thanks a lot..
-
I remember the discussion. I know the current version that I have does not allow servos to use an 8 bit timer (I verified that by looking at servopwm.c).
I think in the end he said he might consider it.
Kurt
-
Here's the thread -
webbotlib and 8 bit timers (http://www.societyofrobots.com/robotforum/index.php?topic=10310.msg78889#msg78889)
-
@Hasan999
I won't be doing anything in WebbotLib until there are answers to the outstanding questions on your original post @ http://www.societyofrobots.com/robotforum/index.php?topic=10113.msg79612#msg79612 (http://www.societyofrobots.com/robotforum/index.php?topic=10113.msg79612#msg79612)
Notably:-
As Admin has said:- "you're supply will need to be capable of providing 22+ Amps".
Your earlier posts suggest you are using a 6v 3300maH battery and that it causes the processor to reset as soon as there is any load on the servos.
Others have said why this would be the case. ie a fully charged battery showing 7.2v with no load will NOT be 7.2v under a load - and that's your problem.
Things still point to your power supply being THE major problem. If I allow 8 bit timers to be used then this will NOT go away.
Equally you haven't answered Dunks very relevant question on that thread - which is a re-wording of an earlier question from me that you also never answered.
Look forward to your responses on that thread; since this is a kinda duplicate. :)