Application of SPMC65P2404A in Smart IC Card Gas Meter

Publisher:BeaLaity0170Latest update time:2012-07-07 Source: mcu99Keywords:SPMC65P2404A Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

1 Introduction
With the development of computer technology and information technology in the world, the global information age has arrived. All countries are formulating their own development paths in the field of high technology. The Chinese government is committed to the construction of national economic informatization. The informatization application project represented by the "Golden Card Project" has accelerated our progress towards global economic integration. As a representative of the Golden Card Project, IC technology is undoubtedly the best application technology in the world today. It has transitioned from the early coin-operated type to the magnetic card type, and now to the IC card type. IC card is a smart card, also known as an integrated circuit card. It embeds an integrated circuit chip in a plastic substrate and encapsulates it in the form of a card. Its appearance is similar to that of a magnetic card covered with a magnetic stripe. The main purpose of developing IC card technology is to realize the electronicization of cash payment and deposit and exchange, reduce the circulation of cash, realize e-commerce, and realize prepayment of public utilities.
IC card gas meter is a new type of gas meter developed in the past decade. It is generally composed of a metering sensor circuit, a micro-power single-chip microcomputer, a micro-power valve, a voltage test circuit, an anti-theft gas circuit, and a flow monitoring system. Compared with the traditional membrane gas meter, it has more accurate counting function, function card transmission medium function, valve automatic processing function, illegal operation processing function, undervoltage processing function, power failure processing function, data download function, data display and sound prompt function, etc. After years of technical improvement and innovation by IC card manufacturers, IC card technology has become increasingly mature and its application has become more and more popular. IC card gas meter basically solves the problem of difficult gas fee collection. At the same time, with the progress of the times, the enhancement of residents' democratic awareness and the improvement of living standards, it is also required to change the backward door-to-door meter reading and charging problem in the past. The promotion and application of IC card technology has fundamentally solved the above problems and taken into account the interests of enterprises and users. For gas companies: first, it solves the problem of difficult door-to-door meter reading; second, it solves the problem of difficult collection of fees; third, it solves the dispute between enterprises and users. For users: first, it eliminates the disturbance of meter readers and time appointment problems; second, it is free to use gas; third, it eliminates the constraints and restrictions of local charging methods. It not only facilitates users, but also reduces the burden and many problems of enterprises, simplifies the operation procedures, promotes social development, improves the quality of life of the people, and reduces the economic costs of enterprises. IC card gas meter is the future development direction.

2 Basic structure of IC card gas meter

Click to browse products in a new window

System composition diagram

The block diagram of the smart IC card gas meter is shown in Figure 2, which consists of a power supply circuit, an IC card reading and writing part, a single-chip microcomputer control part, a valve control and display part, a battery voltage and position detection circuit, etc. [page]

Click to browse products in a new window
Figure 2 IC card gas meter composition block diagram


3.1 IC card reading and writing part
When the user inserts the IC card containing the gas purchase volume (expressed in encrypted numerical form) into the meter, the control valve opens the gas path under the control of the electronic control system. Every time the user uses a metering unit, the metering circuit will send a set of equal-period metering pulse sequences. If the pulse sequence is determined to be valid by the electronic control system, one metering unit can be subtracted from the purchased gas volume, and the remaining gas volume in the meter can be displayed through the LCD module. When the remaining gas volume is zero, the control valve automatically closes and the gas path is cut off. At this time, the user must re-purchase gas with the card. Under normal circumstances, the control valve is in the on state. Only when a special event occurs will the control valve change from the on state to the off state. The information read back from the IC card is then stored in the EEPROM memory. The EEPROM memory I2C uses the 24C01 chip, which can reliably store important data in the system for a long time without power supply, and the working life can reach 106 times. When the user card is inserted into the system, the key data such as the card password, card number, gas purchase volume and user gas usage record will be stored in the 24C01 chip in ciphertext.
3.2 Battery voltage detection, battery box position detection part
When the voltage of the power supply battery in the battery box is lower than the normal working voltage, the system will automatically prompt the user to replace the battery, and inform the user through the display circuit and the alarm circuit; in order to effectively protect the system power supply, this circuit can detect the battery box position with high sensitivity. When the battery box is pulled open, the protection circuit outputs a low level, and the single-chip microcomputer monitors the signal and controls the valve to shut it off. Only when the battery is installed and the battery box is pushed into the normal position in the meter, the single-chip microcomputer will control the valve again to reopen the valve to supply gas.
3.3 LCD display and sound and light alarm circuit The
LCD display circuit can display five information states of undervoltage, gas purchase, valve closing, card error and gas volume and any combination thereof. The alarm circuit
uses LED and buzzer for alarm, and the single-chip microcomputer controls the sound and light alarm.
4 Chip Features
SPMC65P2404A is an 8-bit industrial control microcontroller launched by Sunplus. It has a maximum operating frequency of 8MHz, an operating voltage of 2.5V~5V, 192 bytes of RAM and 4K bytes of OTP ROM, 23 programmable IO ports, built-in pull-up/down resistors, and 8-channel 10-bit A/D converter (100KHz). Other features of SPMC65P2404 include:
◆ Sunplus Technology 8-bit microcontroller
☉ 182 instructions
☉ 11 addressing modes
☉ Support bit operations (Set, Clear, Inverse, Test)
◆ 2 8-bit programmable timer/counters (the initial count value can be automatically preset)
☉ Ordinary timer/counter
☉ With 8-bit capture function
☉ With 8-bit comparison function
◆ 2 16-bit programmable timer/counters (the initial count value can be automatically preset)
☉Ordinary timer/counter
☉With 8 or 16-bit capture function
☉With 16-bit comparison function
☉12-bit PWM output
◆Interrupt mode
☉Support IRQ and NMI interrupts
☉4 external interrupts
☉11 internal interrupts
◆5 reset functions: power-on reset, low voltage reset, watchdog reset, external reset and wrong address reset
◆Support 3 clock circuits: crystal oscillator, RC oscillation, external clock signal
◆2 low power modes: Halt mode and Stop mode
◆Low voltage monitoring (LVD) function
◆A buzzer drive output port
◆With SPI bus
Using these resources, the function of smart IC card gas meter can be realized. [page]

5 Software
The software design is closely integrated with the control mode of the smart IC card gas meter, fully reflecting the functions of reading and writing IC card information, card type judgment, metering signal judgment and data processing, voltage monitoring and power protection, and has been carefully designed in terms of IC and signal security, software operation reliability and anti-interference. The main program block diagram of the system is shown in Figure 4.

Click to browse products in a new window


6 Conclusion
With the continuous development of science and technology, the smart IC card gas meter uses IC card to realize prepayment, which can ensure the consumption mode of "pay first and use gas later". This product is based on the optimization design idea of ​​mechatronics, with unique concept, reliable control, high detection signal resolution, accurate measurement, convenient installation and simple operation. The market prospect of this smart IC card gas meter will be very good.
7 References
[1] Cai Chunjie, Xing Wu. PIC16/17 single chip microcomputer principle and application. Hefei University of Science and Technology of China Press, 1997
[2] He Limin. I2C bus application system design. Beijing: Beijing University of Aeronautics and Astronautics Press, 1995
[3] Wang Aiying. Smart card technology. Beijing: Tsinghua University Press, 1996

Keywords:SPMC65P2404A Reference address:Application of SPMC65P2404A in Smart IC Card Gas Meter

Previous article:Application of SPMC65P2404A in electric treadmill
Next article:Design and implementation of electronic multifunctional watt-hour meter

Recommended ReadingLatest update time:2024-11-16 20:43

Design solution for smart rice cooker
1 Introduction At present, most of the rice cookers on the market use mechanical or fixed power heating, with low energy utilization and single function, which is difficult to meet people's growing living needs. Therefore, it is very necessary to develop a fully functional, safe and reliable microcomputer rice cooker.
[Microcontroller]
Design solution for smart rice cooker
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

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号