Hi,friends
Now I am researching servo motor with PIC BASC Pro. My problem is how to change servo motor PWM. I try to design programming. But it is not successful.Please give me some ideal. Thank you.
Hi,friends
Now I am researching servo motor with PIC BASC Pro. My problem is how to change servo motor PWM. I try to design programming. But it is not successful.Please give me some ideal. Thank you.
Alter the values in the variables to change the values of the Duty time and Cycle time.Code:pin var yourport.x ' for instance PortB.7 Duty var byte cycle var byte PWM pin,duty,cycle ' right out of the book . . . . . . Or, PWM PORTB.7,127,100 ' RIGHT FROM THE BOOK 50% duty cycle @ 100 cycles
you can change them using digital methods or analog a/d converters and a potentiometer.
to alter numbers just . . . duty = 130
.................................. cycle = 150
Last edited by Archangel; - 20th September 2008 at 09:29.
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
Hi, Joe
I think the question was " how to move the servo's arm" ...
Alain
DBoy,
As you have to learn everything about servos management ... I'd recommend you to make a Web search on R/C and Robotics sites about How a servo works.
Once that, with once more the SEARCH tool ,of this forum, now, you'll find how to do that with PicBasicPro...
Alain
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
.
Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
.
There simply is no "Happy Spam" If you do it you will disappear from this forum.
************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
Thank you for your ideal. Actually servo motor pulse width variance from 1ms to 2 ms. I want servo motor shaft slowly turning. So I want to change PWM.
Bookmarks