| Author |
Message |
sharkfire
Joined: 19 Mar 2008 Posts: 2
|
19 Mar 2008 20:21 Controlling servo motor.. need help.. |
|
|
|
I have a servo motor, rotating 360 degrees. It's function is for turning the wheels left and right. Now, what I want, if the wheels turn extreme left ( the farthest that the wheel can reach) the motor should stop rotating. Same goes with the right direction. It's like, the motor should only rotate for 180 degres. That's -90 for left and +90 for right.
To rotate the motor, I have 3 receivers: L(left), C (Center) and R(RIght).
If the C receiver is detected, the system should check which receiver will go high next. Example, the L Receiver. The motor should rotate, at least 90 degrees to the left (the wheels will also turn left). After that, the motor should stop rotating, even the L Receiver is still high. Then If the C receiver becomes active, the will turn right, and will go back in place. Same goes with the right.
What should I do with the program? I'm using PIC16f84, and Assembly language programming. I have little idea with delays and timers. Hope you can help..
|
|
| Back to top |
|
 |
davidgrm
Joined: 08 Apr 2006 Posts: 155 Helped: 9
|
28 Mar 2008 22:24 Re: Controlling servo motor.. need help.. |
|
|
|
| Are you using some kind of servo motor controller or are you controlling it from the MCU?
|
|
| Back to top |
|
 |
pian
Joined: 17 Apr 2008 Posts: 10
|
28 Apr 2008 13:16 Re: Controlling servo motor.. need help.. |
|
|
|
Hi Sharkfire.
Are you using a hobby servo motor?
If so, please include the source file for the m/controller, so that we can start tracing where is the problem.
Do you mean you have three sensors? left sensor, center sensor and right sensor
Are going to build a line follower robot? If so, please list down all of the component you a using in the project and also the schematic, so that we can find where is the problem. If not, leave this question. Tq
'Learn till you die'
Pian.
|
|
| Back to top |
|
 |
shashankthebest
Joined: 12 Feb 2008 Posts: 25 Helped: 1
|
05 May 2008 10:56 Re: Controlling servo motor.. need help.. |
|
|
|
| If you are using PWM controlled RC servos then they should not turn 360 deg. Check if the motors are in good condition.
|
|
| Back to top |
|
 |