User Manual
Reference
C++ and Arduino methods are shown in red.
C functions are shown in green.
static void OrangutanLEDs::red(unsigned char state)
void red_led(unsigned char state)
This method will turn the red user LED off if state is zero, it will toggle the LED state if state is 255, else it
will turn the red user LED on. You can use the keyword HIGH as an argument to turn the LED on, and you
can use the keyword LOW as an argument to turn the LED off. You can use the keyword TOGGLE to toggle
the LED state.
Example:
red_led(HIGH);
// in C++: OrangutanLEDs::red(HIGH); // turn the red LED on
static void OrangutanLEDs::green(unsigned char state)
void green_led(unsigned char state)
This method will turn the green user LED off if state is zero, it will toggle the LED state if state is 255, else
it will turn the green user LED on. You can use the keyword HIGH as an argument to turn the LED on, and
you can use the keyword LOW as an argument to turn the LED off. You can use the keyword TOGGLE to
toggle the LED state. The Baby Orangutan does not have a green user LED, so this function will just affect
the output state of user I/O pin PD7.
Example:
green_led(LOW);
// in C++: OrangutanLEDs::green(LOW); // turn the green LED off
static void OrangutanLEDs::left(unsigned char state)
void left_led(unsigned char state)
For the Orangutan LV, SV, X2, Baby Orangutan, and the 3pi, this method is an alternate version of red(). The
red LED is on the left side of most of these boards. For the Orangutan SVP, this method is an alternate version
of green().
static void OrangutanLEDs::right(unsigned char state)
void right_led(unsigned char state)
For the Orangutan LV, SV, X2, Baby Orangutan, and the 3pi, this method is an alternate version of green().
The green LED is on the right side of most of these boards. For the Orangutan SVP, this method is an alternate
version of red().
static void OrangutanLEDs::red2(unsigned char state)
void red_led2(unsigned char state)
This method controls the Orangutan X2’s second red user LED and is only defined for the Orangutan X2
version of the library. You can use the keyword HIGH as an argument to turn the LED on, and you can use
the keyword LOW as an argument to turn the LED off. You can use the keyword TOGGLE to toggle the LED
state.
static void OrangutanLEDs::green2(unsigned char state)
void green_led2(unsigned char state)
This method controls the Orangutan X2’s second green user LED and is only defined for the Orangutan X2
version of the library. You can use the keyword HIGH as an argument to turn the LED on, and you can use
Pololu AVR Library Command Reference © 2001–2015 Pololu Corporation
6. Orangutan LEDs Page 26 of 65