Quantcast
Channel: Raspberry Pi Forums
Viewing all articles
Browse latest Browse all 8015

General discussion • MG995 servo with raspberry pi 4

$
0
0
Hi,

I have been struggling to get my servo to move at all.
The MG995 servo is continuous, runs on 5-6V.

I have tried using an N-MOSFET, an optocoupler, a PCA9685, and an op amp. I am connecting the power via 5V regulator of my battery.
For the mosfet and the optocoupler, the multimeter reads 5V at the output signal pin, and the op amp output reads 3.8V.

I connected the op amp circuit to a waveform generator (square wave, 3.3Vpp, 50Hz, and 10% duty cycle) and power supply of 5V, and it worked.

Perhaps it is coding issues? I have been trying C (with wiringpi) and python, but nothing is working at all. Please help and suggest anything on the programming.

Statistics: Posted by Quynhpham — Thu Jul 10, 2025 4:22 am



Viewing all articles
Browse latest Browse all 8015

Trending Articles