The method and the device of English display information intercepting in real time and translator of Chinese
Technical field
The present invention relates to the English display information on the import equipment is intercepted method and device with translator of Chinese in real time.
Background technology
Man-machine display interface on the import equipment of domestic a large amount of uses at present, content displayed is generally English.And the use operating personnel of equipment; be generally the workman or the training tradesman that have only basic operating technical ability; to the deciphering of original English information with understand and make a mistake, can't effectively be provided with and operate the equipment that shows english information, perhaps every function of application apparatus fully through regular meeting.How the translator of English that shows on the man-machine display interface is Chinese,, becomes the difficult problem of a lot of foreign equipment manufacturers and importer so that better use at home.
In Chinesizing to the import equipment that has the liquid crystal display interface, at present the method that adopts mainly be by equipment manufacturers directly with Chinese message composition in source code, need the modification and the debugging of source code level, gigantic project but also need equipment manufacturers to entrust to understand the staffing of Chinese generally has only the equipment manufacturers of special main attack continental market just so to do.And the third party personnel must have because the instrument of software source code and modification source code can't obtain software source code or not revise under the situation of source code instrument if want to Chinesize, and then can't carry out translation.
The content of invention
Above-mentioned deficiency at existing Chinesizing method, the applicant improves through research, the method of intercepting in real time of a kind of English display information and translator of Chinese is provided, need not to change the original function and the source code of apparatus control system, can english information be intercepted and replace with Chinese in the final link that shows shows, realize easyly, the applicant provides the device of realizing this method simultaneously.
Technical scheme of the present invention is as follows:
The method of intercepting in real time of a kind of English display information and translator of Chinese adopts single-chip microcomputer intercepting English character display frame information, and the match information by inner pre-stored, mates fast and replaces, and translates the Chinese information of correspondence.
Concrete steps are as follows:
(1) cancels the former English character LCD MODULE that is connected with the liquid crystal display output interface of apparatus control system;
(2) display message that the liquid crystal display output interface of apparatus control system is exported cushions back input single-chip microcomputer, catches the English character display frame immediately by single-chip microcomputer;
(3) after single-chip microcomputer captured complete English character display frame data, the English template of storing in the information database with english information and single-chip microcomputer inside was carried out text matches, and the pairing Chinese template of English template of taking out and matching; Numerical value that is comprised in the english information and English-word variable are then defined by wild symbol in template;
(4) the Chinese template of taking out is carried out post-production, numerical value directly replaces wild symbol, and English-word replaces wild symbol after then being matched to corresponding Chinese, obtains complete Chinese information;
(5) the Chinese information that will process is presented on the graphic lcd module according to dot matrix font.
Its further technical scheme is: described variable by wild symbol definition comprises that time, pressure, temperature etc. change numerical value, and the English-word that changes such as time, unit, pattern.
The present invention also provides the device of intercepting in real time of a kind of English display information and translator of Chinese, comprise the signal damping module, single-chip microcomputer and the graphic lcd module that are linked in sequence, the input interface of described signal damping module is connected with the liquid crystal display output interface of existing equipment control system.
Its further technical scheme is: be connected with an original text/Chinese selector switch on the described single-chip microcomputer.
Useful technique effect of the present invention is:
The present invention can be Chinese with the english information real time translation of equipment and show.Under the situation of other parts except that liquid-crystal display section that do not change the original equipment control system, the module that only contains single-chip microcomputer and graphic lcd module by use, replace former English character module, the final link that is showing, with english information intercepting and replacement, the real-time demonstration of the Chinese information after realizing translating.Following advantage is arranged specifically:
(1) directly former English display information is caught processing, avoided the existing equipment control system is developed Chinese interface again.For the exploitation amount of the Chinese source code level that shows of import barrier system, a large amount of cost of development have been saved.
(2) parts of Gai Donging are few, except replacing former English character Liquid Crystal Module, do not change other any circuits in the apparatus control system, do not influence every function of original equipment control system fully, realize that cost is also cheaper.
(3) whole English display frame capture finishing that final Chinese shows, overall process finishes in the computing in the dozens of millisecond of several milliseconds, operating personnel are when button input or information frame switching, can not feel fully has the phenomenon of display delay.
(4) translate into Chinese and show after, the friendly of operation and the property understood improve greatly, equipment damage and the product loss that can avoid operating personnel's maloperation to bring.
Description of drawings
Fig. 1 is the structured flowchart of apparatus of the present invention.
Embodiment
Below in conjunction with accompanying drawing, the present invention is specifically described by embodiment.
The inventive method is to adopt single-chip microcomputer intercepting English character display frame information, and the match information by inner pre-stored, mates fast and replaces, and translates the Chinese information of correspondence.Concrete steps are as follows:
(1) cancels the former English character LCD MODULE that is connected with the liquid crystal display output interface of apparatus control system; (2) display message that the liquid crystal display output interface of apparatus control system is exported cushions back input single-chip microcomputer, catches the English character display frame immediately by single-chip microcomputer; (3) after single-chip microcomputer captured complete English character display frame data, the English template of storing in the information database with english information and single-chip microcomputer inside was carried out text matches, and the pairing Chinese template of English template of taking out and matching; The time that is comprised in the english information, pressure, temperature etc. change numerical value, and the variablees such as English-word that change such as time, unit, pattern, are then defined by wild symbol in template; (4) the Chinese template of taking out is carried out post-production, numerical value directly replaces wild symbol, and English-word replaces wild symbol after then being matched to corresponding Chinese, obtains complete Chinese information; (5) the Chinese information that will process is presented on the graphic lcd module according to dot matrix font.
Give one example below, describe the process that character information is caught and translated in detail:
A) apparatus control system sends following display message and arrives former English character LCD:
“TODAY?IS?SUN?12:23AM”
“18?JUN?09”
B) this information by single-chip microcomputer captured in real time of the present invention after, when mating, match following English template in the database and corresponding Chinese template in inside:
" TODAY IS $$$ ##:##$$ " → " Shi $$$$$$ ##:##$$$$ today "
" ## $$ $## " → " ## " $$$$ 20## "
C) all digital symbol under unified controls " # " are directly replaced according to current information, form following Chinese character string:
" Shi $$$$$$ 12:23 $$$$ today "
" 18 Ri $$$$ 2009 "
D) three groups of character asterisk wildcards " $ " are according to current information " SUN ", and once more by database matching, inquire Chinese information: " Sun. ", " morning ", " 06 month " finally replaces with following information respectively for " AM ", " JUN ":
" today be Sun. 12:23 the morning "
" 06 month 2009 on the 18th "
Fig. 1 shows the device of real-time intercepting of the English display information that realizes said method and translator of Chinese.It comprises signal damping module BUF, single-chip microcomputer SOC and the graphic lcd modular LCD 2 that is linked in sequence.Existing equipment control system CON is for need not to change part, and the input interface of described signal damping module BUF is connected with the liquid crystal display output interface of existing equipment control system CON.As shown in Figure 1, former English character LCD MODULE LCD disconnects with the liquid crystal display output interface of existing equipment control system CON, is the parts that are replaced.Be connected with an original text/Chinese selector switch K on the single-chip microcomputer SOC, the demonstration that is used for original text and Chinese is switched.The two ends of original text/Chinese selector switch K directly are connected with input end and the output terminal of single-chip microcomputer SOC respectively.When original text/Chinese selector switch K disconnects, carry out translator of Chinese by single-chip microcomputer SOC; When original text/when Chinese selector switch K closes, be equivalent to the short circuit with single-chip microcomputer SOC, switch to the original text show state this moment, and all information are intact to be shown, and without translation and processing, is convenient to obtain former English display information, is used for debugging and translation error correction.In addition, also have backlight control between single-chip microcomputer SOC and the graphic lcd modular LCD 2, connecting lines such as contrast control, its connected mode is according to prior art.
Above-mentioned signal damping module BUF, single-chip microcomputer SOC and graphic lcd modular LCD 2 are the commercial goods, and its connected mode and the course of work all adopt prior art.
The present invention not only can be Chinese with English character liquid crystal information real time translation, programming by the inner matching database of single-chip microcomputer, also can realize (because the acquisition mode of the present invention restriction of other character mode lcd literal, only limit to character mode lcd, and East Asia literal such as inapplicable graphic lcd modular type literal such as Chinese Japanese Korean) to the translation demonstration of other character type literal or dot pattern type literal arbitrarily.
Above-described only is preferred implementation of the present invention, the invention is not restricted to above embodiment.Be appreciated that those skilled in the art under the prerequisite that does not break away from spirit of the present invention and design, can make other improvement and variation.