In this tutorial we will use Nextion display, rtc1307 time module, Arduino UNO, and Visuino to display current time, temperature and humidity.
Watch a demonstration video.
First make sure the SD card is formatted in FAT32 (Use some software like card formatter )
On the menu click on "Tools>Font generator"
When you have placed and position all the elements:
To start programming the Arduino, you will need to have the Arduino IDE installed from here: https://www.arduino.cc/.
Please be aware that there are some critical bugs in Arduino IDE 1.6.6. Make sure that you install 1.6.7 or higher, otherwise this Instructable will not work! If you have not done follow the steps in this Instructable to setup the Arduino IDE to program Arduino UNO! The Visuino: https://www.visuino.eu also needs to be installed. Start Visuino as shown in the first picture Click on the "Tools" button on the Arduino component (Picture 1) in Visuino When the dialog appears, select "Arduino UNO" as shown on Picture 2
Double click on "RealTimeClock1" component, elements window will open and:
Select "FormattedText1" component and under properties window set "text" to: %0:%1:%2
Double click on "FormattedText1" component, elements window will open and:
Drag 3x "Text Element" to the left
Double click on "DisplayNextion1" component, elements window will open and:
Drag 3x "Text" element to the left and for each element set:
Make sure you have the Nextion file on the SD card
Now the Nextion Display is ready.
In Visuino, Press F9 or click on the button shown on Picture 1 to generate the Arduino code, and open the Arduino IDEIn the Arduino IDE, click on the Upload button, to compile and upload the code (Picture 2)Note:
Make sure when you are uploading the code to Arduino to Disconnect Arduino pin[RX] and Arduino pin[TX]
After the Upload is finished connect back the Arduino pin[RX] and Arduino pin[TX]
If you power the Arduino UNO module, the Display will start to show a current temperature and humidity level + time that you set in Visuino. Congratulations! You have completed your Weather station project with Visuino.
Also attached is the Visuino project, that I created for this Instructable You can download and open it in Visuino: https://www.visuino.com
and
Nextion File for Nextion Editor (Weather.HMI) and compiled Nextion file (Weather.tft) that you can copy directly to your Nextion display.
You can also check this amazing tutorial to learn how to work with Nextion Displays
https://www.instructables.com/id/Visuino-Nextion-Lcd-Based-Acceleration-to-Angle-Di/