Abstract: Along with do two generation of ID card’s widespread uses, how cause two generation of ID card microreaders and each kind of platform related application joint operation question are getting more and more prominent. This article studied has designed one kind of intelligent gathering, has realized two generation of ID card information platform irrelevant intelligence read, might with the bank, the telecommunication and so on existing application realize not meets the connection, the project practice indicated that this plan was practical and feasible.
Key word: Two generation of cards; Intelligent gathering; Monolithic integrated circuit;
0 introductions
Trades along with two generation of ID cards sends the work the advancement, our country needs to use two generation of ID card’s domains to be getting more and more widespread. Because two generation of personal documents are the radio frequency smart cards, may read the status information through two generation of ID card microreaders, this has provided the condition for the enhancement working efficiency and the input information’s accuracy, but two generation of card microreaders in profession promotion uses and so on bank, telecommunication, postal service still had the very big barrier. This is because these profession’s service terminal uses the non-windows operating system’s terminal generally, but two generation of card microreader Manufacturer provides is only windows under system’s SDK development package, causes the user to be unable in these professions to carry on the re-development. Even if is the windows system, some professions did not hope because of uses two generation of card microreaders to modify oneself software system. Based on such situation, we designed have developed two generation of ID card intelligence gathering, might effective addressing this question. Two generation of ID card intelligence gathering is coordinates the second generation of resident identification card microreader in domain application and so on bank, telecommunication, postal service second generation of resident identification card information to input the tool automatically, two generation of ID card intelligence gathering may realize, in does not change profession application equipment, in software’s and so on bank, telecommunication, postal service situation, realizes to the second generation of resident identification card information automatic input, eliminates the manual input mistake, reduces the work load, raises the efficiency.
1st, design proposal analysis
1.1 hardware designs
Intelligent gathering system logic diagram as shown in Figure 1.

Figure 1 intelligent gathering system logic diagram
Hardware architecture schematic diagram as shown in Figure 2

Figure 2, intelligent gathering hardware architecture schematic diagram
Intelligent gathering master control MCU is STC89C516RD [1], this monolithic integrated circuit is the new generation ultra strong antijamming which the great crystal science and technology company promotes, high speed, low power loss MCU, its instruction-code completely compatible tradition 8051 monolithic integrated circuits, its crystal oscillator is 11.0592MHz, the serial interface level switch chip was ADM202, analog switch CD4066 has realized the special-purpose keyboard and standard keyboard’s time sharing multiplying, the power source directly from main engine’s PS/2 mouth power supply, the buzzer and the indicating lamp controls by CPU.
1.2 software designs
Intelligent gathering software work flow as shown in Figure 3:
|
Figure 3 procedure work schematic diagram |
The system requests the second generation of ID card microreader through the RS-232 correspondence connection routing directive, the read-out credential information; After process confirmation, preserves in intelligent gathering; The waiting system definition’s hot key presses down again, once has the hot key to press down, intelligent gathering the corresponding information will take out; After the processing, transmits to the PC machine PS/2 keyboard interface, in cursor twinkle place demonstration corresponding information.
This system including the system initialization (for example various registers initialization, serial port initialization, port initialization and so on), the data acquisition, the GBK code transforms, the keyboard events to process, modules and so on data transmission. Uses the software control procedure the looping execution, achieves the real-time examination and the transmitter data goal.
In the data communication aspect, has used the monolithic integrated circuit bringing USART general synchronization asynchronous receive transmitter, adopts the asynchronous working pattern, 8 bit data forms. Must therefore when the procedure start to is related the register to carry on the initialization. Simultaneously must with the ID card microreader synchronized transmission baudrate.
Because CPU uses 11.0592MHz the crystal oscillator, uses the high-speed service pattern, 2 may result in the formula according to the literature:
Must calculate baudrate = 2SMOD.Fosc/64, the establishment baudrate is 9600, Fosc should be equal to FDH.
MOVLW FDH
MOVWF SPBRG ; The establishment baudrate is 9600
The correspondence also uses polling mode [3], intelligent gathering through connects the port, unceasingly to ID card microreader transmission card polling order (forms of field orders: AA AA AA 96 69 00 03 20 01 22), when receives the response message for (AA AA AA 96 69 00 08 00 00 9F 00 00 00 00 97), then expressed that the microreader already examined the effective two belt ID card card, then carries on correlation data gathering processing. Uses MOV INDEX, the W sentence obtains the receive ID card data, uses MOV the SDA, C sentence routing directive data.
The error handling part carries on the error correction separately to the main flow and the pressed key polling part. In order to prevent the procedure to enter the endless loop, the increase mediates the electric work energy, uses in restarts the error correction to intelligent gathering.
The system uses the structurization programming plan, has the good modularity, the probability and the modifiability; The system manages and dispatches other modules through the master control flow, its master routine flow like chart 4:

Figure 4 master routine flow chart
2 key technologies analyses
2.1 Chinese character code transformation
In order to carry on the Chinese character information processing, the country has promulgated GB code GB2312 specially in 1981 - “Exchange of information Chinese character Code Character repertoire”. And has altogether collected Chinese character 6763, and determined that each Chinese character uses two bytes codes. The zone bit code and the international code these two kind of Chinese character code stipulated by GB code GB2312. Considered the GB2312 support the Chinese character are too few, 1995 Chinese character expansion standard GBK1.0 has included 21886 marks, it divides into the Chinese character area and the graphics symbol area. Chinese character area including 21003 characters. 2000 GB18030 was substitutes for GBK1.0 the official national standards. It is further expands [4] to GBK and the GB2312 code.
Because the second generation of ID card card internal storage’s Chinese character information is the GB13000 code, considered this intelligent gathering besides applies connected in terminal devices and so on bank, telecommunication, postal service, but also needs to be connected with other PC machine, regarding connects PC machine, supports GB1300 after the test present windows98 above operating system, may demonstrate directly microreader’s in Chinese character code, but the current many terminal device mainly uses the GB2312 fonts, the GBK fonts, the GB18030 fonts, this needs to be different according to the terminal support fonts, carries on suitable processing, after microreader’s in Chinese character code demonstrates on the different type terminal device. In view of this, we considered in the design the Chinese character code compatible and the user operation’s conveniences, choose in intelligent gathering use the GBK Chinese character storehouse, and establishes GB1300 and the GBK correspondence code dictionary, if the terminal device only supports the GB2312 fonts, after read microreader’s Chinese character code, through the search dictionary, transforms the GB1300 code into the corresponding zone bit code, regarding cold rare word which cannot search, then neglects automatically; If the terminal device supports GBK or GB18030, then outputs GBK to code the direct demonstration. The practice proved that this plan not only may the compatible current major part terminal device, moreover can connect PC machine on seamlessly each kind of application.
2.2 special-purpose keyboards and standard keyboard’s time sharing multiplyings
Because this procedure must realize the gathering special-purpose keyboard and the host machine standard keyboard’s time sharing multiplying, will therefore be related according to the user’s manual the plug, the plug to dock. Judges according to the procedure examination corresponding needle foot’s level height permits that data signal output, thus through the choice different input address wire, chooses the different input device, achieves the time sharing multiplying the goal.
2.3 ID card data frame form analysis
Ministry of Public Security had already stipulated strictly two generation of card’s information storage form as shown in Table 1:
Table one: Two generation of ID card data format
|
Field name |
Name |
Sex |
Nationality |
Family background date |
Family address |
ID card number |
Sends the card institution |
Term of validity |
Supplement information |
Picture information |
|
Length (byte) |
30 |
2 |
4 |
16 |
70 |
36 |
30 |
32 |
36 |
1024 |
|
Start address |
0000H |
001FH |
0021H |
0025H |
0035H |
007BH |
009FH |
00BDH |
00DDH |
0101H |
Intelligent gathering through the polling discovered when in two generation of card microreaders already had the status information, to connects the port to transmit AA AA the AA 96 69 00 03 30 01 32 orders, may form read corresponding data message which assigns according to above. And: The sex field present code is 1- male, 2- females, 9- other; In the family address field pays attention to `- ‘recognition; Supplement information field expression address change information, if has not changed, then this field for spatial; Regarding the picture information, intelligent gathering only will be is responsible for the coded message transmit the terminal or on PC machine according to the specific character class, will then use the SDK decipher display image which Ministry of Public Security will provide; At present can only realize the image display in the windows platform.
3rd, concluding remark
This intelligent gathering equipment support namely inserts namely uses, to use the special-purpose keyboard design, does not need to cut the input method, when profession applications and so on bank, telecommunication, postal service, does not need to make any modification to the original system’s software and hardware, then carries on the second generation of resident identification card information the automatic input operation; The easy to operate is quick. Indicated through the practical application in Chengdu Construction bank Partial Sub-branch onstage business service system: This design proposal eliminates the manual input mistake, reduces the work load, raised the working efficiency.
Reference
[1], STC enlargement mode 8051 monolithic integrated circuit Chinese guide (RC/RD series) http://www.MCU-Memory.com;
[2], Wu Qing live, the enmity sea shrapnel machine principle and application University of Electronic Science and Technology of China publishing house 1998 P82;
[3], Xu Lenian, Liu Yin principle, Liu Minghui based on M-BUS intelligent gathering design and application industry and mining automation 2006.4 P268
[4], what river water, Gao Youxing the VxWorks Chinese character’s demonstration supports the micro computer information, 2005,5: 142-144