O'Reilly logo

Mastering Arduino by Jon Hoffman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Project 3 – environmental sensor

In this project, we will request, from the phone, that the Arduino send temperature or humidity information depending on the character sent. We will need to add the DHT-11 sensor to our circuit. The following diagram shows how to do this:

The DHT-11 temperature sensor is connected to the Arduino exactly as we did in Chapter 9, Environment Sensors. If you are unsure how to connect this sensor to the Arduino, please refer back to that chapter. Now we will need to write the code, so we can access the data from the sensor with Bluetooth LE service. We will start by setting up the SoftwareSerial library for the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required