Skip to content

Instantly share code, notes, and snippets.

@tomtom5152
Created October 5, 2015 13:41
Show Gist options
  • Save tomtom5152/aa695f6e1fd9bd1d8fcb to your computer and use it in GitHub Desktop.
Save tomtom5152/aa695f6e1fd9bd1d8fcb to your computer and use it in GitHub Desktop.
#pragma config(Sensor, S2, HTCS2, sensorI2CCustom)
//*!!Code automatically generated by 'ROBOTC' configuration wizard !!*//
#include "HitechnicColorSensor.h"
task main()
{
long r, g, b;
while (true) {
//use the sensor in passive mode (LED turned off)
HTCS2readRawRGB(HTCS2, true, r , g , b);
writeDebugStreamLine("%d, %d, %d", r, g, b);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment