A kind of based on network commodity counterfeit prevention two-dimension code Redundancy Design method
Technical field
The present invention relates to a kind of two-dimensional bar code, particularly a kind of based on network commodity counterfeit prevention two-dimension code Redundancy Design method.
Background technology
Two-dimension code (2-dimensional bar code) is (on the two-dimensional directional) distributes on the plane according to certain rules with certain specific geometric figure a chequered with black and white graphic recording data symbol information; On coding, utilize " 0 ", the notion of " 1 " bit stream that constitutes the computer-internal logical foundations dexterously, use several and the corresponding geometrical body of scale-of-two to represent the literal numerical information, automatically handle with realization information by image input device or photoelectric scanning device automatically identifying and reading: therefore two-dimensional bar code/two-dimension code can express a large amount of information in horizontal and vertical two orientation while expressing information in very little area.
The existing use than what popularize is the PDF417 two-dimension code, the difference of it and one dimension sign indicating number is that multirow is formed bar code, do not need to connect a database, itself can store mass data, be applied to: hospital, driver's license, handling of goods and materials, freight transportation, when bar code was subjected to necessarily to destroy, error correcting can make bar code can be correctly decoded PDF417.The PDF417 two-dimension code is that news Bo Er (Symbol) scientific ﹠ technical corporation is in the product of nineteen ninety development.It is a multirow, continuity, variable length, comprise the symbol logo of mass data.Its character set comprises all 128 characters, and maximum data content is 1850 characters.
Owing to include 1850 characters in less space, this requires very thin with regard to the bar that requires its bar code, characteristics wherein are to contain much information, and problem is to obtain two-dimension code under camera lens situation of low quality by imaging, be difficult to obtain accurate two-dimension code, influence reading of data.
" telephone set with recognition capability " China Patent No. of having invented the inventor is: among the ZL03108082.0, disclosing a kind of subsidiary camera that utilizes mobile phone carries out two-dimension code and reads, realize false proof technology, but because 1,300,000 general cameras are unintelligible in the 15mm-30mm imaging, excellent its when 15mm-30mm extracts the PDF417 two-dimension code, be difficult to identification especially, influenced existing mobile phone greatly in this application on the one hand.In order to overcome this problem, some mobile phone has increased closely focus adjusting mechanism specially when design, to increase the imaging capability to close-in target.
Its this, the existing two-dimensional sign indicating number is the square structure, the application during as commodity counterfeit prevention seems a bit not too suitable sometimes.
Summary of the invention
The purpose of this invention is to provide a kind of can being beneficial to and have the convenient extraction of mobile phone two-dimensional bar code now, and do not change the based on network commodity counterfeit prevention two-dimension code Redundancy Design method of mobile phone hardware.
The object of the present invention is achieved like this, a kind of based on network commodity counterfeit prevention two-dimension code Redundancy Design method, it is used for representing " 0 " by two kinds of bigger geometrical bodies of contrast at least, " 1 " bit stream, it is characterized in that: two kinds of geometrical body formation levels and vertical " 0 " and " 1 " coding structure in the rectangular parallelepiped framework that contrast is bigger, the geometrical body shape of " 0 " and " 1 " is identical, equal and opposite in direction, by the other inchoate aspect space as two-dimension code of " 0 " and " 1 " this sign of primordial, the geometrical body length of side of described " 0 " or " 1 " is between 0.4-1mm in the rectangular parallelepiped framework.
Described " 0 " and " 1 " coding structure form 16*32 bit in the rectangular parallelepiped framework, can represent 64 bytes.
Described " 0 " and " 1 " coding structure have the two-dimension code of two groups of identical structures in the rectangular parallelepiped framework.
The two-dimension code of described two groups of identical structures is left-right symmetric or symmetrical up and down.
The two-dimension code of described two groups of identical structures comprises that at least the byte that defines network address and anti-counterfeit commodities do not repeat the coding of numbering.
The two-dimension code symmetry place of described two groups of identical structures comprises the check code of each group two-dimension code.
The coding that described anti-counterfeit commodities does not repeat to number comprises date of manufacture, the use term of validity, merchandise classification information, manufacturer's information, grown place information, trade name information, goods number information and the information of check code of commodity at least.
Advantage of the present invention is: same structure constitutes two groups of two-dimensional bar codes because two-dimension code adopts up and down, it is false proof that employing network data base form is carried out two-dimensional bar, as: date of manufacture: 2010-8-16 4 bytes, the term of validity: 2012-8-16 4 bytes, merchandise classification: use 2 bytes, in database, use hexadecimal representation, as 0 expression liquor, 1 expression grape wine, represent champagne with 3, represent cigarette with 10, then can comprise more than 60,000 kind of commodity.Manufacturer: 3 bytes; Grown place: 1 word byte, trade name: 2 bytes; Goods number: 4 bytes, network address: 55; Sign: 1 byte, verification: 4 bytes, then totally 32 bytes.That is to say, can form nearly all commodity counterfeit prevention with 32 bytes.From data processing, can both guarantee like this to the bar code reliability.
Description of drawings
The invention will be further described below in conjunction with the embodiment accompanying drawing:
Fig. 1 is the embodiment of the invention 1 structural representation;
Fig. 2 is the embodiment of the invention 2 structural representations.
Among the figure: 1, be used for representing " 0 ", " 1 " bit stream geometrical body; 2, rectangular parallelepiped framework; 3, basic identification; 4, go up two-dimensional bar code; 5, following two-dimensional bar code; 6, the second from left dimension bar-code; 7, right two-dimensional bar code; 8, check code.
Embodiment
Embodiment 1
Fig. 1 has provided a kind of two-dimensional bar code structure up and down, rectangular parallelepiped framework 2 in last and bottom right a basic identification 3 is arranged respectively, last two-dimensional bar code 4 and following two-dimensional bar code 5 are identical, basic identification 3 is " mouth " word shapes, " mouth " word line bar is with wide all around, " mouth " word upper end has comprised three 0 or three 1, when the black geometrical body represents 0, hem width has comprised three 0 on " mouth " word, hem width has comprised three 0 under " mouth " word, comprised two 0 and one 1 in the middle of " mouth " word, here be used for representing " 0 ", " 1 " bit stream geometrical body 1 is positive four limit bodies, and its length of side equates.Horizontal continuous 32 bits, vertically continuous 16 bits form 512 bits, can form 64 bytes, and same structure constitutes two groups of two-dimensional bar codes about adopting, and every group accounts for 32 bytes.This 32 byte is false proof as adopting the network data base form to carry out two-dimensional bar, as: date of manufacture: 2010-8-16 4 bytes, the term of validity: 2012-8-16 4 bytes, merchandise classification: use 2 bytes, in database, use hexadecimal representation, as 0 expression liquor, 1 expression grape wine is represented champagne with 3, represent cigarette with 10, then can comprise more than 60,000 kind of commodity.Manufacturer: 3 bytes; Grown place: 1 word byte, trade name: 2 bytes; Goods number: 4 bytes, network address: 55; Sign: 1 byte, verification: 4 bytes, then totally 32 bytes.That is to say, can form nearly all commodity counterfeit prevention with 32 bytes.
The geometrical body of " 0 " or " 1 " is with positive four limit bodies, and the length of side is between 0.4-1mm.In the 15mm-30mm imaging, the treatment circuit by mobile phone carries out image recognition then for 1,300,000 cameras for this, read network address and not repeated encoding be not send one's regards to topic.
Adopt the security of identical its commodity counterfeit prevention of two-dimensional bar code of complete lattice to guarantee.Can local damage because the two-dimensional bar code on the commodity has, adopt two groups of identical two-dimensional bar codes of complete lattice, by appropriate design, be not more than 1/2nd as long as two-dimensional bar code damages, can both be complete read all information.
Embodiment 2
Fig. 2 is a kind of left and right sides two-dimensional bar code structure, and other structure with Fig. 1 is identical.No matter be to adopt up-down structure or left and right sides structure.Each group two-dimensional bar code is as long as integral body forms 16*32 bit, and each group two-dimensional bar code all has 32 bytes.
Fig. 1 explanation is the embodiment that provides for thought of the present invention is described, in fact the definition about the concrete commodity counterfeit prevention information of 32 bytes can change to some extent according to concrete form.Undertaken correspondingly as network address by the fixedly network address of a group coding and mobile phone EMS memory storage, just can provide considerable network address or IP.
" mouth " word of basic identification 3 usefulness shape is represented, can set up the basic size of expression " 0 ", " 1 " bit stream geometrical body by reading basic identification 3, read other " 0 ", " 1 " bit stream geometrical body then successively as benchmark, deciphering is 0 or 1, determines anti-counterfeiting information at last.
In one group of two-dimensional bar code, include check code 8, can find by check code 8 whether the network address that reads is correct, when correct, send the network address that reads by mobile phone, enter corresponding website by the mobile network, send to corresponding website and do not repeat anti-fake code, obtain the true or false of commodity counterfeit prevention.
Certainly, when incorrect, the handset processes circuit is handled second half two-dimensional barcode image that obtains, when second half two-dimensional barcode image after check code 8 verifications, correctly, send the network address that reads by mobile phone again, enter corresponding website by the mobile network, do not repeat anti-fake code to the corresponding website transmission, obtain the true or false of commodity counterfeit prevention.
When two all incorrect, can send the network address that reads by mobile phone then to the mobile phone treatment circuit to the half and half splicing processing of two groups of two-dimensional barcode images that obtain, enter corresponding website by the mobile network, do not repeat anti-fake code to the corresponding website transmission, obtain the true or false of commodity counterfeit prevention.
In the time all can not obtaining complete information by said method, mobile phone provides information.
Embodiment 3
The structure of Fig. 1 and Fig. 2 also can be by horizontal continuous 32 bits, and vertical continuous 20 bits are to increase overall quantity of information.When horizontal continuous 32 bits, during vertically continuous 20 bits, overall 640 bits, 80 bytes are arranged, if by two groups of two-dimensional bar code figure designs, every group has 40 bytes, during than vertical continuous 16 bits, many 8 bytes, 8 bytes and original 7 bytes constitute website information jointly, the length of one of them byte definition network address.Network address is made of numeral and letter, and with 7 bits, the most significant digit of a byte is represented a little or oblique line, in the C letter among the www.cctv.com/sx.cn, ASCII character 16 systems of C letter are 43, then illustrate before the C letter have with C3., behind com, add 1 before 16 systems and can represent/line.