I am using the chipKIT Wi-FIRE with the basic I/O shield and MPLABX IDE. I want to read out the temperature sensor of the I/O shield via I2C and write the value to the OLED display. I do see a value on the OLED-display that reacts on the sensors environment (i.e. it increases when I put my finger on the sensor), however it is clearly wrong as I get 360°C for room temperature (before anyone asks: I know I have to multiply the sensor value with 2^-4 to get a the correct numerical value). To initialize the bus and read out the sensor value I followed an example found on https://sites.google.com/site/johnkneenconnectedlab/i2c, but it goes much beyond what I actually want to accomplish and modifying that code just leads to the result mentioned above.
So here is my question: is there some starter code to simply read out the temperature sensor in this setup?
Question
bobby
Hi there,
I am using the chipKIT Wi-FIRE with the basic I/O shield and MPLABX IDE. I want to read out the temperature sensor of the I/O shield via I2C and write the value to the OLED display. I do see a value on the OLED-display that reacts on the sensors environment (i.e. it increases when I put my finger on the sensor), however it is clearly wrong as I get 360°C for room temperature (before anyone asks: I know I have to multiply the sensor value with 2^-4 to get a the correct numerical value). To initialize the bus and read out the sensor value I followed an example found on https://sites.google.com/site/johnkneenconnectedlab/i2c, but it goes much beyond what I actually want to accomplish and modifying that code just leads to the result mentioned above.
So here is my question: is there some starter code to simply read out the temperature sensor in this setup?
Link to comment
Share on other sites
4 answers to this question
Recommended Posts
Archived
This topic is now archived and is closed to further replies.