Arduino Forum

Topics => Robotics => Topic started by: stark_xavier21 on Jun 27, 2020, 04:20 pm

Title: Position Feedback Servo?
Post by: stark_xavier21 on Jun 27, 2020, 04:20 pm
Is there a code to record the steps of a servo if i rotate it  manually?

if so, could anyone help me with this please?

Title: Re: Position Feedback Servo?
Post by: slipstick on Jun 27, 2020, 04:46 pm
No, not with a normal hobby servo. You'd need a special servo that provides feedback and then you'd need some special code to record what was happening and you'd have to hope that manually turning the servo didn't damage it.

Feedback servos do exist but there are not many few of them about e.g. https://www.pololu.com/product/3436

Steve

Title: Re: Position Feedback Servo?
Post by: Coding Badly on Jun 27, 2020, 09:22 pm

Thread split as requested.

Title: Re: Position Feedback Servo?
Post by: Johan_Ha on Jun 29, 2020, 08:19 pm
A simple hobby servo usually has a potentiometer measuring the position of the servo horn for its own controlling circuit. You can hack into such a servo and locate the internal pin going to the sweeper of the potentiometer. Attach it to an analog input on your Arduino. Now you have a feedback from your servo. But don't just do it following this simple advice. Google for projects how people have done it. There might be things to consider, something I haven't mentioned.