Saturday, April 30, 2011

MCP9800 Temperature Sensor

A while ago I picked up a few temperature sensors from DigiKey, it's been in my junk box for sometime now, so I decided it's about time to do something with it!

Features
The MCP9800 is a high accuracy digital temperature sensor from Microchip, the sensor has an  I2C interface, a configurable 9-bit to 12-bit temperature resolution, shutdown mode, one-shot mode (one conversion while in shutdown) and finally an interrupt pin.

Typical Application
The MCP9800 requires a few external components, the standard I2C pull-ups and, depending on the polarity of the ALERT pin, a pull-up/down resistor.


ALERT pin
The ALERT pin gets asserted when the temperature exceeds the upper temperature limit (TSET register) and again when it falls back below the lower limit (THYST register). The interrupt must be cleared by reading any register.

Application
I used the MCP9800 in a wireless sensor network using nrRF4L01+ and atmega328, each node sends a unique id followed by the temperature reading to a central receiver which then sorts out the data and displays it.


Downloads
MCP9800 avr library (the library has a nice native avr I2C example)
hg clone https://mcp9800.googlecode.com/hg/ mcp9800

No comments:

Post a Comment