colorpal library
v0.5
Simplifies monitoring ColorPAL sensor with the Propeller.
|
Simplifies reading Parallax ColorPAL sensor. More...
Go to the source code of this file.
Data Structures | |
struct | colorpal_serinfo |
Typedefs | |
typedef struct colorpal_serinfo | colorPal_t |
typedef text_t | colorPal |
Functions | |
colorPal * | colorPal_open (int sioPin) |
Open a connection to a Parallax ColorPAL sensor. | |
void | colorPal_close (colorPal *device) |
Close a connection and recover all memory set aside for the ColorPal sensor instance. | |
void | colorPal_getRGB (colorPal *device, int *r, int *g, int *b) |
Get RGB (red green blue) values from the ColorPAL sensor. |
Simplifies reading Parallax ColorPAL sensor.
typedef text_t colorPal |
Defines instance of colorpal for use with simpletext functions that accept text_t parameters.
typedef struct colorpal_serinfo colorPal_t |
Defines instance of colorpal_t settings for serial communication.
void colorPal_close | ( | colorPal * | device | ) |
Close a connection and recover all memory set aside for the ColorPal sensor instance.
*device | device identifier returned by colorPal_open function. |
void colorPal_getRGB | ( | colorPal * | device, |
int * | r, | ||
int * | g, | ||
int * | b | ||
) |
Get RGB (red green blue) values from the ColorPAL sensor.
*device | device identifier returned by colorPal_open function. |
r | Red value. |
g | Green value. |
b | Blue value. |
colorPal* colorPal_open | ( | int | sioPin | ) |
Open a connection to a Parallax ColorPAL sensor.
sioPin | Propeller I/O pin connected to ColorPAL sensor's SIO pin. |