How to Hookup Arduino to the AM2315 Temperature - Humidity Sensor
The AM2315 is a digital I2C humidity - temperature sensor that is mounted in a protective housing. It is not waterproof but sufficient to provide some protection to both sensors mounted inside. It use the DS18B20 along with a capacitive humidity sensor. It has it's own controller that provides a I2C interface to both of these sensors. We cannot change the address of device so it only supports one device per I2C bus. It is supplied with two mounting brackets depending on how you want to physically mount the device.
Hardware and Software Parts List
- Arduino Board
- AM2315 Sensor. We used the Adafruit PN
- 2 * 10K Pullup Resistor
- Breadboard hookup wires
- USB Cable to suite Arduino
- Sample Sketch ( )
- AM2315 Library ( )
Wiring diagram for connecting the AM2315 Sensor to the Arduino
Breadboard Wiring diagram for connecting AM2315 Sensor to the Arduino Board
We can test this sensor using the simple sketch as shown below. It requires the cactus.ioto communicate with the sensor.
It reads the temperature and humidity every 2 seconds and then displays it on the console.Limitations
- Supports only one sensor on the I2C bus
- Its blocking code.