The MG996R servo is a popular choice for robotics projects due to its affordability and decent performance.
However, it lacks built-in position feedback, which can be a limitation for applications that require precise control.
To address this, we implemented a custom position feedback mod for the MG996R servo. Here's how we did it.
Before diving into the mod, let's briefly review how a standard servomotor works.
A servomotor is a device that can rotate to a specific angle based on a control signal. This is typically achieved using 3 components :
A servomotor has three wires :
The control circuit compares this signal to the feedback from the position sensor and adjusts the motor's rotation until the feedback matches the desired position.
In most robotics projects using MG996R servos, adding position feedback is done by attaching an external sensor, such as a rotary encoder, the the joint.
However, since a potentiometer is already present inside the MG996R for internal control, we could tap into this existing sensor to extract position feedback without needing additional hardware.
Sadly, reading the potentiometer's output directly isn't as easy as it sounds. The MG996R's control circuit is really sensitive to any external interference, and to read the potentiometer's voltage with a microcontroller generates a little voltage drop1 that causes the servo to jitter as it tries to compensate for the perceived change in position.
To solve this, we used an operational amplifier (op-amp) acting as a buffer to isolate the potentiometer from the microcontroller's input. This way, we can read the voltage without affecting the servo's performance.
schema
A complete guide on how to modify the MG996R motors of the TNY-360 is available in the Practical Guide section of the documentation !