Hi all,
I purchased a servo link wanting to build a contraption that would basically work reading input from LDRs and moving the servo accordingly.
I'm no expert with servos so I'm trying to see if this thing is broken or if its working as it is supposed to.
Very first thing I did was to connect it to my lab bench power supply (7.2v 3 A limit - Made sure to share ground with Arduino-) loaded up the sweep example sketch from the IDE on my arduino UNO and I noticed the servo moving back and forth as it was supposed to, after that and since it was apparently working fine, I breadboarded it along with a pot (10k) and loaded up the knob sketch which worked perfectly as well.
After flawlessly passing both previous tests, I was ready to test and write down the actual "comfortable limits" -upper and lower- , so I coded a quick sketch (basic sketch, asking for input on serial and after entering the number the servo would move) and I quickly discovered that for some strange reason, my servo works fine when I ask it to move in 10 degree increments, but goes bananas when I want it to move in bigger increments (say 30 to 160, 20 to 160, etc etc etc) even if it is at 90 and I ask it to go to 110 the damned thing starts vibrating like crazy and does nothing, but if instead of 110 I modify the code and I input 100 (10 degree movement) the servo moves fine to where it should move.
I've spent several hours troubleshooting this thing, reading up online and trying to come up with a solution and I honestly couldn't find any. Tried 3 different Arduino Uno's including 2 original Arduinos and 1 clone, tried with an Original Arduino nano, and also tried with my esp8266, and same thing.
Issue is that I have no idea what the actual issue is, I don't know if the actual servo is busted, or if it is damaged or if it is power/software related issue.
On my side I basically tried every possible thing I could think of:
Tried 2 different lab bench power supplies, tried SLA battery with a Buck/Boost tried liPO, li-ion etc, I even tried different supply voltages from 6v all the way to 8v and same thing.
I also tried several different sketches inputting microseconds or direct pwm, heck even browsed and copy pasted as many sketches I could possibly find, I also modified the original sketches with different values, and nothing.
The actual circuitry/cabling was checked and checked again and I went as far as soldering everything into perfboard after trying 4 different breadboards (thinking it was a bad contact or connection)
But no, nothing... I honestly have no clue how come this thing works perfectly fine with the Knob example and follows the actual analog reading to the teeth and then it just goes bananas when asked to move in more than 20 degree increments. (modified the knob sketch too, turned the serial on and printed the actual reading and the servo movement and everything worked fine)
I'm trying to describe the situation to the best of my knowledge, there is no sketch to upload since I am basically using the default knob and sweep from the Arduino IDE and for the actual sketch that would fail is basically writing anything that would require the servo to move into a position 20 degrees over.
For the actual circuitry/cabling is simple, 3 wires from servo * signal, vcc and ground * signal to pin9, ground to arduino and pwr source and vcc to power source, on the arduino just 5v, vcc and ground + ground of the servo. (highly doubt is power or circuitry related since sweep and knob work fine)
All help, comments, questions appreciated in advance !