Project Description of IoT Based Mushroom Cultivation System:
This paper aims to explain temperature and humidity control and monitor in the mushroom cultivation process using the Internet of Things technology by utilizing the MQTT protocol. The MQTT protocol is used because of its ability to transmit data from the sensor as a publisher to a subscriber with cloud services as a broker or a server. The MQTT protocol was chosen because it has a faster data transmission rate than using The Hypertext Transfer (HTTP) Protocol.
The application of the Internet of Things (IOT) to mushroom cultivation is to reduce human intervention in controlling and monitoring temperature and humidity in the mushroom cultivation room in real time.
The data communication protocol used on the Internet of Things is the Message Queuing Telemetry Transfer protocol (MQTT). MQTT protocol works with the concept of Publish/ Subscribe where the communication occurring uses a low power but it is sufficient enough to transmit data on the Internet of Things. There are several reasons why using the MQTT protocol as the basis of the work of the Internet of Things such as the existence of limited power on devices: sensors, relays. The device uses low power but it determines the success in the transmission process. Thus, it can be concluded that the use of MQTT protocol is the proper decision. The second reason is that limited bandwidth and connection are not always connected, while the Internet of Things requires speed in updating data.
The use of the MQTT protocol on Internet of Things technology is preferred over The Hyper Text Transfer (HTTP) protocol because the MQTT protocol only requires low power and a small bandwidth but the accuracy and speed of data transmission can still be relied upon. MQTT Protocol Working Principle
The publisher with subscriber is connected to the broker or a server, There are three main components in the MQTT protocol namely publisher, broker or server and subscriber.
- Publisher is a component that collects the data from real- time sensors. Before being sent by the publisher, the data publishes certain topics such as temperature, humidity, and others.
- Subscriber is the recipient of data topics from the publisher in the form of sensor values, humidity values and others. Topic data can be displayed on the mobile application or the dashboard user interface.
- Broker is an intermediary third party that manages the transactions between publisher and subscriber. A broker mainly aims to collect and process data from the publisher and send to the subscriber. Here is where the process of data topics will be processed and therefore the broker is a smart- device that is able to process data topics at one time. Brokers can be called a server’s ability to process data and can be a cloud service.
The system would consist of a set of hardware and software components. On the hardware side, the system would include DHT11 sensor, relay module, fan and sprayer along with Raspberry pi installed at mushroom cultivation room, as well as a communication module i.e., MQTT for sending data back to a central server. On the software side, the system would include a cloud-based platform here we use ThingSpeak dashboard for receiving, analyzing, and displaying the data.
For data-communication, MQTT protocol is used. MQTT protocol works based on the publisher-subscriber paradigm with broker or server intermediaries. In the recent study, Raspberry Pi 3 works as a broker / server is a small computer device with large capabilities. This device will later connect the publisher with the subscriber via cloud services.
Raspberry pi 3 model B is used as a server/broker. Raspberry pi is provided with by Python language to support the MQTT protocol through general purpose input output (GPIO) socket as the gateway of two- way communication.
The hardware (sensor and the automatic tools) is connected with raspberry pi and Thingspeak as the real-time database management. Thingspeak database provides responses to process automation of DHT 11 sensor. This sensor is a digital data processing type that will easily support.
The first testing is done by measuring the average of overall temperature and humidity. From this test, it is revealed that, the DHT 11 sensor starts giving response on temperature data and delivers it to the raspberry pi when the power supply is on. The data is further stored in the Thingspeak database. After conducting five tests, the results reveal that the average temperature is 32C and the humidity is 77%.
In the first entity, the test result of data delivery from the hardware (sensor, fan, spray, raspberry pi) to the thing speak for every second when the temperature is 32C and the humidity is 77% is 1.22 second and 1.18 second respectively. Meanwhile, the test of SYB-ACK in HTTP protocol reveals that the average time to transfer the data from thing speak to smart phone is 1.74 second for the temperature 320 C and 1.62 second for the humidity 77%.
The aforementioned tests indicate the results of average estimated time for each protocol. In this case, MQTT result is smaller than HTTP result. While in HTTP protocol needs 1.74 second, it only needs 1.22 second in MQTT. Thus, it can be inferred that MQTT is faster than HTTP in transferring the data. In addition, MQTT has better ability when it is integrated with IoT. As MQTT offers much better capability in transferring data, it becomes one the best choices in applying real-time controlled connectivity among hardware.
Generally, MQTT protocol has faster speed in transferring data than that of HTTP . The development of this protocol is suitable to be applied as assisting tools in cultivating mushroom. Besides, machine to machine automation has not been applied yet. The second test carried out in this study is regarding the speed (estimated time) to reach the ideal condition. The test in conducted by setting the temperature and humidity in random condition. By using MQTT protocol-based application, the condition is controlled in order to reach the ideal temperature and humidity.
Therefore, MQTT protocol for internet of things can be used as a tool to monitor and control the room temperature and the humidity in mushroom cultivation. As the results, dependence on human labour can be reduced.
Hardware and software requirements for project implementation:
Hardware Requirements for IoT Based Mushroom Production System :
- Raspberry Pi : To process the data from the sensors and control the communication module.
- DHT11 Sensor : Used to measure Temperature and Humidity.
- Fan : Used to control air-circulation.
- Relay: Used to control the ON/OFF of the circuit contacts of an electronic circuit.
- Sprayer: Used as watering device.
- Power Supply: Utilized to supply electric power to an electrical load.
- Internet Modem: used for internet connection.
- Things peak: Using as a real-time data-base.
- Jumper Cable: Used to interconnect the components.
- VNC Viewer / Python Idle: Used as a software.
Software Requirements of IoT Based Smart Automated Mushroom Production System:
- Operating system: To run on the microprocessor and manage the system’s resources, Linux is the most frequently used OS on the Raspberry Pi.
- Sensor drivers: To communicate with the DHT11 sensor, relay module and sprayer.
- Communication stack: To manage the system’s communication with the central server.
- Algorithm: To process the data from the sensors and control the communication module.
- Cloud Platform: To receive, store, analyse and display the data, and enable mushroom cultivation room to access the data remotely.
- Mushroom cultivation Application: To enable the mushroom cultivation to monitor and control the system remotely using a web interface or a mobile application.
- Monitoring the temperature and humidity of the cultivation room: To enable the automatic monitoring of the temperature and the humidity from the cultivation room.
It’s important to note that the specific hardware and software requirements will depend on the system’s design and your specific requirements.
What You Will Learn? By working on IoT Based Mushroom Cultivation project
- IoT Fundamentals: Students will gain a deep understanding of the concepts and technologies that understanding IoT, including embedded systems, microcontroller programming, sensor networks, and cloud computing.
- Hardware and software integration: Students will learn how to design, assemble, and program an IoT system that integrates various hardware and software components.
- Algorithm development: Students will learn how to develop algorithms that process data from sensors and enable the system to automatically control mushroom cultivation room.
- Cloud computing and data management: Students will learn how to set up a cloud platform to receive, store, and analyze data, and create an application to monitor and control the system remotely.
- Monitoring temperature and humidity : Students will learn how to monitor the temperature and humidity on the cloud platform
- Project management: Students will learn how to plan, implement, test, and deploy a real-world IoT-based project.
- Portfolio building: Students will learn how to document their work, build an effective portfolio, and market themselves to potential employers in the IoT field.
- Networking and staying updated: Students will learn how to stay updated on the latest developments in the field and develop their networking skills to expand their opportunities in the industry.