Issue with HS-785HB servo

This is my code.

#include <Servo.h>
Servo llr;
int pos = 0;
void setup()
{
llr.attach(10);
}

void loop()
{
llr.write(180);
delay(6000);
llr.write(0);
delay(6000);
}

The issue is when I turn it counter clockwise, it will automatically stop at a certain point and do nothing.

Anyone know that issue?

Hi,
Give us a clue or more info!! How is it wired, how is it powered?? How do you know where left and centre are?

Issue a command to set the servo at centre(90) like this; IIr.write(90); if it's not pointing where you think it should be, remove the arm and re-postion it to where it should be for centre. And try again.

Give that servo a name that means something IIr!!

Hope it helps, Regards.

Mel.

It just connects to arduino.
I set it to center already, how do you remove the arm?

Hi,
Nothing just connects to the Arduino!! How do you know you set it to centre? You may have set it to centre in your code, but have you actually done it, the arm is held on by the screw in the centre, try removing it.

If you're powering it also from the arduino that can be a problem, servos like motors generate a lot of electronic noise, this can interfer with the arduino and cause many problems. It can also damage the arduino by the reverse EMF they generate.

The best advice on the forum is NEVER power motors or servos from the Arduino, it can't supply the current needed, the arduino power drops and the arduino resets itself at the very least.

Regards

Mel.

It just connects to arduino.
I set it to center already, how do you remove the arm?

That servo is a multi turn sail winch servo. It requires an external power supply, powering from the arduino probably won;t work. To remove the servo horn, usually there is a screw attaching the horn to the output shaft. Below is a link with info on the servo.

http://www.robotshop.com/ca/en/hitec-hs785hb-servo-motor.html

Hi,
The OP could have told us it not a conventional servo and does not have an Arm/horn, But also does 3.5 turns. So remove the winch pulley? use some code to set it half way, and with a servo that has 3.5 turns not sure how you do that, what do the instructions say! Do you have any instructions, perhaps if you did you wouldn't be asking us..

Do the usual servo parameters apply. 0=far left(ccw) and 180=far right (cw) if so then 90 will still be the mid-point... Make a mark on the rim with a felt tip pen and see how it moves according to your code, do you get 3.5 turns or 1.75 turns left and right?

Regards

Mel.

Hi,

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

Tom.... :slight_smile:

Do the usual servo parameters apply. 0=far left(ccw) and 180=far right (cw) if so then 90 will still be the mid-point... Make a mark on the rim with a felt tip pen and see how it moves according to your code, do you get 3.5 turns or 1.75 turns left and right?

Well, there are some hobby servo misconceptions that may come into play. I think the pulse duration of typical hobby RC equipment that is sent to a servo is ~1000-2000ms, not 500-2500ms. This may be important knowledge point with sail winch servos and ESCs. The below pix is for the servo under discussion. Other sail winch servos may get double the listed rotations when using the full 500-2500ms control range.