Functions
servo.h File Reference

Servo outputs. More...

Functions

void servo_init (void)
void servo_set_pos (uint8_t servo, uint16_t pos)
void servo_disable (uint8_t servo)

Detailed Description

The happyboard as 6 servo outputs.

Each servo has a 9bit register used to set it's position. Setting the servo to 0 will cause it to move to its counter-clockwise limit, while setting it to 511, will cause it to move to its clockwise limit.


Function Documentation

void servo_disable ( uint8_t  servo)

Disable servo - stops sending servo commands until the next servo_set_pos();

Parameters:
servoServo to disable
void servo_init ( void  )

Initialize servos. Should not be called by user.

void servo_set_pos ( uint8_t  servo,
uint16_t  pos 
)

Set a servo's position.

Parameters:
servoServo to set.
posNew servo value (0..511)