Temperature and Humidity Sensor Pro (AM2302)
Last updated
Last updated
The Temperature and Humidity Sensor Pro is an upgraded version to the original Grove temperature and humidity sensor and it has more complete and accurate performance. The detection range of the Sensor Pro is 5% RH to 99% RH, -40°C to 80°C. The accuracy reaches up to 2% RH and 0.5°C. For detailed specifications, visit the official WiKi page of this component
You can see how to download and install the driver by referring to:
After the installation is done, follow the steps below to use this component.
Connect the module to the A0 header of the LinkIt 7697 breakout board.
Select the File / Examples / Grove_Temperature_And_Humidity_Sensor-master / DHTtester menu.
Click the Upload icon to compile and upload the sketch file to the board.
Open the serial monitor (with baud rate 9,600) and reset the board to execute the application. You should be able to see the output as below:
This library supports DHT11 / DHT22 (AM2302) / DHT21 (AM2301) sensors. Check the part number of your sensor and select the correct one in the sketch file. For example, if the sensor is DHT22 (AM2302), uncomment the Line 10 before execution.
Reference
If you're using sources from the repositories of module vendors:
the Seeed DHT library.
Please follow the steps to modify the codes for making it available to the LinkIt 7697:
Open the DHT.h file from the library folder.
Comment out the #error message in line 16 and define the COUNT
macro in line 17.
Save the file.