ds18b20 library cc3200

A DS18B20 Driver for TICC3200 SimpleLink MCU

A couple of days ago, I completed a project for one of my clients during which I came across a situation to use this amazing temperature sensor. I suggested my client that we could use a dht11 or lm35 instead to do the job. But for some reason, he insisted me on wanting to use the ds18b20 temperature sensor for the following reasons:

  1. The ds18b20 provides better resolution than dht11 and LM35 i.e. 12 bit.
  2. The ds18b20 provides better accuracy.
  3. You can connect as many ds18b20’s as you want on a single bus and effectively communicate with each of them independently without collisions. So, it provides the ability to develop a distributed multisensor system.
  4. It has a feature called parasitic power which eliminates the use of external Vcc. This is a very useful feature that helps reduce power consumption and deploy your systems in remote locations.
  5. It uses a one-wire protocol which is simple use.

After I was done with the development, I performed a couple of tests to see how this sensor works. To my surprise, they are indeed better than the dht11 and lm35 in terms of resolution, accuracy and stability.

In short, the ds18b20 is a very reliable temperature sensor and can be used in a wide variety of applications such as industrial control systems, consumer electronics etc.

1. DS18B20 Driver/ Software Library

This driver can be very easily included in your project just by adding the following files to your project.

The driver can be found in my Github repo or can be cloned using the below command.

2. Demo and Scope of Extension

The below video shows the working demo of the ds18b20 temperature sensor driven by the TICC3200. The driver was developed on CCS7 IDE using the CC3200 SDK 1.3.0.

At present, this driver can support communication with just one ds18b20 sensor. Multi-drop and parasitic capabilities are yet to be implemented. When implemented, it shall be updated on Github accordingly.

Leave a Reply

Your email address will not be published. Required fields are marked *