This is an old revision of the document!
Sorana-Elena ION (125961) 2023/05/06 16:32
My project is a weather station that gathers information about temperature, humidity, and pressure, and then sends it to a server in a MySQL database. From that database, a dedicated web page can display the data for the station.
The idea for this project started with my interest in weather monitoring and the desire to create a system that could gather and display weather data in a convenient way. I believe that this project could be useful for others who are interested in weather monitoring, as well as for myself to keep track of weather conditions in my area.
The purpose of the project is to provide real-time weather information that is accurate and accessible through the internet. This information can be useful for people who want to plan their day or activities based on the weather conditions.
I believe that the project is useful for others because it provides accurate and real-time weather information that can help people plan their day. It can also be useful for farmers, gardeners, and other people who rely on weather conditions for their livelihoods. For me, the project is an opportunity to learn about sensors, microcontrollers, and web development while creating something that can benefit others and myself at the same time.
+————————–+
| Weather Station |
+————————–+
|
| +-----------------------+
+------>| NodeMCU with ESP8266 |
+-----------------------+
|
| +---------------------+
+-------->| Weather Click Sensor|
| +---------------------+
|
| +-------------------+
+-------->| LCD Display |
| +-------------------+
|
| +------------------+
+-------->| Wi-Fi Connection|
| +------------------+
|
| +-----------------+
+-------->| MySQL Database |
| +-----------------+
|
| +-----------------+
+-------->| Django Admin |
+-----------------+
The NodeMCU with ESP8266 retrieves data from the Weather Click Sensor, which includes temperature, humidity, and pressure readings. This data is then displayed on the LCD Display. The NodeMCU with ESP8266 connects to the internet via Wi-Fi, allowing it to send the weather data to the MySQL Database for storage. The stored weather data can then be accessed and displayed on a web page.
The weather station is composed of the following important components:
The application firmware is developed using the Arduino IDE, which provides support for ESP8266 microcontrollers. It leverages various third-party libraries to enable specific functionalities and streamline the development process.
The code is developed using the Arduino IDE, which supports ESP8266 microcontrollers.
The firmware code implements various algorithms and data structures to ensure efficient data processing and handling.
Sensor Data Reading:
Data Transmission:
Communication Protocols:
Database Integration:
In addition to the firmware code, the project also involves integration with MySQL and Django for data storage and web application development, respectively.
MySQL: The firmware code is designed to send sensor data to a MySQL database. To achieve this, the firmware code includes functionality to establish a connection with the MySQL server and send the collected sensor data using an HTTP POST request. The server-side script, written in PHP or another suitable server-side language, receives the data and stores it in a MySQL database table.
Django: On the web application side, Django is used to develop a user interface for accessing and visualizing the stored sensor data. Django is a high-level Python web framework that follows the Model-View-Controller (MVC) architectural pattern. It provides a robust set of tools and features for rapid web application development.
In the Django code, models are defined to represent the structure of the MySQL database table where the sensor data is stored. Views are implemented to handle user requests and retrieve data from the database. Templates are used to render the HTML pages and present the data to the user in a visually appealing way.
The integration between the firmware code, MySQL, and Django allows for real-time data collection from the sensor device and seamless storage and presentation of the data through a web application. By combining the firmware code with Django and MySQL, you can create a comprehensive system that collects, stores, and presents sensor data, providing valuable insights and facilitating further analysis.
Fişierele se încarcă pe wiki folosind facilitatea Add Images or other files. Namespace-ul în care se încarcă fişierele este de tipul :pm:prj20??:c? sau :pm:prj20??:c?:nume_student (dacă este cazul). Exemplu: Dumitru Alin, 331CC → :pm:prj2009:cc:dumitru_alin.