CN101908133B - Method and device for decoding bar code - Google Patents

Method and device for decoding bar code Download PDF

Info

Publication number
CN101908133B
CN101908133B CN2010101898678A CN201010189867A CN101908133B CN 101908133 B CN101908133 B CN 101908133B CN 2010101898678 A CN2010101898678 A CN 2010101898678A CN 201010189867 A CN201010189867 A CN 201010189867A CN 101908133 B CN101908133 B CN 101908133B
Authority
CN
China
Prior art keywords
bar code
version
estimated
code image
error
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.)
Expired - Fee Related
Application number
CN2010101898678A
Other languages
Chinese (zh)
Other versions
CN101908133A (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.)
Newland Digital Technology Co ltd
Original Assignee
Fujian Newland Computer 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 Fujian Newland Computer Co Ltd filed Critical Fujian Newland Computer Co Ltd
Priority to CN2010101898678A priority Critical patent/CN101908133B/en
Publication of CN101908133A publication Critical patent/CN101908133A/en
Application granted granted Critical
Publication of CN101908133B publication Critical patent/CN101908133B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention provides a method for decoding a bar code. The method for decoding the bar code comprises the following steps of: acquiring a bar code image; pre-estimating version or format of the bar code image according to the type of the bar code; and decoding the bar code image according to the pre-estimated version or format. In the method for decoding the bar code, the bar code can be decoded without prejudging the version and the format of the bar code, so the problem that the bar code cannot be decoded caused by contamination damage of the bar code version information and the format information is completely solved. The invention further provides a bar code decoding device based the bar code decoding method.

Description

A kind of bar code decoding method and device
[technical field]
The present invention relates to a kind of bar code decoding method and device, relate in particular to a kind of coding/decoding method that can decode to bar code and the device that uses this method with a plurality of versions, form.
[background technology]
Barcode technology is an appearance coding, printing, identification, the data acquisition and processing (DAP) emerging technology that on computer technology and infotech basis, grows up.Barcode technology is because its identification is quick, accurate, reliable and low cost and other advantages; Be widely used in fields such as commerce, taking care of books, storage, post and telecommunications, traffic and Industry Control, and certainly will in " Internet of Things " that rise gradually used, bring into play great function.
Two-dimensional bar code is the bar code of the chequered with black and white figure identifying recording layer symbolic information that (on the two-dimensional directional) distributes on the plane according to certain rules with certain specific geometric figure.Therefore two-dimensional bar code can express great deal of information in horizontal and vertical two orientation while expressing information in very little area.Two-dimensional bar code also has certain verifying function, good error correcting capability.Two-dimensional bar code can be divided into stack two-dimensional bar code and matrix two-dimensional barcode.The stack two-dimensional bar code is that the bar code by the multirow cutting back piles up and forms, and representational stack two-dimensional bar code comprises PDF417, Code 49, Code 16K etc.Matrix two-dimensional barcode is made up of black, the white module that is distributed in by pre-defined rule in the matrix, and representational matrix two-dimensional barcode comprises Code one, Aztec, Date Matrix, QR sign indicating number etc.
The bar code of same code system possibly have a plurality of versions or form (comprising error-correction level, mask).With the QR sign indicating number is example, and the QR sign indicating number 0 has 40 versions from version 1 to edition 4, and version 1 data capacity is minimum, and edition 40 capacity is maximum.In addition, the QR sign indicating number has four error-correction level, is L, M, Q, H from high to low, and corresponding error correction rate is 7%, 15%, 25%, 30%.Error-correction level is the successful ratio of under the QR sign indicating number has the situation of certain damage, also decoding.
Have the general at first detection of bar-code decoder now and obtain function informations such as the version of bar code, form, confirm number of modules, mask graph and the error-correction level of bar code then according to above-mentioned information, again bar code is decoded.If it is stained that the version information on the bar code, format information have, then existing coding/decoding method can't be decoded.
[summary of the invention]
At first need judge the version of bar code, the problem that form is decoded again in order to solve in the prior art to the bar code decoding process; The invention provides a kind of bar code decoding method and use the device of this method, this method and device need not judge that the version of bar code, form can decode to bar code.
For solving the problems of the technologies described above, the invention provides a kind of bar code decoding method, this bar code decoding method comprises: a. obtains bar code image; B. the version or the form of bar code image are estimated through the permutation and combination of possibly carrying out according to barcode types version, mask graph and error-correction level; C. according to version or the form estimated bar code image is decoded; After wherein utilizing certain version estimated or form to the bar code image decoding; If can't obtain correct decoded information; Then utilize other versions estimated or form further bar code image to be decoded,, perhaps used all versions estimated or form to decode until decoding correct decoded information.
According to one preferred embodiment of the present invention, step b comprises according to the pairing barcode types of a plurality of different decode logics and respectively the version or the form of bar code image being estimated.
According to one preferred embodiment of the present invention, step c comprises that a plurality of different decode logics carry out parallel decoding according to version or the form estimated to bar code image respectively.
According to one preferred embodiment of the present invention, form comprises mask graph and error-correction level.
According to one preferred embodiment of the present invention, step c comprises according to the version estimated and confirms sampling grid, and utilizes sampling grid to carry out pixel sampling.
According to one preferred embodiment of the present invention, step c comprises according to the mask graph elimination mask of estimating.
According to one preferred embodiment of the present invention, step c comprises according to the error-correction level estimated and carries out error correction.
For solving the problems of the technologies described above; The present invention also provides a kind of bar-code decoder; This bar-code decoder comprises: estimate module, be used for through the permutation and combination of possibly carrying out to version, mask graph and error-correction level the form or the version of bar code image being estimated; Decoder module; According to form of estimating or version bar code image is decoded; After wherein utilizing certain version estimated or form to the bar code image decoding,, then utilize other versions estimated or form further bar code image to be decoded if can't obtain correct decoded information; Until decoding correct decoded information, perhaps used all versions estimated or form to decode.
According to one preferred embodiment of the present invention, form comprises mask graph and error-correction level.
According to one preferred embodiment of the present invention, estimate module version, mask graph and error-correction level possibly carried out permutation and combination.
Through said method, the version, the form that need not to prejudge bar code can be decoded to bar code, have solved the problem that can't decode to bar code that causes because of bar code version information, format information are stained fully.
[description of drawings]
To combine accompanying drawing and embodiment that the present invention is described further below, in the accompanying drawing:
Fig. 1 is the structural representation of bar-code decoder one embodiment of the present invention;
Fig. 2 is the process flow diagram of bar code decoding method of the present invention;
Fig. 3 is the particular flow sheet of one preferred embodiment of bar code decoding method according to the present invention; And
Fig. 4 is the structural representation of another embodiment of bar-code decoder of the present invention.
[embodiment]
The invention provides a kind of bar code decoding method and use the device of this method.This method and device need not judge that the version of bar code, format information can decode to bar code.
Fig. 1 is the structural representation of bar-code decoder of the present invention.As shown in Figure 1, bar-code decoder 10 of the present invention comprises estimates module 11 and decoder module 12.
Estimate module 11 and can store the version and the form of various dissimilar bar codes, and can estimate form, the version of bar code image according to barcode types, wherein form comprises mask graph and error-correction level.For example, through the permutation and combination of possibly carrying out of each version, mask graph and error-correction level is come version and form are estimated.For example 1~40 version and L, M, Q, four error-correction level of H and the mask graph with the QR sign indicating number carries out permutation and combination.Decoder module 12 is decoded to bar code image according to form, the version estimated.
Fig. 2 is the process flow diagram of bar code decoding method of the present invention.As shown in Figure 2, in bar code decoding method of the present invention, at first obtain bar code image, according to barcode types the version or the form of bar code image are estimated then, and bar code image is decoded according to version of estimating or form.
Fig. 3 is the particular flow sheet of one preferred embodiment of bar code decoding method according to the present invention.This method specifically may further comprise the steps:
Step S1: obtain image;
Step S2: the type according to bar code is estimated the version or the form of bar code image;
Step S3: the version according to estimating is confirmed sampling grid, and carries out pixel sampling;
Step S4: according to the mask graph of estimating the module of code area is carried out XOR and handle, eliminate mask;
Step S5: confirm the error correction code word according to the error-correction level of estimating, checking mistake, and carry out error correction;
Step S6: decoding.
Further, bar code decoding method of the present invention can be judged the type of bar code through the reconnaissance probe figure earlier, estimates according to the barcode types of being judged then.As distortion; Type that also can not need judge bar code; But respectively the version or the form of bar code image are estimated according to the pairing barcode types of a plurality of different decode logics, these a plurality of different decode logics carry out parallel decoding according to version or the form estimated separately to bar code image respectively then.
Specifically as shown in Figure 4, in the present embodiment, decoding device 40 comprises a plurality of decoder modules 42,43.Decoder module 42,43 is respectively the decode logic to different barcode types, and for example decoder module 42 is the decode logic of QR sign indicating number, and decoder module 43 is the decode logic of Code one.Estimate that module 41 is carried out version according to decoder module 42,43 pairing barcode types respectively or form is estimated.Decoder module 42 according to estimate that module 41 estimated to the bar code image decoding of a version of QR sign indicating number or form to input, decoder module 43 carries out parallel decoding to a version of Code one sign indicating number or form to the bar code image of input according to what estimate that module 41 estimated simultaneously.After decoder module 42,43 utilizes certain version estimated or form to the bar code image decoding; If can't obtain correct decoded information; Then decoder module 42,43 can utilize other versions estimated or form further bar code image to be decoded; One in decoder module 42,43 decodes correct decoded information, and perhaps decoder module 42,43 has used all versions estimated or form to decode.Through said method, can carry out parallel decoding to bar code image in the situation that need not to judge barcode types and version, format information, improved decoding speed.
In the above-described embodiments, only the present invention has been carried out exemplary description, but those skilled in the art can carry out various modifications to the present invention after reading present patent application under the situation that does not break away from the spirit and scope of the present invention.

Claims (10)

1. a bar code decoding method is characterized in that, said bar code decoding method comprises step:
A. obtain bar code image;
B. the version or the form of bar code image are estimated through the permutation and combination of possibly carrying out according to barcode types version, mask graph and error-correction level;
C. according to said version of estimating or form bar code image is decoded; After wherein utilizing certain version estimated or form to the bar code image decoding; If can't obtain correct decoded information; Then utilize other versions estimated or form further bar code image to be decoded,, perhaps used all versions estimated or form to decode until decoding correct decoded information.
2. bar code decoding method according to claim 1 is characterized in that, said step b comprises according to the pairing barcode types of a plurality of different decode logics and respectively the version or the form of said bar code image being estimated.
3. bar code decoding method according to claim 2 is characterized in that, said step c comprises that said a plurality of different decode logics carry out parallel decoding according to said version of estimating or form to said bar code image respectively.
4. bar code decoding method according to claim 1 is characterized in that said form comprises mask graph and error-correction level.
5. bar code decoding method according to claim 4 is characterized in that, said step c comprises according to the said version of estimating and confirms sampling grid, and utilizes said sampling grid to carry out pixel sampling.
6. bar code decoding method according to claim 4 is characterized in that, said step c comprises the mask graph elimination mask of estimating according to said.
7. bar code decoding method according to claim 4 is characterized in that, said step c comprises according to the said error-correction level of estimating and carries out error correction.
8. a bar-code decoder is characterized in that, said bar-code decoder comprises:
Estimate module, be used for the form or the version of bar code image being estimated through the permutation and combination of possibly carrying out to version, mask graph and error-correction level;
Decoder module; According to said form of estimating or version said bar code image is decoded; After wherein utilizing certain version estimated or form to the bar code image decoding,, then utilize other versions estimated or form further bar code image to be decoded if can't obtain correct decoded information; Until decoding correct decoded information, perhaps used all versions estimated or form to decode.
9. bar-code decoder according to claim 8 is characterized in that said form comprises mask graph and error-correction level.
10. bar-code decoder according to claim 9 is characterized in that, the said module of estimating possibly carried out permutation and combination with said version, said mask graph and said error-correction level.
CN2010101898678A 2010-06-01 2010-06-01 Method and device for decoding bar code Expired - Fee Related CN101908133B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2010101898678A CN101908133B (en) 2010-06-01 2010-06-01 Method and device for decoding bar code

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2010101898678A CN101908133B (en) 2010-06-01 2010-06-01 Method and device for decoding bar code

Publications (2)

Publication Number Publication Date
CN101908133A CN101908133A (en) 2010-12-08
CN101908133B true CN101908133B (en) 2012-06-06

Family

ID=43263590

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2010101898678A Expired - Fee Related CN101908133B (en) 2010-06-01 2010-06-01 Method and device for decoding bar code

Country Status (1)

Country Link
CN (1) CN101908133B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103955663B (en) * 2014-04-22 2017-02-01 广州宽度信息技术有限公司 QR code fouling resistance identification method
CN105631383A (en) * 2015-12-30 2016-06-01 福建联迪商用设备有限公司 Intelligent gating bar code decoding method and system
CN105654004A (en) * 2015-12-30 2016-06-08 福建联迪商用设备有限公司 Intelligent gating barcode decoding method and chip

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1294519C (en) * 2003-05-22 2007-01-10 武汉矽感科技有限公司 Two-D bar code encoding and decoding method
CN101296441A (en) * 2007-04-26 2008-10-29 中兴通讯股份有限公司 Method and device for scanning two-dimension bar code and transmitting message

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100481117C (en) * 2004-03-15 2009-04-22 武汉矽感科技有限公司 A two dimensional bar code coding-decoding method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1294519C (en) * 2003-05-22 2007-01-10 武汉矽感科技有限公司 Two-D bar code encoding and decoding method
CN101296441A (en) * 2007-04-26 2008-10-29 中兴通讯股份有限公司 Method and device for scanning two-dimension bar code and transmitting message

Also Published As

Publication number Publication date
CN101908133A (en) 2010-12-08

Similar Documents

Publication Publication Date Title
EP3038009B1 (en) Method of barcode templating for enhanced decoding performance
CN102129585B (en) Method and system for transmitting information, device for displaying bar code and device for reading bar code
Sutheebanjard et al. QR-code generator
CN101908125B (en) QR (Quick Response) bar code decoding chip and decoding method thereof
CN103530669A (en) Data information two-dimensional code encoding method
CN101645081A (en) Method and system for tracing farm product information through two-dimension code
WO2014044159A1 (en) Method and device for batch scanning 2d barcodes
US20140263632A1 (en) Creating a virtual bar code from a physical bar code
CN105787403B (en) A kind of bar code reading method of high pixel image processing and the bar code recognizing apparatus of high pixel image processing
CN103927319A (en) QR code business card information access method
CN102799848A (en) Commodity information identification method and commodity information identification device
CN101908133B (en) Method and device for decoding bar code
EP2482231B1 (en) Method for encoding and decoding data on a matrix code symbol
CN102044010A (en) Method for realizing temporary vehicle number plate information data transmission by utilizing two-dimensional bar codes
CN101840499B (en) Bar code decoding method and binarization method thereof
Chen et al. Customized 2D barcode sensing for anti-counterfeiting application in smart IoT with fast encoding and information hiding
CN101882202B (en) Sign character extracting module and method
Skurowski et al. Performance of QR code detectors near Nyquist limits
TW201601068A (en) Image type high-speed barcode scanning method
CN201518129U (en) Two-dimensional code information tracing system for agricultural product
CN103902951B (en) Electronic tag and the converting system and method for Logistic Unit bar code
CN201927040U (en) Bar code decoding device
CN102087698B (en) A kind of information transferring method and system, bar code display and reading device
CN102087699B (en) Information transmission method and system, bar code display device and reading device
CN101882212B (en) Method for acquiring barcode image

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: 350015 No. 1 Rujiangxi Road, Mawei District, Fuzhou City, Fujian Province

Patentee after: NEWLAND DIGITAL TECHNOLOGY Co.,Ltd.

Address before: 350015 New Continental Science Park No. 1 Rujiangxi Road, Mawei District, Fuzhou City, Fujian Province

Patentee before: Fujian Newland Computer Co.,Ltd.

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20120606