CN104899542A - Image-type CMOS barcode rapid recognition method and apparatus - Google Patents

Image-type CMOS barcode rapid recognition method and apparatus Download PDF

Info

Publication number
CN104899542A
CN104899542A CN201510279823.7A CN201510279823A CN104899542A CN 104899542 A CN104899542 A CN 104899542A CN 201510279823 A CN201510279823 A CN 201510279823A CN 104899542 A CN104899542 A CN 104899542A
Authority
CN
China
Prior art keywords
image
bar code
way
decoding
interface
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201510279823.7A
Other languages
Chinese (zh)
Other versions
CN104899542B (en
Inventor
李飞龙
谢楠
谢世伟
王永锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
GUANGZHOU WINSON INFORMATION TECHNOLOGY Co Ltd
Original Assignee
GUANGZHOU WINSON INFORMATION TECHNOLOGY Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by GUANGZHOU WINSON INFORMATION TECHNOLOGY Co Ltd filed Critical GUANGZHOU WINSON INFORMATION TECHNOLOGY Co Ltd
Priority to CN201510279823.7A priority Critical patent/CN104899542B/en
Publication of CN104899542A publication Critical patent/CN104899542A/en
Application granted granted Critical
Publication of CN104899542B publication Critical patent/CN104899542B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The present invention discloses an image-type CMOS barcode rapid recognition method and an image-type CMOS barcode rapid recognition apparatus. The method comprises: starting an image-type CMOS imaging system to acquire images and respectively caching the images into a first data buffer zone and a second data buffer zone; carrying out binarization processing on the images cached in the second data buffer zone according to a current binarization algorithm; carrying out barcode decoding on the images subjected to binarization processing, judging whether decoding is successfully carried out, and if yes, carrying out parameter preprocessing; othereise, executing the next step; judging whether all types of binarization algorithms are switched and if yes, returning to the last step; otherwise, switching to a next type of binarization algorithm and returning to the last step; and selecting a corresponding interface output mode according to an interface type parameter value and outputting a barcode, which is automatically and successfully identified, by a corresponding interface. Implementation of the image-type CMOS barcode rapid recognition method and apparatus which are disclosed by the present invention has the following beneficial effects that: read data bits can be greatly improved; reading can be carried out in a range of 360 degrees; and readability is improved.

Description

A kind of image-type CMOS bar code method for quickly identifying and device
Technical field
The present invention relates to bar-code identification field, particularly a kind of image-type CMOS bar code method for quickly identifying and device.
Background technology
The applied environment current according to bar code and information quantity requirement are in bar code recognition field, more and more higher to the requirement of the reader identified.Require that reader can read one-dimensional bar code, can two-dimensional bar code be read again; Require that data bit up to more than 500 bar codes, and can read by 360 degree of omnibearing angels; And conventional laser reader, CCD reader can only read 100 within bar code (generally within 48); Can only forward to reading, can not 360 degree of readings.In addition, conventional laser reader, CCD reader can not be identified in containing light absorbent is the bar code that medium makes background.Tradition image-type CMOS two-dimensional scanner only supports that serial ports TTL/RS232 exports, and does not support to switch output containing USB HID keyboard, USB-VCP (CDC), RS485.Tradition image-type CMOS two-dimensional scanner does not support image in 2 D code export function.One-dimensional bar code decoding lacks translation-angle decoding, affects recognition rate and decoding speed.Picture pre-service Binarization methods lacks many algorithms and switches, and affects recognition rate.
Summary of the invention
The technical problem to be solved in the present invention is, data bit for the above-mentioned reading of prior art is less, can not 360 degree of readings, affect the defect of recognition rate, provide a kind of greatly can improve reading data bit, can 360 degree readings, the image-type CMOS bar code method for quickly identifying of raising recognition rate and devices.
The technical solution adopted for the present invention to solve the technical problems is: construct a kind of image-type CMOS bar code method for quickly identifying, be applied to Processing in Barcode Recognizing System, described Processing in Barcode Recognizing System comprises image-type cmos imaging system, and described recognition methods comprises the steps:
A) start scan function, and start described image-type cmos imaging system;
B) described image-type cmos imaging system obtains image, and is buffered in respectively by the image of acquisition in the first data buffer and the second data buffer;
C) image binaryzation process is carried out by being buffered in the Binarization methods of the image in described second data buffer according to current type;
D) one-dimensional bar code decoding is carried out to the image after binary conversion treatment, and judge whether successfully decoded, in this way, perform step G); Otherwise, perform step e);
E) decoding two-dimensional bar code is carried out to described image after binary conversion treatment, and judge whether successfully decoded, in this way, perform step G); Otherwise, perform step F);
F) judge whether all types of Binarization methods of specifying in advance all switched, and in this way, returned step B); Otherwise, be switched to the Binarization methods of next type, and return step C);
G) parameter pre-service is carried out; Described parameter pre-service comprises output interface type conversion and decoded data format conversion;
H) select the corresponding interface way of output according to the size of current interface type parameter value, and exported the bar code being automatically identified as merit by corresponding interface.
In image-type CMOS bar code method for quickly identifying of the present invention, also comprise the steps:
I) judge whether serial ports receives the instruction of deriving original image, in this way, exports the image information in described first data buffer; Otherwise, proceed the judgement of this step.
In image-type CMOS bar code method for quickly identifying of the present invention, described step D) comprise further:
D1) be 0 to anglec of rotation assignment;
D2) size of the image after binary conversion treatment according to the described anglec of rotation is rotated;
D3) carry out repeating query decoding according to one-dimensional bar code coding schedule, and judge that whether decoding is successful, in this way, perform step G); Otherwise, perform step D4);
D4) after the described anglec of rotation being added an angle setpoint, judge whether its size is greater than 180 degree, in this way, perform step e); Otherwise, return step D2).
In image-type CMOS bar code method for quickly identifying of the present invention, described all types of Binarization methods of specifying in advance comprise median filtering algorithm, large law and local algorithm.
In image-type CMOS bar code method for quickly identifying of the present invention, when being switched to local algorithm, described local algorithm comprises the steps:
C1 ') from the second data buffer, obtain the pixel of image;
C2 ') carry out assignment to respectively radius reference value and correction factor;
C3 ') pixel average and the standard deviation square value of described pixel is calculated respectively according to the square value size of radius reference value;
C4 ') described correction factor is multiplied with standard deviation square value, and the product obtained and described pixel average are carried out being added obtaining binary value;
C5 ') one-dimensional bar code or decoding two-dimensional bar code are carried out to the image after binary conversion treatment, and whether successful, in this way, perform step G if sentencing decoding); Otherwise, perform step C6 ');
C6 ') convert the size of described radius reference value, and judge whether the size of the radius reference value after converting is greater than radius setting value, in this way, perform step G); Otherwise, return step C2 ').
In image-type CMOS bar code method for quickly identifying of the present invention, described step H) comprise further:
H1) judge whether interface parameters equals the first setting value, in this way, select TTL interface or the RS232 interface way of output, and use described TTL interface or RS232 interface to export the bar code being automatically identified as merit; Otherwise, perform step H2);
H2) judge whether described interface parameters equals the second setting value, in this way, select the USB HID keyboard way of output, and use described USB HID keyboard to export the bar code being automatically identified as merit; Otherwise, perform step H3);
H3) judge whether described interface parameters equals the 3rd setting value, in this way, select the USB virtual serial port way of output, and use described USB virtual serial port to export the bar code being automatically identified as merit; Otherwise, perform step H4);
H4) judge whether described interface parameters equals the 4th setting value, in this way, select the RS485 interface way of output, and use described RS485 interface to export the bar code being automatically identified as merit; Otherwise, prompting warning message.
The invention still further relates to a kind of device realizing above-mentioned image-type CMOS bar code method for quickly identifying, be applied to Processing in Barcode Recognizing System, described Processing in Barcode Recognizing System comprises image-type cmos imaging system, and described device comprises:
Start unit: for starting scan function, and start described image-type cmos imaging system;
Image Acquisition buffer unit: for making described image-type cmos imaging system obtain image, and the image of acquisition is buffered in respectively in the first data buffer and the second data buffer;
Binary conversion treatment unit: for carrying out image binaryzation process by being buffered in the Binarization methods of the image in described second data buffer according to current type;
One-dimensional bar code decoding unit: for carrying out one-dimensional bar code decoding to the image after binary conversion treatment, and judge whether successfully decoded;
Decoding two-dimensional bar code unit: for carrying out decoding two-dimensional bar code to described image after binary conversion treatment, and judge whether successfully decoded;
Switching judging unit: for judging whether all types of Binarization methods of specifying in advance all switched, and in this way, returned; Otherwise, be switched to the Binarization methods of next type;
Parameter pretreatment unit: for carrying out parameter pre-service; Described parameter pre-service comprises output interface type conversion and decoded data format conversion;
Bar code output unit: for selecting the corresponding interface way of output according to the size of current interface type parameter value, and the bar code being automatically identified as merit is exported by corresponding interface.
In device of the present invention, also comprise:
Command reception judging unit: for judging whether serial ports receives the instruction of deriving original image, in this way, exports the image information in described first data buffer; Otherwise, proceed to judge.
In device of the present invention, described one-dimensional bar code decoding unit comprises further:
Assignment module: for being 0 to anglec of rotation assignment;
Image rotation module: for the size of the image after binary conversion treatment according to the described anglec of rotation is rotated;
Repeating query decoder module: for carrying out repeating query decoding according to one-dimensional bar code coding schedule, and judge that whether decoding is successful;
Anglec of rotation size judge module: after the described anglec of rotation is added an angle setpoint, judges whether its size is greater than 180 degree.
In device of the present invention, described all types of Binarization methods of specifying in advance comprise median filtering algorithm, large law and local algorithm.
Implement image-type CMOS bar code method for quickly identifying of the present invention and device, there is following beneficial effect: owing to using image-type cmos imaging system, both one-dimensional bar code was read, two-dimensional bar code can be read again, barcode data position can up to more than 500 bar codes, even 1024/2048 bar code, can read by 360 degree of omnibearing angels, can switch in the Binarization methods of multiple types of specifying in advance; So its can greatly improve reading data bit, can 360 degree readings, raising recognition rate.
Accompanying drawing explanation
In order to be illustrated more clearly in the embodiment of the present invention or technical scheme of the prior art, be briefly described to the accompanying drawing used required in embodiment or description of the prior art below, apparently, accompanying drawing in the following describes is only some embodiments of the present invention, for those of ordinary skill in the art, under the prerequisite not paying creative work, other accompanying drawing can also be obtained according to these accompanying drawings.
Fig. 1 is the process flow diagram of method in image-type CMOS bar code method for quickly identifying of the present invention and device embodiment;
Fig. 2 carries out one-dimensional bar code decoding to the image after binary conversion treatment in described embodiment, and judges whether the particular flow sheet of successfully decoded;
Fig. 3 is the particular flow sheet of local algorithm in described embodiment;
Fig. 4 selects the corresponding interface way of output according to the size of current interface type parameter value in described embodiment, and is exported the particular flow sheet being automatically identified as the bar code of merit by corresponding interface;
Fig. 5 is the structural representation of device in described embodiment.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, be clearly and completely described the technical scheme in the embodiment of the present invention, obviously, described embodiment is only the present invention's part embodiment, instead of whole embodiments.Based on the embodiment in the present invention, the every other embodiment that those of ordinary skill in the art obtain under the prerequisite of not making creative work, all belongs to the scope of protection of the invention.
In image-type CMOS bar code method for quickly identifying of the present invention and device embodiment, the process flow diagram of its image-type CMOS bar code method for quickly identifying as shown in Figure 1.This image-type CMOS bar code method for quickly identifying is applied to Processing in Barcode Recognizing System, and Processing in Barcode Recognizing System comprises image-type cmos imaging system, and in Fig. 1, this image-type CMOS bar code method for quickly identifying comprises the steps:
Step S001 starts scan function, and starts image-type cmos imaging system: in this step, starts scan function, and starts image-type cmos imaging system.
Step S002 image-type cmos imaging system obtains image, and the image of acquisition is buffered in respectively in the first data buffer and the second data buffer: in this step, image-type cmos imaging system obtains image, after acquisition image completes, the image of acquisition is buffered in respectively in the first data buffer and the second data buffer, in the present embodiment, the first data buffer is labeled as buf_F [x], the second data buffer is labeled as buf_d [x].
Step S003 carries out image binaryzation process by being buffered in the Binarization methods of the image in the second data buffer according to current type: in this step, image binaryzation process is carried out by being buffered in the Binarization methods of the image in the second data buffer according to current type, about how to process, rear extended meeting is described in detail.
Step S004 carries out one-dimensional bar code decoding to the image after binary conversion treatment, and judge whether successfully decoded: it is worth mentioning that, the image that image-type cmos imaging system obtains is likely the picture of one-dimensional bar code, also may be the picture of two-dimensional bar.In this step, one-dimensional bar code decoding is carried out to the image after binary conversion treatment, and judges whether successfully decoded, if the result judged is yes, then perform step S008; Otherwise, perform step S005.
Step S005 carries out decoding two-dimensional bar code to the image after binary conversion treatment, and judges whether successfully decoded: if the judged result of above-mentioned steps S004 is no, then perform this step.In this step, decoding two-dimensional bar code is carried out to the image after binary conversion treatment, and judges whether successfully decoded, if the result judged is yes, then perform step S008; Otherwise, perform step S006.
Step S006 judges whether all types of Binarization methods of specifying in advance all switched: if the judged result of above-mentioned steps S005 is no, then perform this step.In the present embodiment, all types of Binarization methods of specifying in advance comprise median filtering algorithm, large law (OTSU) and local algorithm (Niblack).In this step, judge whether all types of Binarization methods of specifying in advance all switched, namely judge whether median filtering algorithm, large law and local algorithm were all switched once, if the result judged is yes, then returned step S002; Otherwise, perform step S007.
Step S007 is switched to the Binarization methods of next type: if the judged result of above-mentioned steps S006 is no, then perform this step.In this step, be switched to the Binarization methods of next type, be namely switched to a kind of algorithm be not switched in median filtering algorithm, large law and local algorithm.Execute this step, return step S003.
Step S008 carries out parameter pre-service: in this step, carries out parameter pre-service, and this parameter pre-service has a variety of, such as: output interface type conversion and decoded data format conversion etc., can specifically need to set corresponding parameter.
Step S009 selects the corresponding interface way of output according to the size of current interface type parameter value, and the bar code being automatically identified as merit is exported by corresponding interface: in this step, select the corresponding interface way of output according to the size of current interface type parameter value, and exported the bar code being automatically identified as merit by corresponding interface.
It is worth mentioning that, in the present embodiment, adopt image-type CMOS (as: MT9V0xx, OV79xx, OV76xx) as image-type cmos imaging system, this image-type cmos imaging system also comprises master cpu, master cpu is ARM, ARM selects ARM9/ARM11 series, is specially self-carried USB, CSI utilizing camera interface functional chip, such as: imx257, imx353 series etc.Owing to using image-type cmos imaging system, both read one-dimensional bar code, and can two-dimensional bar code be read again, barcode data position can up to more than 500 bar codes, even 1024/2048 bar code, can read by 360 degree of omnibearing angels, can switch in the Binarization methods of multiple types of specifying in advance; So its can greatly improve reading data bit, can 360 degree readings, raising recognition rate.Also support that containing light absorbent be the bar code that medium makes background simultaneously.
For the present embodiment, when original image derived by needs, this image-type CMOS bar code method for quickly identifying also comprises the steps:
Step S010 judges whether serial ports receives the instruction of deriving original image: after execution of step S009, perform this step.In this step, judge whether serial ports receives the instruction of deriving original image, if the result judged is yes, then perform step S011; Otherwise, proceed the judgement of this step.
Step S011 exports the image information in the first data buffer: if the judged result of above-mentioned steps S010 is yes, then perform this step.In this step, export the image information in the first data buffer.Identify after successful bar code so the present invention is supported in export, accept instruction and control to derive the original image identifying successful bar code.
For the present embodiment, above-mentioned steps S004 also can refinement further, and the process flow diagram after its refinement as shown in Figure 2.In Fig. 2, above-mentioned steps S004 comprises further:
Step S41 is 0: in this step to anglec of rotation assignment, is 0, in the present embodiment to anglec of rotation assignment, for convenience of description, the anglec of rotation is compared for angle, in this step, namely makes angle=0.
The size of image after binary conversion treatment according to the anglec of rotation rotates by step S42: in this step, the size of image after binary conversion treatment according to the anglec of rotation is rotated, namely by the image rotation angle degree after binary conversion treatment.
Step S43 carries out repeating query decoding according to one-dimensional bar code coding schedule, and judges that whether decoding is successful: in this step, carry out repeating query decoding according to one-dimensional bar code coding schedule, and judges that whether decoding is successful, if the result judged is yes, then performs step S006; Otherwise, perform step S44.
After the anglec of rotation is added an angle setpoint by step S44, judge whether its size is greater than 180 degree: if the judged result of above-mentioned steps S43 is no, then perform this step.In this step, after the anglec of rotation being added an angle setpoint, judge whether its size is greater than 180 degree, concrete, in the present embodiment, angle setpoint is 15, in this step, namely make angle=angle+15, then judge whether angle is greater than 180 degree, if the result judged is yes, then perform step S005; Otherwise, return step S42.One-dimensional bar code decoding and decoding two-dimensional bar code are carried out classification decoding by the present invention, when one-dimensional bar code decoding, by the transformation of image by the anglec of rotation being decoded, can improve recognition rate and decoding speed like this.It is worth mentioning that, under the certain situation of the present embodiment, the size of above-mentioned angle setpoint can be also other values, is specially how many, can sets flexibly according to actual conditions.
In the present embodiment, when Binarization methods is switched to local algorithm, its process flow diagram as shown in Figure 3.In Fig. 3, this local algorithm comprises the steps:
Step S31 ' obtains the pixel of image from the second data buffer: in this step, obtains the pixel of image from buf_d [x].
Step S32 ' carries out assignment to respectively radius reference value and correction factor: in this step, carries out assignment to respectively radius reference value and correction factor, for convenience of description, in the present embodiment, radius reference value and correction factor mark is designated as R and K respectively.
Step S33 ' calculates pixel average and the standard deviation square value of pixel respectively according to the square value size of radius reference value: in this step, pixel average and the standard deviation square value of pixel is calculated respectively according to the square value size of radius reference value, the pixel average of pixel is labeled as m (x, y), standard deviation square value is labeled as S (x, y), (x, y) be the coordinate of pixel, concrete, according to the size of R*R, calculate m (x respectively, y) with S (x, y).
Correction factor is multiplied with standard deviation square value by step S34 ', and the product obtained and pixel average are carried out being added obtaining binary value: in the present embodiment, binary value is labeled as T (x, y), in this step, namely T (x, y)=m (x, y)+K*S (x, y).
Step S35 ' carries out one-dimensional bar code or decoding two-dimensional bar code to the image after binary conversion treatment, and whether sentence decoding successful: in this step, one-dimensional bar code or decoding two-dimensional bar code are carried out to the image after binary conversion treatment, and whether sentence decoding successful, if the result judged is yes, then perform step S006; Otherwise, perform step S36 '.
Step S36 ' converts the size of radius reference value, and judges whether the size of the radius reference value after converting is greater than radius setting value: if the judged result of above-mentioned steps S35 ' is no, then perform this step.In the present embodiment, radius setting value is 5, in this step, the size of conversion R, and judges whether R is greater than 5, if the result judged is yes, then performs step S006; Otherwise, return step S32 '.So just achieve local algorithm.
For the present embodiment, above-mentioned steps S009 also can refinement further, and the process flow diagram after its refinement as shown in Figure 4.In Fig. 4, above-mentioned steps S009 comprises further:
Step S91 judges whether interface parameters equals the first setting value: in the present embodiment, and the size of the interface parameters of often kind of interface is all different.In this step, judge whether interface parameters equals the first setting value, if the result judged is yes, then perform step S92; Otherwise, perform step S93.In the present embodiment, interface parameters is labeled as transmit_mode.In the present embodiment, the first setting value is 0x30, and certainly, under the certain situation of the present embodiment, the size of the first setting value also can be other values, can set its size as the case may be.
Step S92 selects TTL interface or the RS232 interface way of output, and uses TTL interface or RS232 interface to export the bar code being automatically identified as merit: if the judged result of above-mentioned steps S91 is yes, then perform this step.In this step, select TTL interface or the RS232 interface way of output, and use TTL interface or RS232 interface to export the bar code being automatically identified as merit.
Step S93 judges whether interface parameters equals the second setting value: if the judged result of above-mentioned steps S91 is no, then perform this step.In this step, judge whether transmit_mode equals the second setting value, if the result judged is yes, then perform step S94; Otherwise, perform step S95.In the present embodiment, the second setting value is 0x31, and certainly, under the certain situation of the present embodiment, the size of the second setting value also can be other values, can set its size as the case may be.
Step S94 selects the USB HID keyboard way of output, and uses USB HID keyboard to export the bar code being automatically identified as merit: if the judged result of above-mentioned steps S93 is yes, then perform this step.In this step, select the USB HID keyboard way of output, and use USB HID keyboard to export the bar code being automatically identified as merit.
Step S95 judges whether interface parameters equals the 3rd setting value: if the judged result of above-mentioned steps S93 is no, then perform this step.In this step, judge whether transmit_mode equals the 3rd setting value, if the result judged is yes, then perform step S96; Otherwise, perform step S97.In the present embodiment, the 3rd setting value is 0x32, and certainly, under the certain situation of the present embodiment, the size of the 3rd setting value also can be other values, can set its size as the case may be.
Step S96 selects the USB virtual serial port way of output, and uses USB virtual serial port to export the bar code being automatically identified as merit: if the judged result of above-mentioned steps S95 is yes, then perform this step.In this step, select the USB virtual serial port way of output, and use USB virtual serial port to export the bar code being automatically identified as merit.
Step S97 judges whether interface parameters equals the 4th setting value: if the judged result of above-mentioned steps S95 is no, then perform this step.In this step, judge whether transmit_mode equals the 4th setting value, if the result judged is yes, then perform step S98; Otherwise, perform step S99.In the present embodiment, the 4th setting value is 0x34, and certainly, under the certain situation of the present embodiment, the size of the 4th setting value also can be other values, can set its size as the case may be.
Step S98 selects the RS485 interface way of output, and uses RS485 interface to export the bar code being automatically identified as merit: if the judged result of above-mentioned steps S97 is yes, then perform this step.In this step, select the RS485 interface way of output, and use RS485 interface to export the bar code being automatically identified as merit.
Step S99 points out warning message: if the judged result of above-mentioned steps S97 is no, then perform this step.In this step, prompting warning message.The present invention has powerful predeterminable process parameter and abundant output interface, can only support that serial ports TTL/RS232 exports, support to switch output containing USB HID keyboard (USB HID keyboard), USB virtual serial port (USB-VCP (CDC)), RS485 simultaneously.
The present embodiment also relates to a kind of device realizing above-mentioned image-type CMOS bar code method for quickly identifying, and its structural representation as shown in Figure 5.This application of installation is in Processing in Barcode Recognizing System, this Processing in Barcode Recognizing System comprises image-type cmos imaging system, in Fig. 5, this device comprises start unit 1, Image Acquisition buffer unit 2, binary conversion treatment unit 3, one-dimensional bar code decoding unit 4, decoding two-dimensional bar code unit 5, switching judging unit 6, parameter pretreatment unit 7 and bar code output unit 8; Wherein, start unit 1 for starting scan function, and starts image-type cmos imaging system; Image Acquisition buffer unit 2 obtains image for making image-type cmos imaging system, and is buffered in respectively by the image of acquisition in the first data buffer and the second data buffer; Binary conversion treatment unit 3 is for carrying out image binaryzation process by being buffered in the Binarization methods of the image in described second data buffer according to current type; One-dimensional bar code decoding unit 4 for carrying out one-dimensional bar code decoding to the image after binary conversion treatment, and judges whether successfully decoded; Decoding two-dimensional bar code unit 5 for carrying out decoding two-dimensional bar code to the image after binary conversion treatment, and judges whether successfully decoded; Switching judging unit 6 is for judging whether all types of Binarization methods of specifying in advance all switched, and in this way, returned; Otherwise be switched to the Binarization methods of next type, all types of Binarization methods of specifying in advance comprise median filtering algorithm, large law and local algorithm.Parameter pretreatment unit 7 is for carrying out parameter pre-service; Parameter pre-service comprises output interface type conversion and decoded data format conversion; Bar code output unit 8 for selecting the corresponding interface way of output according to the size of current interface type parameter value, and is exported the bar code being automatically identified as merit by corresponding interface.Owing to using image-type cmos imaging system, both read one-dimensional bar code, and can two-dimensional bar code be read again, barcode data position can up to more than 500 bar codes, even 1024/2048 bar code, can read by 360 degree of omnibearing angels, can switch in the Binarization methods of multiple types of specifying in advance; So its can greatly improve reading data bit, can 360 degree readings, raising recognition rate.Also support that containing light absorbent be the bar code that medium makes background simultaneously.
For the present embodiment, when original image derived by needs, this device also comprises command reception judging unit 9, and command reception judging unit 9 is for judging whether serial ports receives the instruction of deriving original image, in this way, exports the image information in the first data buffer; Otherwise, proceed to judge.After it is supported in and exports the successful bar code of identification, accept instruction and control to derive the original image identifying successful bar code.
In the present embodiment, one-dimensional bar code decoding unit 4 comprises assignment module 41, image rotation module 42, repeating query decoder module 43 and anglec of rotation size judge module 44 further; Wherein, assignment module 41 is for being 0 to anglec of rotation assignment; Image rotation module 42 is for rotating the size of the image after binary conversion treatment according to the anglec of rotation; Repeating query decoder module 43 for carrying out repeating query decoding according to one-dimensional bar code coding schedule, and judges that whether decoding is successful; Anglec of rotation size judge module 44, for after the anglec of rotation being added an angle setpoint, judges whether its size is greater than 180 degree.When one-dimensional bar code decoding, by the transformation of image by the anglec of rotation being decoded, recognition rate and decoding speed can be improved like this.
In a word, in the present embodiment, image-type CMOS is adopted to make master cpu as imaging system, ARM9/ARM11; Both read one-dimensional bar code, and can two-dimensional bar code be read again; Barcode data position can up to more than 500 bar codes, even 1024/2048 bar code; Can read by 360 degree of omnibearing angels; Support that containing light absorbent be the bar code that medium makes background; There is powerful predeterminable process parameter and abundant output interface, can only support that serial ports TTL/RS232 exports, also support to switch output containing USB HID keyboard, USB-VCP (CDC), RS485 simultaneously; Be supported in after exporting the successful bar code of identification, accept instruction and control to derive the original image identifying successful bar code; One dimension, decoding two-dimensional bar code classification decoding, when one-dimensional bar code decoding, increases image and changes decoding by the anglec of rotation, improve recognition rate and decoding speed; Increase multiple binary conversion treatment algorithm, switch and use, improve recognition rate.
The foregoing is only preferred embodiment of the present invention, not in order to limit the present invention, within the spirit and principles in the present invention all, any amendment done, equivalent replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1. an image-type CMOS bar code method for quickly identifying, is characterized in that, be applied to Processing in Barcode Recognizing System, and described Processing in Barcode Recognizing System comprises image-type cmos imaging system, and described recognition methods comprises the steps:
A) start scan function, and start described image-type cmos imaging system;
B) described image-type cmos imaging system obtains image, and is buffered in respectively by the image of acquisition in the first data buffer and the second data buffer;
C) image binaryzation process is carried out by being buffered in the Binarization methods of the image in described second data buffer according to current type;
D) one-dimensional bar code decoding is carried out to the image after binary conversion treatment, and judge whether successfully decoded, in this way, perform step G); Otherwise, perform step e);
E) decoding two-dimensional bar code is carried out to described image after binary conversion treatment, and judge whether successfully decoded, in this way, perform step G); Otherwise, perform step F);
F) judge whether all types of Binarization methods of specifying in advance all switched, and in this way, returned step B); Otherwise, be switched to the Binarization methods of next type, and return step C);
G) parameter pre-service is carried out; Described parameter pre-service comprises output interface type conversion and decoded data format conversion;
H) select the corresponding interface way of output according to the size of current interface type parameter value, and exported the bar code being automatically identified as merit by corresponding interface.
2. image-type CMOS bar code method for quickly identifying according to claim 1, is characterized in that, also comprise the steps:
I) judge whether serial ports receives the instruction of deriving original image, in this way, exports the image information in described first data buffer; Otherwise, proceed the judgement of this step.
3. image-type CMOS bar code method for quickly identifying according to claim 1 and 2, is characterized in that, described step D) comprise further:
D1) be 0 to anglec of rotation assignment;
D2) size of the image after binary conversion treatment according to the described anglec of rotation is rotated;
D3) carry out repeating query decoding according to one-dimensional bar code coding schedule, and judge that whether decoding is successful, in this way, perform step G); Otherwise, perform step D4);
D4) after the described anglec of rotation being added an angle setpoint, judge whether its size is greater than 180 degree, in this way, perform step e); Otherwise, return step D2).
4. image-type CMOS bar code method for quickly identifying according to claim 3, is characterized in that, described all types of Binarization methods of specifying in advance comprise median filtering algorithm, large law and local algorithm.
5. image-type CMOS bar code method for quickly identifying according to claim 4, it is characterized in that, when being switched to local algorithm, described local algorithm comprises the steps:
C1 ') from the second data buffer, obtain the pixel of image;
C2 ') carry out assignment to respectively radius reference value and correction factor;
C3 ') pixel average and the standard deviation square value of described pixel is calculated respectively according to the square value size of radius reference value;
C4 ') described correction factor is multiplied with standard deviation square value, and the product obtained and described pixel average are carried out being added obtaining binary value;
C5 ') one-dimensional bar code or decoding two-dimensional bar code are carried out to the image after binary conversion treatment, and whether successful, in this way, perform step G if sentencing decoding); Otherwise, perform step C6 ');
C6 ') convert the size of described radius reference value, and judge whether the size of the radius reference value after converting is greater than radius setting value, in this way, perform step G); Otherwise, return step C2 ').
6. image-type CMOS bar code method for quickly identifying according to claim 1, is characterized in that, described step H) comprise further:
H1) judge whether interface parameters equals the first setting value, in this way, select TTL interface or the RS232 interface way of output, and use described TTL interface or RS232 interface to export the bar code being automatically identified as merit; Otherwise, perform step H2);
H2) judge whether described interface parameters equals the second setting value, in this way, select the USB HID keyboard way of output, and use described USB HID keyboard to export the bar code being automatically identified as merit; Otherwise, perform step H3);
H3) judge whether described interface parameters equals the 3rd setting value, in this way, select the USB virtual serial port way of output, and use described USB virtual serial port to export the bar code being automatically identified as merit; Otherwise, perform step H4);
H4) judge whether described interface parameters equals the 4th setting value, in this way, select the RS485 interface way of output, and use described RS485 interface to export the bar code being automatically identified as merit; Otherwise, prompting warning message.
7. realize a device for image-type CMOS bar code method for quickly identifying as claimed in claim 1, it is characterized in that, be applied to Processing in Barcode Recognizing System, described Processing in Barcode Recognizing System comprises image-type cmos imaging system, and described device comprises:
Start unit: for starting scan function, and start described image-type cmos imaging system;
Image Acquisition buffer unit: for making described image-type cmos imaging system obtain image, and the image of acquisition is buffered in respectively in the first data buffer and the second data buffer;
Binary conversion treatment unit: for carrying out image binaryzation process by being buffered in the Binarization methods of the image in described second data buffer according to current type;
One-dimensional bar code decoding unit: for carrying out one-dimensional bar code decoding to the image after binary conversion treatment, and judge whether successfully decoded;
Decoding two-dimensional bar code unit: for carrying out decoding two-dimensional bar code to described image after binary conversion treatment, and judge whether successfully decoded;
Switching judging unit: for judging whether all types of Binarization methods of specifying in advance all switched, and in this way, returned; Otherwise, be switched to the Binarization methods of next type;
Parameter pretreatment unit: for carrying out parameter pre-service; Described parameter pre-service comprises output interface type conversion and decoded data format conversion;
Bar code output unit: for selecting the corresponding interface way of output according to the size of current interface type parameter value, and the bar code being automatically identified as merit is exported by corresponding interface.
8. device according to claim 7, is characterized in that, also comprises:
Command reception judging unit: for judging whether serial ports receives the instruction of deriving original image, in this way, exports the image information in described first data buffer; Otherwise, proceed to judge.
9. the device according to claim 7 or 8, is characterized in that, described one-dimensional bar code decoding unit comprises further:
Assignment module: for being 0 to anglec of rotation assignment;
Image rotation module: for the size of the image after binary conversion treatment according to the described anglec of rotation is rotated;
Repeating query decoder module: for carrying out repeating query decoding according to one-dimensional bar code coding schedule, and judge that whether decoding is successful;
Anglec of rotation size judge module: after the described anglec of rotation is added an angle setpoint, judges whether its size is greater than 180 degree.
10. device according to claim 9, is characterized in that, described all types of Binarization methods of specifying in advance comprise median filtering algorithm, large law and local algorithm.
CN201510279823.7A 2015-05-27 2015-05-27 A kind of image-type CMOS bar codes method for quickly identifying and device Active CN104899542B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510279823.7A CN104899542B (en) 2015-05-27 2015-05-27 A kind of image-type CMOS bar codes method for quickly identifying and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510279823.7A CN104899542B (en) 2015-05-27 2015-05-27 A kind of image-type CMOS bar codes method for quickly identifying and device

Publications (2)

Publication Number Publication Date
CN104899542A true CN104899542A (en) 2015-09-09
CN104899542B CN104899542B (en) 2017-06-20

Family

ID=54032200

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510279823.7A Active CN104899542B (en) 2015-05-27 2015-05-27 A kind of image-type CMOS bar codes method for quickly identifying and device

Country Status (1)

Country Link
CN (1) CN104899542B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107729792A (en) * 2017-10-23 2018-02-23 广州市韦尔讯信息科技有限公司 Image-type CMOS mobile payments method for quickly identifying and device
CN109255277A (en) * 2018-08-31 2019-01-22 阿里巴巴集团控股有限公司 A kind of two dimensional code analysis method and device
CN109376568A (en) * 2018-09-19 2019-02-22 上海商米科技有限公司 Identify the method, apparatus and system of bar code
CN110245537A (en) * 2019-05-28 2019-09-17 北京三快在线科技有限公司 Graphic code coding/decoding method, device, storage medium and electronic equipment
CN111435417A (en) * 2020-01-14 2020-07-21 珠海市杰理科技股份有限公司 Image analysis method and device for bar code scanning and storage medium
CN112287702A (en) * 2020-05-19 2021-01-29 珠海市杰理科技股份有限公司 Code scanning method and device without external memory, scanning equipment and mobile terminal
CN113111675A (en) * 2021-04-19 2021-07-13 广州讯宝电子科技有限公司 Method and system for rapidly identifying bar code based on bar code scanner

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050103861A1 (en) * 2003-11-13 2005-05-19 Metrologic Instruments, Inc. Hand-supportable digital imaging-based bar code reading system wherein, during each imaging cycle, a single frame of pixel data is automatically detected by a CMOS area-type image sensing array when substantially all rows of pixels therein are in a state of integration and have a common integration time, and then pixel data is transmitted from said CMOS area-type image sensing array into a FIFO buffer, and then mapped into memory for subsequent image processing
CN101499135A (en) * 2008-01-29 2009-08-05 茂森科技股份有限公司 Quasi-isotropic bar code scanner
CN101751591A (en) * 2010-01-14 2010-06-23 复旦大学 High-capacity two-dimensional barcode capable of recording voice message and reader
US7949155B2 (en) * 2005-03-08 2011-05-24 Fuji Xerox Co., Ltd. Image processing apparatus, image processing method, and storage medium
US20110121067A1 (en) * 1997-10-17 2011-05-26 Longacre Jr Andrew Imaging device operative for image processing
CN202584157U (en) * 2012-05-21 2012-12-05 深圳市民德电子科技有限公司 Two-dimensional bar code reading system
CN204302987U (en) * 2014-11-26 2015-04-29 戴银飞 A kind of two-dimension code recognition device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110121067A1 (en) * 1997-10-17 2011-05-26 Longacre Jr Andrew Imaging device operative for image processing
US20050103861A1 (en) * 2003-11-13 2005-05-19 Metrologic Instruments, Inc. Hand-supportable digital imaging-based bar code reading system wherein, during each imaging cycle, a single frame of pixel data is automatically detected by a CMOS area-type image sensing array when substantially all rows of pixels therein are in a state of integration and have a common integration time, and then pixel data is transmitted from said CMOS area-type image sensing array into a FIFO buffer, and then mapped into memory for subsequent image processing
US7949155B2 (en) * 2005-03-08 2011-05-24 Fuji Xerox Co., Ltd. Image processing apparatus, image processing method, and storage medium
CN101499135A (en) * 2008-01-29 2009-08-05 茂森科技股份有限公司 Quasi-isotropic bar code scanner
CN101751591A (en) * 2010-01-14 2010-06-23 复旦大学 High-capacity two-dimensional barcode capable of recording voice message and reader
CN202584157U (en) * 2012-05-21 2012-12-05 深圳市民德电子科技有限公司 Two-dimensional bar code reading system
CN204302987U (en) * 2014-11-26 2015-04-29 戴银飞 A kind of two-dimension code recognition device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
吴佳鹏: ""二维条码识读技术及其应用研究"", 《中国博士学位论文全文数据库 信息科技辑》 *

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107729792A (en) * 2017-10-23 2018-02-23 广州市韦尔讯信息科技有限公司 Image-type CMOS mobile payments method for quickly identifying and device
CN109255277A (en) * 2018-08-31 2019-01-22 阿里巴巴集团控股有限公司 A kind of two dimensional code analysis method and device
CN109376568A (en) * 2018-09-19 2019-02-22 上海商米科技有限公司 Identify the method, apparatus and system of bar code
CN110245537A (en) * 2019-05-28 2019-09-17 北京三快在线科技有限公司 Graphic code coding/decoding method, device, storage medium and electronic equipment
CN111435417A (en) * 2020-01-14 2020-07-21 珠海市杰理科技股份有限公司 Image analysis method and device for bar code scanning and storage medium
CN111435417B (en) * 2020-01-14 2023-07-07 珠海市杰理科技股份有限公司 Image analysis method, device and storage medium for bar code scanning
CN112287702A (en) * 2020-05-19 2021-01-29 珠海市杰理科技股份有限公司 Code scanning method and device without external memory, scanning equipment and mobile terminal
CN112287702B (en) * 2020-05-19 2023-03-14 珠海市杰理科技股份有限公司 Code scanning method and device without external memory, scanning equipment and mobile terminal
CN113111675A (en) * 2021-04-19 2021-07-13 广州讯宝电子科技有限公司 Method and system for rapidly identifying bar code based on bar code scanner

Also Published As

Publication number Publication date
CN104899542B (en) 2017-06-20

Similar Documents

Publication Publication Date Title
CN104899542A (en) Image-type CMOS barcode rapid recognition method and apparatus
US20230401399A1 (en) Hybrid system and method for reading indicia
EP3764271B1 (en) Mobile device having an improved user interface for reading code symbols
US6814290B2 (en) Method for processing images captured with bar code reader having area image sensor
US6947612B2 (en) Methods and apparatus for image capture and decoding in a centralized processing unit
US10650211B2 (en) Artificial intelligence-based machine readable symbol reader
CN102385688B (en) The method of bar code sequence during regional imaging
CN101075297A (en) Universal encoding-decoding and read-write device for non-contacting IC card
CN104298953A (en) Method and system for recognizing barcodes in batches
CN114519858B (en) Document image recognition method and device, storage medium and electronic equipment
CN102411701A (en) Method and system for scanning and identifying two-dimensional code array image for invoice special for value-added tax
CN111767754A (en) Identification code identification method and device, electronic equipment and storage medium
CN104346596A (en) Identification method and identification device for QR (Quick Response) code
CN110717397A (en) Online translation system based on mobile phone camera
CN1275182C (en) Two-D bar code reading method and appts. thereof
CN104182200A (en) Cylindrical surface two-dimension code identifying method and device
US10650205B2 (en) Methods, systems, and apparatuses for scanning and decoding direct part marking indicia
CN103544465B (en) A kind of decoding two-dimensional bar code recognition methods and device
CN105765604A (en) Method of recognizing bar code and intelligent wrist ring
KR20200087243A (en) Grain recognition methods, devices and computer storage media
CN106156676A (en) A kind of image-type CCD bar code method for quickly identifying and device
CN105628707A (en) Image recognition method for water treatment resin interface
CN202632304U (en) Image data acquisition equipment
CN1991862A (en) Two-dimensional bar-shaped system with high reliability and recognizing method thereof
CN110647964A (en) Batch curing method for parameter information of digital cameras

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant