石榴姐

#the4thLichuangcompetition#Instant heating pulse valve flushing smart toilet

 
Overview

Note: * is required.

[Please fill in during the registration stage↓]   A brief introduction to the work: The smart toilet became the focus of the "Auntie" overseas snap-up in the past few years and began to be understood by more people. It itself began to be used as a medical device for civilian use, and it is actually now It is very meaningful for busy modern people, especially the health brought by clean water cleaning, especially the gentle seat in winter, especially the wide application of instant heating to bring a more skin-friendly user experience. In recent years, the market After the gradual development, the products have become more and more user-friendly, and the development of subdivided fields has further demonstrated the capabilities of this top-level bathroom product. [Please fill in ↓ during the competition stage]   1. Details of the work; The smart toilet designed this time uses modern The more popular instant heating method is non-traditional heat storage toilet. There are probably several main functions. 1. In the flushing part, there is almost no conflict between flushing and other functions. You can flush at any time without affecting Cleaning, seat temperature, remote control, and other functions, so this time the flushing function is separated into a thread. Another feature of the flushing function is that it can be used normally when the mains power is stopped. 2. Cleaning and drying. This part Basically, the current methods are mutually exclusive (a few manufacturers can start drying when the nozzle does not spray water, but the difference is not big, so I will not follow them one by one). The main cleaning methods include women's washing and buttock washing. There is not much difference in basic functions. The angle of rotation of the water valve controller (like a faucet) controls the size of the water outlet, allowing users to obtain appropriate water pressure and a more comfortable cleaning experience. It is also equipped with massage cleaning and wide-width cleaning. Massage cleaning is done by turning the water inlet valve The gas is blown into the water flow, thereby increasing the pressure of the water, and when passing through the nozzle, the water will be dispersed, resulting in a better cleaning effect. Wide-width cleaning allows the nozzle to move back and forth during the cleaning process, thereby providing a better cleaning experience (also A kind of massage effect). 3. Drying function. To achieve drying without paper after cleaning, you need to rely on warm air drying. This place is equipped with a high-power fan and mica clip heating wire (220v power supply heating). It is a bit Similar to a hair dryer, it can dry the human body. 4. Seat heating: This function is also completely independent from other functions. It is achieved by burying heating wires (low power, about 5,60W) and temperature sensors inside the seat. Keep the seat ring in a suitable temperature range (of course, this temperature is the internal temperature of the seat ring and can only be a reference value in actual applications, so it is normal for the same gear to be colder in winter). 5. This use The mobile phone app controls the toilet through Bluetooth (the large-scale application of Bluetooth transceiver in this industry is still useless for the time being, most of them use 433, 2.4g, infrared). It is a new attempt and exploration. Because now the toilet actually has many functions, and For example, the position of the nozzle can be easily switched steplessly, and the water divider valve can also be used to steplessly control the water flow from large to small, so as to better obtain the appropriate water pressure. The other is health data, which is also written this time. One of the main reasons for this project is that as a product that can directly come into contact with people, the smart toilet can obtain certain data, such as squatting time, cleaning time, drying time. In addition, there are some custom water temperatures, etc. It doesn't seem like much, but many of them are closely related to health. Squatting down to read information on mobile phones as soon as you go to the toilet, washing for too long, and drying for too long all reflect some problems. However, this project is only for data collection, and other things are temporary. No processing.   2. Describe the challenges faced by the work and the problems solved; This smart toilet uses RTOS this time due to its large number of functional modules, and uses the freeRTos that comes with stm32cubemx, but the selected chip The ram of stm32f030c8tx is very small, and it is quite tight after running the system. Therefore, many places that should have used threads are now completed with timer scanning. When looking at the software, don’t have too many problems in this regard. (We welcome all kinds of communication at the same time. After all, this industry is very marginal in electronic products, with many functions and many manufacturers in demand). In addition, there are buttons and seat temperature ADC reading, because there are a total of 12v, 10v (battery variable), 5v, 3.3v on the motherboard. , 220vac, so the interference is very large. I have used interrupts to trigger the buttons before, but they often trigger for no reason, and the buttons jitter, so I use a continuous scanning method, the same is true for ADC, and at the same time do data edge processing such as high and low. Bluetooth communication part It is also more difficult, because some third-party imitating bt4.0 directly uses cc2541 to open the port and transparently transmit data, and then there are often some strange problems when debugging, restarting, and the phone loses link. I will rewrite this if I have the opportunity in the future, and provide The main control chip can actively disconnect the BT from the mobile phone and other functions. After all, this Bluetooth chip has its own MCU function, which is more than enough to process some data.   3. Describe the key points involved in the hardware and software parts of the work; Hardware part: The smart toilet integrates many level power supply, so there is a lot of interference. The typesetting is still relatively particular. Of course, due to personal issues, the work may be relatively ordinary. Many switches have reverse current when they are turned off, so there are a lot of tests in the selection of switch tubes. And basically all of them are selected. It has freewheeling, but the consumption of the switching tube is not very important. Since the gate resistors are across voltages, they are selected relatively large, mainly because they are afraid that the current will flow back to the chip when something goes wrong. Software part: This time, stm32cubemx is used. For initialization work, the LL library is used to implement functions normally, and freeRTos is used for the system. The mobile terminal uses flutter and the third-party library shared_preferencesflutter_bluecupertino_iconssqflite. As an accessory product, the mobile terminal will not be introduced in detail (mainly actual control, and recording health data).   4 . , Material list of the work; Electronic accessories are in the BOM table. Some of the resistors may be better with fine-tuning. You can try it yourself. Other peripheral accessories are as follows: Fuxin bistable pulse solenoid valve (many brands are available, but for the time being, you can get this one Subject to) 30w 12v voltage (customized glue injection, as long as the power is appropriate, it can be used, because the toilet needs to be waterproof, so this treatment is done) Xinhuida 220v 10a leakage protection switch Jin Yatai instant heating module nozzle water separation valve set with Rayleigh Motor, hT motor for water separation valve 5015 deodorizing fan 7530 drying fan water inlet solenoid valve diaphragm air pump chewing gum battery wires and soft hoses 5.   Upload the picture of the work; (the competition logo must be on the PCB and take a photo to upload. If If you ignore it, you will be deemed to have given up the competition.) Back of overall product the main control board * 6. Demonstrate your work and record it as a video for upload; (The content of the video must include: introduction of the work; function demonstration; performance test; close-up shot of the competition logo on the PCB. If you do not show it, you will be deemed to have given up the competition. )imageimage

7. Open source documents. https://github.com/vachelcai/intelligent-closestool  software part, and some parts will be updated slowly. The temporary version can run normally and realize all functions. I will not exclude the mobile app part and explain it. It is only used as an accessory to ensure the function for the time being. It can run, but it is not ready to be perfected, because BT cannot actively release the link after connecting it to a mobile phone. Moreover, during the test, it was found that it is easy to connect directly through the wall. This is indeed not suitable for actual user use, and the wiki page will be updated. If you like the corresponding data transmission format, you can also improve it together. After entering the mobile app, modify the conBan.dart page

var _BTid = /*"98:5D:AD:1D:57:5A"*/ "00:15:83:00:AB:00" ;

If you don’t know the ID of the module, you can run it online. The software will print the scanned Bluetooth ID, and then you can improve it and run it. Then the time when the health data is transmitted will be temporarily inaccurate. I don’t know if it is a mobile phone setting. Problem. I don’t plan to correct it in detail. I plan to use normal remote control + wifi networking later, and then control and health data will be separated, and more detailed records such as personal habitual temperature and wind temperature will be added. The Bluetooth interface communication method has been updated. In this way, even without a mobile app, you can directly control the smart toilet through a computer + serial port tool + Bluetooth transceiver module. Code introduction address: https://github.com/vachelcai/intelligent-closestool/wiki/Remote control communication code explanation will be updated next , Low battery storage data, because the smart toilet has a battery, so the normal operation data (setting gears, recording superscripts and subscripts of health data, etc.) are stored in the memory, and then when low battery is detected, the first Turn on the battery power at the time, then write the mark (record systick), and then disconnect the battery voltage. When entering again, first compare the tick (0 means it has not been recorded, it must be recorded. If the tick happens to be 0 when writing, it will automatically change to 1. I have no impression of actual use. If I happen to tick a group and then check the range, it will not affect it. It has been for several months.) (Remarks, I just checked the programming manual and there is no pvd for f030. Write the save state function first, and then read See whether to use a software watchdog or a scanning method to read the internal reference voltage ADC. At the same time, the capacitance of the 3.3v segment may be modified to increase the duration during power outage to trigger a low power interrupt. If it is slower, it will be updated on GitHub.)

参考设计图片
×
 
 
Search Datasheet?

Supported by EEWorld Datasheet

Forum More
Update:2025-05-14 16:51:28

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
community

Robot
development
community

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号