The current lack of water resources is a worldwide problem, and water shortages will become an important factor constraining national economic and social development. At present, China's water resources situation is a resource shortage and waste of use coexist, and price is the adjustment lever of resource optimization configuration, so reasonable water price is the key to water conservation.
In order to adapt to the reform of the national water system, on the basis of the original smart water meter, the ladder billing multi-rate accounting function has been added. The water meter receives the relevant water parameters of the ladder water price, adjusts the current (step) unit price inside the water meter according to the change of the water consumption of the water meter in the current month, and calculates the remaining amount in the water meter in real time according to the water consumption parameter and the water consumption in the current month. Management of users and water supply departments. To alleviate the financial pressure caused by the “first water supply and post-charge†and the waste of water resources in the society, the IC card smart water meter system developed in this paper can effectively solve the above problems.
1 system composition and working principle
The composition of the IC card type smart water meter based on MSP430F413 is as follows:
The IC card smart water meter works by measuring and controlling the total volume of water flowing through the tap water pipe. When there is a metering pulse, the MCU changes from sleep to working state, and the corresponding billing process is performed by the microprocessor: when the user reaches a certain limit of water in the unit time segment (generally calculated on a monthly basis), with the water consumption Increasing the price of water increases step by step. The more water used, the higher the price of water used. The water meter receives the relevant water parameters of the ladder water price, adjusts the current (step) unit price inside the water meter in real time, and calculates the water consumption data such as the remaining amount in the water meter in real time according to the water consumption parameter and the water consumption in the current month. When the remaining amount of water used by the user reaches the preset alarm amount (the alarm amount is set by the water meter management department), the water meter will automatically close the valve alarm, thereby reminding the user to purchase water as soon as possible. When the recharged IC card is inserted into the water meter for recharging, the MCU in the IC card water meter first recognizes the IC card password and confirms that it is correct, then reads in the purchased water amount and accumulates with the remaining amount in the water meter, and the water meter is based on the ladder of the water sales department. Water price, real-time billing, regular settlement. After the settlement, the current water consumption is zeroed, the total water consumption is accumulated in real time, and written into the memory of the IC card water meter, and then the solenoid valve is opened. The working state and the recharge amount of the refilled water meter will be displayed on the liquid crystal display, when the water meter is manually disassembled or When the remaining water volume is lower than the set value, the water meter alarms and closes the valve in time, and saves the data in the internal Flash.
2 hardware design
The hardware system of the IC card smart water meter mainly includes the following circuits: microprocessor, IC card interface, liquid crystal display, water meter detection, power supply detection, electronic control valve control interface and sound alarm circuit.
(1) Microprocessor. The microprocessor is the core of the entire smart water meter, and it is responsible for information judgment, recognition, calculation, processing and so on. After comparison of performance, quality and price, the microprocessor uses TI's MSP430F413 microcontroller. The MCU is an ultra-low-power Flash 16-bit RISC instruction set MCU with rich on-chip peripherals, operating voltage of 1.8V to 3.6V, built-in LCD driver 24 & TImes; 4 segments, which can reduce the size and cost. It is especially suitable for applications where low power consumption is required, such as on batteries or handheld devices.
(2) IC card interface. From the perspective of cost saving, the IC card interface uses the FM4442 memory card produced by Fudan Microelectronics Co., Ltd. It uses a 0.6-micron CMOS EEPROM process with an internal 256-byte user memory, a 32-byte write-protected area, and a 3-byte programming security authentication code. The peripheral interface complies with the IS07816 protocol standard (synchronous transmission). Make full use of its internal and external resources, the user memory stores the user's water volume; the protection of the storage area and the encryption memory programming can realize the personalized design of the IC and improve the security of use. Its interface circuit with the microcontroller is shown in Figure 2:
(3) Liquid crystal display. As the output interface of the water meter, the liquid crystal display mainly functions to output various operating states of the water meter and related data; in addition, it has the function of prompting the user. In order to reduce power consumption and save costs, a custom-designed liquid crystal display is used in the design. Its interface is shown in Figure 3:
As the output interface of the water meter, the liquid crystal display not only displays the switch status of the electromagnetic valve, the remaining amount in the table (when the balance is negative, the water meter is overdraft), the accumulated water consumption, the battery status, the accumulated water consumption this month, and the segmentation ( When the water price is stepped, the price limit of each water price is displayed, the unit price (current water price) is displayed, the current date and the current time, and the information and error information that reminds the user to recharge in time.
3 software design
The IC card smart water meter software design adopts modular processing. The main control program includes: system initialization, status judgment, flow pulse and water consumption processing, alarm prompt and low power mode processing, etc., the key is the billing processing part and the gatekeeper. The initialization of the dog. The function subroutine includes: IZl module of IC card (including IC card validity judgment, read/write and IC card decryption and encryption), billing processing module (including ladder water price segmentation billing judgment and processing) and valve control Modules, etc. The main program flow chart of the system is shown in Figure 3.
Figure 4 main program flow chart
The system initialization includes the stack of the MSP430F413, each port, interrupt, LCD control register settings, so that the CPU can work normally; after the system is initialized, enter the low power mode, until there are various interrupt conditions to wake it up, then enter the corresponding interrupt Service program.
4 system functions
Designed and developed IC card smart water meter, in addition to pre-paid, ladder water price billing, fault detection and other functions in vitro, but also has the following special features:
(1) Automatic alarm function: When the remaining water volume is used to set the alarm amount, the water meter will automatically close the valve, cut off the water source, and remind the user to purchase water.
(2) Overdraft function: When the remaining water volume is used to set the overdraft amount, the water meter will automatically close the valve and cut off the water source; at this time, the water meter valve can be opened only when the “user card†is recharged to purchase water.
(3) Automatic protection function: When the water meter encounters magnetic interference, the water meter will automatically close the valve; at the same time, the water meter records various interference statuses. The water meter is equipped with a tamper-proof device that will enter a locked state when it encounters self-assembly and disassembly.
(4) Battery undervoltage prompt function: When the battery is low, the controller will automatically close the valve, cut off the water source to remind the user to replace the battery; at the same time, the remaining water volume and the actual water consumption record data will be locked, after replacing the new battery, The original water information data remains unchanged.
(5) The accumulated water consumption, the monthly water consumption and the available water volume can be provided at any time. In order to facilitate the user to grasp the water situation in time, you can insert the “user card†at any time to view the “cumulative usageâ€, “residual amountâ€, “unit price†and “monthly usageâ€.
5 Conclusion
The intelligent IC card type water meter developed in this paper has been successfully developed and put into production. The water meter integrates the functions of prepaid, ladder water price billing, fault detection and alarm function, and has the characteristics of clear reading, accurate measurement and convenient management and control. And the water meter has the price parameter of water for the current unit price, the ladder water price, etc.) and the accurate real-time clock commission for the time rate of the multi-rate calculation. More importantly, the recharge is based on the amount of the recharge, instead of According to the amount of water to fill, it avoids the trouble of mutual conversion and change when recharging, effectively improving the modernization level of household water metering and charging management, and has achieved good results in practical applications.
ZGAR FILTER TIP
ZGAR electronic cigarette uses high-tech R&D, food grade disposable pod device and high-quality raw material. All package designs are Original IP. Our designer team is from Hong Kong. We have very high requirements for product quality, flavors taste and packaging design. The E-liquid is imported, materials are food grade, and assembly plant is medical-grade dust-free workshops.
Our products include disposable e-cigarettes, rechargeable e-cigarettes, rechargreable disposable vape pen, and various of flavors of cigarette cartridges. From 600puffs to 5000puffs, ZGAR bar Disposable offer high-tech R&D, E-cigarette improves battery capacity, We offer various of flavors and support customization. And printing designs can be customized. We have our own professional team and competitive quotations for any OEM or ODM works.
We supply OEM rechargeable disposable vape pen,OEM disposable electronic cigarette,ODM disposable vape pen,ODM disposable electronic cigarette,OEM/ODM vape pen e-cigarette,OEM/ODM atomizer device.
Vape Filter Tip,Disposable Pod Vape,Disposable Vape Pen,Disposable E-Cigarette,Electronic Cigarette,OEM vape pen,OEM electronic cigarette.
ZGAR INTERNATIONAL(HK)CO., LIMITED , https://www.zgarpods.com