1412 views|1 replies

86

Posts

0

Resources
The OP
 

Design of intelligent controller for tea brewing machine based on Gizwits IoT platform [Copy link]

Abstract: With the integration of smart phones, the Internet of Things and cloud services, the intelligence of the home has become a development trend. Taking the function control of the tea maker as the starting point, this paper designs an intelligent controller based on the Internet of Things cloud platform .
It mainly includes the design of single-chip intelligent controller and the cloud platform access of the equipment, and finally realizes the control of various functions of the tea maker through mobile phone APP. Based on the development of automatic tea maker intelligent controller, it provides a reference for studying the application of controller based on the Internet of Things cloud platform in smart home.
1. Design Idea
Figure 1 Control board functional block diagram
At present, the tea makers on the market have quite complete basic functions, such as water cup detection, water temperature control, water level monitoring and water shortage alarm, but the control of these functions still requires users to press the corresponding buttons on site, and the intelligence and comfort are far from enough. Based on the existing functions of traditional tea makers, this project will design an intelligent control panel to integrate all the functions of the tea maker, and connect the tea maker to the Internet of Things cloud platform through a wireless module. Users can control all operations of the tea maker on the mobile phone APP, which is very suitable for use in homes and offices, allowing users to experience the intelligent life of tea being brewed before they arrive.
The functional block diagram of the control board is shown in Figure 1. This project uses a low-power, high-performance single-chip microcomputer as the main control chip, which is connected to the existing functional modules of the tea maker to achieve integrated control of functions. It uses the domestic mainstream WiFi module and connects with the module system GAgent on the device side according to the protocol provided by the cloud service provider (Gizwits Cloud) , so that the device can quickly access the cloud.
2 Hardware Design
2.1 Main control module
The C8051F34X series is a fully integrated mixed-signal system-on-chip MCU with a high-speed, pipelined 8051-compatible controller core, a full-speed online on-chip system debugging interface, a built-in 10-bit 200ksps single-ended/differential ADC, and an analog multiplexer. This project uses the C8051F340 chip as the core to connect the various functional modules of the tea maker to achieve integrated control, as shown in Figure 2.
Figure 2 Main control chip connection diagram
The IO port function allocation of the main control unit is shown in Table 1.
2.2 Wireless network transmission module
This project selected the commonly used esp8266-01 , and the unit module is shown in Figure 3. This is an ultra-low power UART-WiFi transparent transmission module that can connect the user's physical device to the wireless network, communicate with the Internet or LAN, and realize the networking function. The module supports the wireless 802.11b/g/n standard, has three working modes to choose from: STA/AP/STA+AP, has a built-in TCP/IP protocol stack, supports multiple TCPClient connections, and supports UART/GPIO data communication interface. The ESP-01 module needs to add a 3.3V voltage regulator module to ensure stable power supply, so a 3.3V voltage regulator circuit is designed in the circuit, as shown in Figure 4.
Figure 3 Wireless transmission circuit
Figure 4 Voltage stabilization circuit
2.3 Water temperature detection module
ADC collects the voltage on the temperature measuring resistor to calculate the current water temperature. VREF is the reference voltage of ADC. The circuit in Figure 5 is used to measure water temperature. The reference voltage is buffered by the op amp and then passes through R7 and the temperature measuring resistor to form a voltage divider circuit.
Figure 5 Water temperature detection circuit
2.4 Other detection modules
In this project, water inlet detection, water outlet monitoring, water cup detection and switch detection circuits are also designed, as shown in Figure 6. The existing sensor circuit of the tea maker is used to connect it to the IO port of the microcontroller, and the state of the tea maker is detected according to the change of the input level so that the program can process it.
Figure 6 Water inlet, water outlet and water cup detection circuit
2.5 Output Control Module
The output control part of the tea maker is also controlled by the integrated single-chip microcomputer chip, as shown in Figure 7. After the IO port outputs the control level, it outputs a large control current through ULN2803 to drive the relay to control the normal operation of the three water pumps, heat preservation heating, buzzer and three-color signal lights. The specific functions are defined in the program.
Figure 7 Output control circuit
Figure 8 Tea Maker Workflow Diagram
3. Software Design and Debugging
According to the workflow of the teapot, design the main control process, as shown in Figure 8.
This project uses the cloud platform provided by Gizwits for remote control. Gizwits is the world's leading IoT development platform and IoT cloud service provider. Before using the Gizwits platform services, you need to register a Gizwits developer account, which is divided into two types: personal developer and enterprise developer. Personal developer accounts can be used for product access, device management, OTA services, MCU development, etc., and can access 10 devices for free testing. This project uses a personal developer account for cloud access.
After logging in to the backend of the Gizwits Developer Center, click the "Create New Product" menu in the upper right corner of the backend of the Developer Center, create a new product named "SmartTeaMachine" on the jump page, select the "Wi-Fi/Mobile Network Plan" method to access, and complete the first step of product creation. Then set the data points of the product. Data points refer to the functional abstraction of the product, which is used to describe the product functions and their parameters, and are represented by different data types. For example, the simplest device "switch" has the functions of: on and off. It is abstracted into a data point of Boolean type, 0 means off, and 1 means on. After creating the data point, the data format of the communication between the device and the cloud can be determined, and the device and Gizwits can recognize the data of the interconnection between the device and Gizwits.
Data points are an important attribute of a product, so the first step in product intelligence is to clarify product functions and create corresponding data points on the platform one by one to describe the functions. Next, the cloud will generate the device-side code for the corresponding product based on the data points defined by the product. The automatically generated code implements the parsing and packaging of the Gizwits communication protocol, the conversion logic of sensor data and communication data, and is encapsulated into a simple API, and provides example codes for multiple platforms.
When the device receives data from the cloud or APP, the program will convert the data into corresponding events and notify the application layer. Developers only need to add the sensor control function in the corresponding event processing logic to complete product development. When using automatically generated code to develop products, there is no need to deal with protocol-related parts. Developers can focus on the core function development of the product.
Figure 9 Smart tea maker APP control terminal
After the data points and device-side codes are set, you can use the Gizwits Cloud APP on your mobile phone to connect and debug the product. The mobile control interface is shown in Figure 9.
4 Conclusion
After joint debugging of software and hardware, this design finally enables users to remotely control the various functions of the tea maker using an APP on their mobile phones. As shown in Figure 9, by selecting the data point number value from 1 to 10, multiple modes of tea brewing programs can be switched, and functions such as automatic teacup cleaning and water temperature adjustment can also be selected in the APP.
The current trend is to research smart homes based on cloud services. The smart control panel developed in this project can also be extended to control other small home appliances, realizing innovation in the control method. Traditional home appliance control is nothing more than controlling the home appliances through buttons on the appliances or dedicated remote controls, while smart homes can be controlled through an integrated operating experience: they can be operated on a mobile phone or on a dedicated operating device, through touch, voice or even gestures. This unified control of all home appliances not only improves the user's operating experience, but also reduces the hardware cost of the entire system.

This post is from RF/Wirelessly

Latest reply

In fact, you feel that there is a lack of usage scenarios here, and using a mobile phone to control it does not reflect much convenience   Details Published on 2022-12-1 07:23
 

6060

Posts

6

Resources
2
 

In fact, you feel that there is a lack of usage scenarios here, and using a mobile phone to control it does not reflect much convenience

This post is from RF/Wirelessly
Personal signature

在爱好的道路上不断前进,在生活的迷雾中播撒光引

 
 

Guess Your Favourite
Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

快速回复 返回顶部 Return list