For this project we are building an Arduino-based thermometer and humidity display. It shows the current temperature, temperature index (feel), humidity level and dew point. It also displays a graph of the readings from the past 12 hours.
This design is*completely free* and shared under a permissive license. Your support is hugely appreciated.
Some of our designs cannot be found on Thingiverse. If you are looking for more, check out our premium projects:
https://codeandmake.com/premium
If you plan to 3D print the case included with this project, you will need the exact components listed below. If you use alternative components they may not fit inside the case.
You will need:
For the 3D printed case, you will need the following bolts/screws:
The DHT22 sensor is said to be accurate to within 0.5C and 5% humidity (the DHT11 is slightly less accurate). However, the electronic components used in this project generate heat, which can affect the sensor's measurements.
In particular, the Arduino's on-board voltage regulator generates a significant amount of heat, so we bypass the voltage regulator in this project by wiring a 5V power supply directly to the 5V pin and we mount the DHT22/DHT11 to the exterior of the case with an air-gap between the sensor and the case.
By doing this we've achieved temperature readings that are within 0.5-1.0C of independent thermometers.
The 2.8" display module has a optimum viewing angle that means it is best viewed from straight-on and below, or straight-on and above, but not both. Therefore, you should consider where it will reside once built.
We've created two versions of the case, meaning you can pick the one that will be best suited to your needs, depending on whether it will mostly be viewed from above or below. You should choose:
Before constructing this project, you should upload the code (.ino) to your Arduino.
If you haven't already, install Arduino IDE and configure it ready to program your Arduino.
Please see our tutorial for installing the Arduino IDE in Ubuntu and configuring it for an Arduino Uno. The steps will be similar for other operating systems.
The code for this project has several dependencies on other libraries. We recommend installing the dependencies through the Arduino IDE's Library Manager, which can be accessed via: 'Tools > Manage Libraries...'. Simply search for the following libraries and install them:
Please take a note of the following changes which may be necessary, depending on your needs:
If you will be using a DHT11 sensor instead of a DHT22 sensor, you should change the following line:
Before:
#define DHTTYPE DHT22 After:
#define DHTTYPE DHT11
If you will be using the 'rotated' version of the case (for viewing from above), you should change the following line:
Before:
const boolean rotateScreen = false; After:
const boolean rotateScreen = true;
If you would like to use 'light mode' (white background), you should change the following line:
Before:
const boolean darkMode = true; After:
const boolean darkMode = false; Wiring
We recommend wiring up the project and testing it before printing a case for it. This will allow you to test the components and the code (including any changes you make) and it will help you to decide which version of the case to use ('standard' or 'rotated').
As we will be wiring the power directly to the 5V pin, westrongly recommend checking the voltage at the 2.1mm power jack using a multimeter. Only use it if it reads close to 5V!
The jack's center pin isusually positive (+ve), but it depends on the USB to 2.1mm jack cable, so be sure to also check the polarity using a multimeter. Once you've checked the polarity, solder the two lengths of ~26 AWG wire to your 2.1mm jack socket accordingly.
Your Adafruit Proto-Screwshield (Wingshield) may arrive as a kit which will require soldering. If so, we recommend checking out this excellent guide.
Once everything is soldered, it's time to test it works. Please use this diagram as a reference:
If you haven't already, upload the code to the Arduino (detailed in the 'Code' section above).
Insert the Adafruit Proto-Screwshield (Wingshield) into the Arduino Uno.
Remove the female pin header connector from the cable that came with the DHT22/DHT11 sensor and strip the wires. If you'd prefer not to do this, you will require a cable with a JST-PH connector, but be aware that the colors and/or order of the wires may be different to the original cable!
Join the DHT22/DHT11's positive (+ve) wire (red) with the positive (+ve) power wire by twisting them together and insert them into the '5V' terminal of the Adafruit Proto-Screwshield (Wingshield).
Join the DHT22/DHT11's negative (GND) wire (black) with the negative (GND) power wire by twisting them together and insert them into a 'GND' terminal of the Adafruit Proto-Screwshield (Wingshield).
Insert the DHT22/DHT11's signal wire (green) into the digital pin '12' terminal of the Adafruit Proto-Screwshield (Wingshield).
Insert the 2.8" Display Module into the Adafruit Proto-Screwshield (Wingshield), being careful not to press directly on the screen, as you could damage it.
Finally, connect 5V power to the 2.1mm jack and, after a few seconds, you should see some measurements being displayed.
With testing complete, it's time to decide which case to print. Remember, you should choose:
If you will be printing the 'rotated' version, refer to the 'Code changes' section (above) to make the necessary code change and upload it to the Arduino.
You will need to print 3 parts; a front, a rear and the stand-offs:
*codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-Front-_Standard.stl - use this if it will mostly be viewed frombelow *codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-Front-_Rotated.stl - use this if it will mostly be viewed fromabove - Note: a code change is required for the rotated version - refer to the 'Code changes' section (above)
*codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-Rear-DHT22-_Standard.stl - use this if it will mostly be viewed frombelow and you are using aDHT22 sensor *codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-Rear-DHT22-_Rotated.stl - use this if it will mostly be viewed fromabove and you are using aDHT22 sensor - Note: a code change is required for the 'rotated' version - refer to the 'Code changes' section (above) *codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-Rear-DHT11-_Standard.stl - use this if it will mostly be viewed frombelow and you are using aDHT11 sensor - Note: a code change is required to use a DHT11 sensor - refer to the 'Code changes' section (above) *codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-Rear-DHT11-_Rotated.stl - use this if it will mostly be viewed fromabove and you are using aDHT11 sensor - Note: a code change is required to use a DHT11 sensor and a code change is required for the 'rotated' version - refer to the 'Code changes' section (above)
*codeandmake.com_Arduino_Thermometer_Display_Case_v1.0_-_Stand-offs.stl - use this no matter which sensor you are using
If the electronics are still assembled from testing, remove power, separate the boards and remove the wires from the Adafruit Proto-Screwshield (Wingshield) terminals.
You can now assemble the case in the following order:
Insert 2x M3x20mm bolts/screws into the mounting holes of the DHT22/DHT11 PCB
Thread the stand-offs onto the M3x20mm bolts/screws
Insert the ends of the M3x20mm bolts/screws into the rear of the case, such that the sensor is positioned on the outside of the case
Secure the bolts/screws with 2x M3 nuts
Thread the DHT22/DHT11's cable through the cable slot
Insert the 2.1mm barrel jack into the rear of the case and secure with the nut
Mount the Arduino Uno to the rear of the case using 2-4x M3x5mm bolts/screws - we ended up using 3, as we found that the screw head was too large to fit into one of the Arduino Uno's mounting holes
Insert the Adafruit Proto-Screwshield (Wingshield) into the Arduino Uno.
Wire the power and sensor wires to the Adafruit Proto-Screwshield (Wingshield) using the 'Wiring' section (above) as a reference
Connect 5V power to the 2.1mm jack to be sure everything works as expected
Attach the front to the rear of the case using 4x M3x12mm bolts/screws
Recommended slicer settings:
The "Arduino Thermometer Display" models (.stl) are licensed under the CC BY license by Code and Make.
The "Arduino Thermometer Display" code (.ino) is licensed under The MIT License by Code and Make.
We love to create free content for you. As you might imagine, it takes a lot of time. Supporters help us fund materials and equipment to create future projects and tutorials. To show your appreciation, please use the link below:
https://codeandmake.com/support
We thank you so much for your support!
Category: GadgetsThe author marked this model as their own original creation. Imported from Thingiverse.