lights.h File Reference

Contains declarations for managing the orbs. More...

Go to the source code of this file.

Defines

#define RED   0xE0
 Red.
#define ORANGE   0xE4
 Orange.
#define YELLOW   0xE8
 Yellow.
#define LIME   0x68
 Lime.
#define GREEN   0x1C
 Green.
#define CYAN   0x1F
 Cyan.
#define BLUE   0x03
 Blue.
#define PINK   0xA6
 Pink.
#define PURPLE   0x41
 Purple.
#define MAGENTA   0xE3
 Magenta.
#define WHITE   0xFE
 White.
#define ORB_OFF   0x00
 Turn the orb off.
#define orb_mode_pwm   0
 PWM mode.
#define orb_mode_binary   1
 Binary mode.

Typedefs

typedef unsigned char uint8_t
typedef uint8_t orb_mode_t

Functions

void orb_init (void)
 Enables the orbs in default mode.
void orb_init_binary (void)
 Enables the orbs in binary mode.
void orb_init_pwm (void)
 Enables the orbs in PWM mode.
void orb_set_mode (orb_mode_t mode)
 Switches the orbs to the specified mode.
void orb_disable_timer (void)
 Disables the orb timer, but does not change the mode.
void orb_enable_timer (void)
 Enables the orb timer, but does not change the mode.
void orb_n_set (uint8_t num, uint8_t red, uint8_t green, uint8_t blue)
 set the specified orb to a specified color
void orb_set (uint8_t red, uint8_t green, uint8_t blue)
 Set both orbs to a specified color.
void orb1_set (uint8_t red_led, uint8_t green_led, uint8_t blue_led)
 Set orb1 to a specified color.
void orb2_set (uint8_t red_led, uint8_t green_led, uint8_t blue_led)
 Set orb2 to a specified color.
void orbs_set (uint8_t red1, uint8_t green1, uint8_t blue1, uint8_t red2, uint8_t green2, uint8_t blue2)
void orb_n_set_color (uint8_t num, uint8_t col)
 set the specified orb to the specified color
void orb1_set_color (uint8_t col)
 Set orb1 to a specified color.
void orb2_set_color (uint8_t col)
 Set orb2 to a specified color.
void orbs_set_color (uint8_t col1, uint8_t col2)
 set the orbs to specified colors
void orb_set_color (uint8_t col)
 Set both orbs to a specified color.


Detailed Description

Contains declarations for managing the orbs.

Copyright (c) 2007 Colony Project

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Contains declarations for using the orbs and PWM.

Author:
Colony Project, CMU Robotics Club Based on Firefly Library, by Tom Lauwers and Steven Shamlian

Generated on Mon Sep 7 19:07:28 2009 for libdragonfly by  doxygen 1.5.9