51 #include "LRFEvents.h"
52 #include "LRFInfrared.h"
54 #define LRF_FIRMWARE_MAJOR 1
55 #define LRF_FIRMWARE_MINOR 1
57 #define LRF_DEBUG_CONSOLE_ENABLED 0
58 #define LRF_FORCE_HARDWARE_TEST 0
59 #define LRF_ADVANCED_HARDWARE_TEST 0
201 void setBoredom(
unsigned int timeout,
unsigned char count);
269 void setLeftLED(
unsigned char red,
unsigned char green,
unsigned char blue,
bool update=
true);
270 void setRightLED(
unsigned char red,
unsigned char green,
unsigned char blue,
bool update=
true);
271 void setBothLEDs(
unsigned char red,
unsigned char green,
unsigned char blue,
bool update=
true);
280 void setSpeaker(
unsigned int frequency,
unsigned int duration);
unsigned char readLight(void)
Read the light sensor.
unsigned char readTouch(void)
Read the touch sensor.
void setBoredom(unsigned int timeout, unsigned char count)
Set how quickly and how often your robot gets bored.
void loop(void)
run the LRF library loop
Allows for access of sound data as a structure or raw integer.
void sleep(void)
Put the robot to sleep.
void setRightLED(unsigned char red, unsigned char green, unsigned char blue, bool update=true)
Set the RGB value of one or both LEDs.
The main class of the Little Robot Friends API.
LRFEvent
Constants for different interaction and system events.
void blink(LRFPattern pattern)
Blink a light pattern on the LED eyes.
void setBothLEDs(unsigned char red, unsigned char green, unsigned char blue, bool update=true)
Set the RGB value of one or both LEDs.
void setLeftLED(unsigned char red, unsigned char green, unsigned char blue, bool update=true)
Set the RGB value of one or both LEDs.
void sendIRMessage(LRFIRMessage message)
Send an IR message.
void say(LRFSound sound)
Speak a single sound.
LRFIRMessage readIRMessage(void)
Read the latest received IR message.
void(* LRFEventHandler)(void)
Function pointer with no parameters and no return value.
unsigned char readMicrophone(void)
Read the microphone.
void setup(void)
setup the LRF library
Collection of custom types and handy functions used throughout the LRF codebase.
void blinkAndSay(LRFPattern pattern, LRFSound sound)
Blink and speak at the same time.
Allows for access of pattern data as a structure or raw integer.
void setEventHandler(LRFEvent event, LRFEventHandler handler)
Customize how your robot responds to particular events.