Patent ID: 9230147
Filing Date: 2016-01-05
CPC Classification: G06K

Claim Text:
1. A method of optically reading out one of a first barcode and a second barcode contained within a field of view based on differences between first and second formats respectively of the first barcode and the second barcode and of decoding information stored in the one of the first and second barcodes, each of the first and second barcodes being composed of linearly-aligned parallel bars, the first format of the first barcode defining a predetermined maximum margin width and a maximum number of bars, the second format of the second barcode defining a maximum number of bars, the maximum number of bars of the second format being smaller than the maximum number of bars of the first format, and a part of the first barcode and a part of the second barcode having an identical format of continuously and linearly-aligned parallel bars, the method comprising: optically reading out the field of view including at least the identical format of continuously and linearly-aligned parallel bars and obtaining a binarized black and white pattern of the field of view, the black and white pattern being composed of black bars and white bars; wherein the optical readout of the one of the first and second barcodes uses an area sensor in two-dimension, and the determining whether there is a margin comprises: setting a check line on one external side region of at least one of both ends of the black and white pattern, the check line extending outwardly from the at least one of both ends of the black and white pattern: measuring a first height of the black and white pattern in a height direction, the height direction being orthogonal to a length direction of the black and white pattern; measuring a second height of a bar on the check line in the height direction; comparing the first height with the second height; and determining that the bar measured on the check line is a margin when the first height and the second height are different from each other; subsequent to the optical reading, decoding the black and white pattern using an algorism corresponding to the second format; subsequent to the decoding the black, determining whether there is a margin having a width greater than the predetermined maximum margin width of the first barcode and located at at least one of both ends of the black and white pattern; subsequent to the determining whether there is a margin, determining that a result of the decoding is good when it is determined that there is a margin with having the width greater than the predetermined maximum margin width of the first barcode and located at at least one of both ends of the black and white pattern; wherein the method further comprises: storing a plurality of black and white patterns that are close to or equivalent to the part of the black and white pattern; and checking whether the black and white pattern coincides with any one of the stored plurality of black and white patterns, wherein the determining whether there is a margin is carried out when the black and white pattern coincides with any one of the stored plurality of black and white patterns.