Datasheet

IDUINO for Maker’s life
www.openplatform.cc
3 Example
This is a simple code for the DS18B20temperature module, Wire as below:
Example code :
******Code begin******
#include <OneWire.h>
// DS18S20 Temperature chip i/o
OneWire ds(10); // on pin 10
void setup(void) {
// initialize inputs/outputs
// start serial port
Serial.begin(9600);
}
void loop(void) {
//For conversion of raw data to C
int HighByte, LowByte, TReading, SignBit, Tc_100, Whole, Fract;
byte i;
byte present = 0;
byte data[12];