Design of contactless smart card access control system
this paper mainly summarizes the development process of the design of RF card access control system based on tcp/ip protocol, and the main results are reflected in the following aspects:
(1) this paper discusses the design principle of RF card access control system based on tcp/ip protocol, and puts forward the overall design scheme
(2) solve the problem of embedded tcp/ip protocol single chip microcomputer network data transmission. Compared with the old system of data transmission through RS485 format signal, this system has higher data transmission rate and more nodes, which is more convenient for managers to manage
(3) further research on RF card reading and writing technology. In addition, the system also needs to further control the servo electromechanical rotation through the speed regulation system. The perfect function has integrated a variety of identification technologies. It is to integrate magnetic stripe code verification technology and fingerprint identification technology into this system, so that users can choose different access control subsystems according to their needs, such as fingerprint access control system and magnetic stripe access control system
1 overall design scheme of the system
the main chips selected by the system include AT89C55 single chip microcomputer, RTL8019AS card chip and fm1702n card reading chip. Modular design is adopted, mainly including processor, card reading module, LCD module, card module, keyboard module and electronic lock. The main technologies involved are radio frequency identification technology and Ethernet communication technology based on tcp/ip protocol
2 system hardware design scheme
this system mainly studies and designs a contactless IC card intelligent access control system based on tcp/ip protocol transmission. Through tcp/ip protocol to achieve the transmission of data between access control and remote management host, combined with the rapid development of radio frequency identification technology since the 1990s, to complete the management of modern network access control system. Figure 2 shows the hardware connection block diagram of 51 single chip microcomputer control card chip to realize Ethernet communication. The main chips used are AT89C55, RTL8019AS, 74ls373, 62256 (32K SRAM). Fm1702n is a special chip for contactless card reader designed by Fudan Electronics Co., Ltd. based on iso14443 standard, which adopts 0 6-micron CMOS EEPROM process supports iso14443 typea contactless communication protocol and Mifare standard encryption algorithm. Analog modulation and demodulation circuits are highly integrated in the chip, which can work with a minimum of peripheral circuits. It supports SPI interface, and digital circuits have TTL and CMOS voltage working modes. It is especially suitable for the application of card readers in various billing systems
TCP protocol uses the unreliable communication services provided by network layer IP protocol to solve the problem of packet retransmission and sequencing, and provides reliable, connection oriented byte stream based services for application processes. When the application uses TCP for communication, a virtual connection will be established between the source and the target, and the two computers will exchange data as a two-way byte stream in the virtual connection. TCP not only maintains the status and status information of each user data flow into and out of the TCP module of the transport layer, but also is responsible for the transmission of data through one or more networks to the user application port receiving the data. Each TCP transmission byte has a sequence number. The receiving TCP module uses a checksum routine to check whether it is damaged. If the check is correct, an ACK will be given. Otherwise, the datagram will be discarded and the serial number will be used to notify the sending TCP module of relevant problems. TCP is the key of protocol stack. However, in systems such as microcontrollers, resources are very limited, and it is impossible and unnecessary to implement all the contents of the protocol. The protocol can be appropriately simplified to save hardware costs and improve data throughput. After implementing TCP protocol, we can complete the implementation of HTTP in web server on this basis. Tcp/ip network module is mainly composed of MCS-51 single chip microcomputer and local interface chip
3 system software design
card reader software programming adopts standard C language program to realize a series of operations on Contactless IC card, mainly including AT89C55 MCU initialization, fm1702n card reading chip initialization, anti-collision program, card reading and writing program, and card block (data block) operation. The design idea of the card reading program is that after power on initialization, once the RF interface detects that Mifare 1 card enters the effective range of the RF antenna, the card reading program starts the anti-collision program and the authentication program in sequence. The zigzag stress corrosion tester can also carry out the zigzag stress corrosion fatigue experiment according to the requirements of the customer. After the verification is successful, finally operate the card reading and writing program. The software design flow chart is shown in Figure 4. Rtl8o19as card chip has two working modes, namely interrupt mode and query mode. The query method is adopted here. It mainly includes the initialization of main function, timer 1, card, ARP, TCP, HTTP, and finally the task cycle of main function
4 comprehensive debugging of software and hardware
4.1 hardware debugging
the most serious error in the process of hardware debugging is the error of address allocation. Due to insufficient consideration, the system cannot work normally. After reallocation, this problem is solved
4.2 software debugging
in the process of software debugging, the debugging of LCD, keyboard and card reader programs is relatively smooth. The debugging of card program is mainly the sending and receiving of UDP packets. The process is as follows:
first, the card chip is connected to the upper computer through twisted pair cable, then the local IP address and the upper computer IP address are set through the keyboard, and then the same setting is made through the upper computer software. Finally, activate the server, input the communication content, and press the send key to communicate. After receiving the UDP packet from the upper computer, the single chip microcomputer sends it back as it is. If the communication is normal, it will be 3 in the chat record window between us and the general public of Hong Kong The content just sent will appear if there is contact between the toothed bar pressing plate and the toothed bar. Otherwise, there is a communication problem and the program needs to be modified. The upper computer software diagram is shown in Figure 5. The debugging of this part takes a long time, and various problems can be solved only after repeated modifications. Finally, the modules that have been successfully debugged are connected in sequence, and finally all the requirements of the system are realized
5 practical application of the system
intelligent access control system has been widely used in schools, factories, office buildings, property communities, stores, financial systems, telecommunications systems, military systems and other occasions, greatly improving work efficiency and ensuring system security. The contactless IC card intelligent access control system is a modern and fully functional access control system. It can not only be used as an entrance and exit management, but also contribute to the orderly internal management and improve the overall image of the enterprise. The system can clearly limit the authority of personnel, and can greatly save human resources while improving security. Intelligent, safe and efficient access control system management has become an inevitable trend of social development. (end)
LINK
Copyright © 2011 JIN SHI