Connecting Color Sensor to dsPic33
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Connecting Color Sensor to dsPic33

by Team7 on Thu Apr 20, 2017 6:14 pm


Currently my lab team is working on building a device that includes the TCS34725 color sensor, the one sold by adafruit. Our professor is requiring that all teams use a dsPIC33FJ64MC202 micro controller. We have purchased the sensor and we are struggling with how to connect the output data pin of the sensor to an input pin on our microcontroller.

We have noticed that most of the supporting documentation is for an arduino so we are having difficulties even understanding how we can have our microcontroller connect with the sensor. Also, we are confused on the output signal coming from the color sensor since the datasheet that we are finding does not give specific information for the 34725.

Please let us know if you could help or if there are any references or sample code we could look at. We only have a small budget that we can spend on this project, coming from our own pockets, so it would be unfortunate if the sensor was not compatible with the microcontroller.


Posts: 1
Joined: Thu Apr 20, 2017 6:01 pm

Re: Connecting Color Sensor to dsPic33

by adafruit_support_mike on Fri Apr 21, 2017 3:04 am

The TCS34725 is an I2C device, and its interface is described starting on page 12 of the datasheet:


Find some refefrence code that shows how to do I2C communication for the microcontroller you're using, and then you'll be able to adapt the sequences of I2C messages used in the Arduino library to that platform.

Posts: 50680
Joined: Thu Feb 11, 2010 2:51 pm

Please be positive and constructive with your questions and comments.