RC Receiver Servo out Signal to Servo


hey folks,
i new arduino, programmes c# , vba before never in connection hardware.

i far let leds blinks, move servo , show stuff on display

how can connect rc-receiver arduino uno , read servosignal send servo ?
the servo gets angle should move
to controll servo use following code:
code: [select]

// sweep
// barragan <http://barraganstudio.com>
// example code in public domain.


#include <servo.h>
servo myservo;  // create servo object control servo
                // maximum of 8 servo objects can created
int pos = 0;    // variable store servo position

void setup()
{
  myservo.attach(9);  // attaches servo on pin 9 servo object
}
void loop()
{
    myservo.write(pos);              // tell servo go position in variable 'pos'
    delay(15);                       // waits 15ms servo reach position
}


"pos" angle of servo in degrees

greets phil

what servo library sends servo pulse of (roughly) 1000 2000 microseconds (1 2 milliseconds).

strangely enough, that's same kind of signal rc receiver sends servo.

you can use "pulsein()" function (http://arduino.cc/en/reference/pulsein) measure pulse in microseconds.

you can use 'servo.writemicroseconds()' function (http://arduino.cc/en/reference/servowritemicroseconds) tell servo library how long outgoing pulses should be.


Arduino Forum > Topics > Robotics (Moderator: fabioc84) > RC Receiver Servo out Signal to Servo


arduino

Comments

Popular posts from this blog

Convierte tu Raspberry en un NAS. Firmware fvdw-sl 15.3 - Raspberry Pi Forums

How to format a Get Request

avrdude: verification error, first mismatch at byte 0x0000 0x0c != 0x62