program for final combination of working pieces
Dependencies: SDFileSystem TMP102 mbed ISL29125
Fork of TEMP_Test by
Diff: RGBSensor.cpp
- Revision:
- 9:9690da23e8d7
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/RGBSensor.cpp Sun Apr 03 21:51:02 2016 +0000 @@ -0,0 +1,15 @@ +#include "RGBSensor.h" +#include "ISL29125.h" + +// The location of the sensor on the FRDM-K64F// + +ISL29125 RGB_sensor(I2C_SDA,I2C_SCL); + +void RGB_init() { + RGB_sensor.RGBmode(ISL29125_RGB); + RGB_sensor.Range(ISL29125_10KLX); + RGB_sensor.Resolution(ISL29125_16BIT); +} +void get_rgb(uint16_t rgb[]){ + RGB_sensor.Read(ISL29125_RGB, rgb); +}