Bar code, bar code processing system, and coffee machine
By introducing a combination of a closed-boundary area and an image sensor processing circuit into the barcode, the problem of difficult two-dimensional barcode alignment is solved, enabling simple and efficient barcode reading and reducing the dependence on the image frame buffer.
Patent Information
- Application Number
- CN202210249739.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2021-11-03
- Filing Date
- 2022-03-14
- Publication Date
- 2026-11-20
- Estimated Expiration
- 2042-03-14
AI Technical Summary
In existing technologies, aligning two-dimensional barcodes is difficult, especially for small-sized two-dimensional barcodes which require a large image frame buffer, resulting in wasted resources and low alignment efficiency.
The barcode design with a closed boundary area is adopted. The code information is determined by the color order, intensity order and the relationship between bright and dark spots. The decoding direction is independent of the boundary area. The barcode is read by an image sensor and processing circuit, reducing the dependence on the image frame buffer.
It enables easy barcode alignment, reduces the storage requirements of the image frame buffer, and improves the efficiency and accuracy of barcode reading.
Smart Images

Figure CN115221999B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to barcodes, barcode processing systems, and coffee machines, and particularly to barcodes, barcode processing systems, and coffee machines that can use an alignment mechanism without adding a frame buffer. Background Technology
[0002] Barcodes in the current technology can be divided into one-dimensional barcodes and two-dimensional barcodes. One-dimensional barcodes can only cover a limited amount of information. Two-dimensional barcodes are more difficult to align, especially when they are small. In addition, the alignment of two-dimensional barcodes requires a larger frame buffer. Summary of the Invention
[0003] One objective of this invention is to disclose a barcode with a relatively simple alignment mechanism.
[0004] Another objective of this invention is to disclose a barcode processing system that makes it easier to align barcodes.
[0005] An embodiment of the present invention discloses a barcode comprising: a code area including bright spots, dark spots and code information; and a boundary area surrounding the code area in a closed shape; wherein the decoding direction of the code area is independent of the boundary area; wherein the code information is determined according to at least one of the following: color order, intensity order, and the relationship between the bright spots and the dark spots.
[0006] Another embodiment of the present invention discloses a barcode processing system, comprising: an image sensor for optically sensing an image; and a processing circuit for determining whether a closed object exists within the sensing image to define a code area within the closed object in the sensing image, wherein the code area includes bright spots and dark spots, and wherein the processing circuit generates code information based on at least one of the following: color order, intensity order, and the relationship between the bright spots and the dark spots; wherein the decoding direction of the code area is independent of the boundary area.
[0007] Another embodiment of the present invention discloses a coffee machine, comprising: a capsule container for holding capsules; a liquid injection probe; and a barcode reader including an image sensor and a processing circuit. The image sensor optically senses a sensing image. The processing circuit determines whether a closed object exists within the sensing image to define a code area within the closed object in the sensing image, wherein the code area includes bright spots and dark spots, wherein the processing circuit generates code information based on at least one of the following: color order, intensity order, and the relationship between the bright spots and the dark spots; wherein the decoding direction of the code area is independent of the boundary area; wherein a plurality of barcodes repeatedly appear on the upper surface of the capsule, each of the plurality of barcodes including the closed object and the code area; wherein the liquid injection probe faces the upper surface, and the distance between the probe and the upper surface enables the barcode reader to read at least one complete barcode among the plurality of barcodes.
[0008] According to the aforementioned embodiments, barcodes can be more easily aligned through closed boundary areas without the need for a frame buffer with large storage space. Attached Figure Description
[0009] Figure 1 , Figure 2 as well as Figure 3 Schematic diagrams of barcodes according to different embodiments of the present invention are shown.
[0010] Figure 4 A block diagram of a barcode reader according to an embodiment of the present invention is shown.
[0011] Figure 5 A schematic diagram of a coffee machine according to an embodiment of the present invention is shown.
[0012] Figure 6 A schematic diagram illustrating a barcode location on the upper surface of a capsule according to an embodiment of the present invention is shown.
[0013] Figure 7 as well as Figure 8 Schematic diagrams of code regions according to different embodiments of the present invention are illustrated.
[0014] The reference numerals in the attached figures are explained as follows:
[0015] 100, 200, 300 barcodes
[0016] 400 barcode reader
[0017] 401 Processing Circuit
[0018] 403 Image Sensor
[0019] 405 lens
[0020] 500 coffee machine
[0021] 501 Capsule Container
[0022] 503 Liquid Injection Probe
[0023] 505 shelf
[0024] BK1, BK11, BK12, BK2, BK21, BK22, BK3, BKa grid
[0025] BR Boundary Zone
[0026] BKC1, BKC2, BKC3, BKC4, BKC5, BKC6, BKC7 encoding format
[0027] BKCa, BKCb, BKCc encoding grid
[0028] BKE1, BKE2, BKE3 (space)
[0029] BKL1, BKL2, BKL3 large encoding grid
[0030] BKS1, BKS2, BKS3 sub-coding grid
[0031] CR1, CR2, CR3, CR code areas
[0032] Capsules
[0033] IR isolation zone
[0034] SR blank area
[0035] Rows R1, R2, R3, R4, R5, R6
[0036] Sur upper surface Detailed Implementation
[0037] The present invention will be described below with reference to several embodiments. It should be noted that the elements in each embodiment can be implemented by hardware (e.g., devices or circuits) or firmware (e.g., at least one program written in a microprocessor). Furthermore, the terms "first," "second," and similar descriptions in the following description are only used to define different elements, parameters, data, signals, or steps, and are not intended to limit their order. For example, the first device and the second device can be devices with the same structure but different from each other.
[0038] Figure 1 , Figure 2 as well as Figure 3 Schematic diagrams of barcodes according to different embodiments of the present invention are illustrated. For example... Figure 1 As shown, barcode 100 includes a code area CR and a boundary area BR. The code area CR contains code information. A barcode reader can obtain the code information by decoding the code area CR. The boundary area BR forms a closed shape surrounding the code area CR. The color order or intensity order of the code area CR represents the code information. Intensity order can refer to the brightness order, such as grayscale values 0-100-50. The code information can represent multiple codes. For example, if the color order of the code area CR is purple-green-orange, the corresponding code information is 101101. Another example is that if the grayscale value order of the code area CR is 0-100-50, the corresponding code information is 011011.
[0039] In one embodiment, the code area CR includes bright spots and dark spots. Code information can be represented by the ratio of the number of bright spots (hereinafter referred to as NB) to the number of dark spots (hereinafter referred to as ND). For example, if NB is 80% of NB+ND, then the code information represents code 0011001. As another example, if NB is 70% of NB+ND, then the code information represents code 0011011. In another embodiment, the code information is the ratio of the total bright spot area to the total dark spot area.
[0040] According to the foregoing embodiments, the code information of the code area CR can be represented by at least one of the following: color order, intensity order, and the relationship between bright spots and dark spots. For example, the code information of the code area CR can be represented by color order and intensity order, but not by a relationship. Alternatively, the code information of the code area CR can be represented by a relationship, not by color order and intensity order. The relationship between bright spots and dark spots can be, for example, the ratio of the number of bright spots to the number of dark spots, or the ratio of the total area of bright spots to the total area of dark spots.
[0041] In one embodiment, the code region CR includes multiple color-coded cells BK1, BK11, BK12, BK2, BK21, BK22, BK3, BKa… (only eight of which are marked). Cells BK1, BK11, BK12, BK2, BK21, BK22, BK3, BKa… have at least one color, and the color order of the aforementioned code region CR is the color order of cells BK1, BK11, BK12, BK2, BK21, BK22, BK3, BKa… For example, if cells BK1, BK2, and BK3 are red, green, and blue respectively, then the color order of cells BK1, BK2, and BK3 is red-green-blue, and the code region CR also has a color order of red-green-blue. The above intensity order can also follow the same rule.
[0042] In one embodiment, the code region CR is decoded following a grid distribution. However, the decoding direction can also be set by any other method. Furthermore, in one embodiment, the decoding direction of the code region CR is independent of the boundary region BR. In one embodiment, the decoding direction is independent of the size, position, color, and shape of the boundary region BR. Furthermore, in one embodiment, the boundary region BR does not have any code information. The boundary region BR may have only one color or more colors. In one embodiment, the color of the boundary region BR is the same as the color of the code region CR.
[0043] Furthermore, in one embodiment, if the code region CR is decoded in both a first direction and a second direction opposite to the first direction, the same code information can still be obtained. The first and second directions can be, for example, [missing information]. Figure 1 The X and Y directions or Figure 1The P and Q directions are defined in the code. The first and second directions can start from the same row or different rows, depending on the decoding algorithm. For example, decoding can start from cell BK1 along the X direction, or from cell BKa along the Y direction.
[0044] The aforementioned direction can be combined with at least one sub-direction. For example, for the X direction, it could mean that cell BK1 is decoded, and then cell BK2 is decoded. No sub-direction is used in this example. Furthermore, in another example, for the X direction, it could mean that cell BK1 is decoded, and then cells BK11, BK12... in the same column are decoded (sub-direction). After decoding all cells in the same column as cell BK1, cell BK2 is decoded, and then cells BK21, BK22... in the same column as cell BK2 are decoded. Other directions such as the Y, P, and Q directions can follow the same rules.
[0045] The term "identical code information" can refer to the code information actually being the same. For example, a code area CR decodes to the same code 10101100 when decoded in two symmetrical directions (such as the X and Y directions). However, "identical code information" can also mean "converting different code information into other code information to obtain the same code information." For example, decoding a code area CR in the X direction yields the code 10101100, while decoding it in the Y direction yields the opposite code 00110101. However, the barcode reader decoding the code area CR will interpret 00110101 as 10101100, thus obtaining the same code information.
[0046] The first direction and the second direction are not necessarily opposite to each other. In one embodiment, if the code region CR is decoded in the first direction and the second direction respectively, the same code information can be obtained. The angle between the first direction and the second direction is less than 180 degrees.
[0047] In one embodiment, after acquiring code information, the barcode reader sends the code information to the control circuit, which then generates a corresponding control command. Therefore, in the aforementioned embodiment, when the barcode reader acquires different code information (which should ideally be the same code information), it can convert the different code information into converted code information and then transmit the converted code information to the controller. In this way, even if the barcode reader receives different code information, the control circuit can still generate the same control command. For example, after acquiring code 10101100 and code 00110101, the barcode reader converts code 00110101 into the converted code 10101100 and then transmits the converted code 10101100 to the control circuit. The control circuit then generates a control command corresponding to code 10101100 but not to code 00110101.
[0048] Conversely, in another example, after acquiring different code information, the barcode reader directly transmits it to the control circuit. Then, even if the control circuit receives different code information, it will still generate the same control command. For example, after receiving code 10101100 and code 00110101, the barcode reader directly transmits both codes to the control circuit. Then, when the control circuit receives code 10101100 and code 00110101, it will still generate the same control command respectively.
[0049] The control circuit can be incorporated into a barcode processing system that includes the aforementioned barcode reader. The barcode processing system can read barcodes using the barcode reader and operate according to control commands provided by the control circuit. The barcode processing system can be used in various electronic devices, such as coffee machines.
[0050] Figure 1 The boundary region BR in the image is filled with color and has no blank areas. However, the boundary region BR can also have at least one blank area, but the barcode reader will still determine that the boundary region BR is a closed shape when sensing an image that includes the boundary region BR. In other words, the barcode reader ignores the blank areas when sensing an image that includes the boundary region BR.
[0051] Figure 2 This is a schematic diagram of a barcode 200 that includes a boundary area with a blank area SR. (See diagram below.) Figure 2 As shown, the boundary area BR contains multiple blank areas SR (only two are shown). Blank areas SR are not limited to empty areas, white areas, or squares. For example, a blank area SR can be a relatively small area compared to the other areas of the boundary area BR. Furthermore, a blank area SR can have at least one color different from the colors in the boundary area BR. Additionally, the color of a blank area SR can be the same as the color of the boundary area BR but darker, or the same as the color of the boundary area BR but lighter. In short, a blank area SR can have at least one color that can be visually distinguished from the color of the boundary area BR, whether by the user's naked eye or in the image.
[0052] In addition, the boundary area BR may include blank areas SR with different shapes or sizes. The blank areas SR may be areas specially designed into the boundary area BR, or unwanted areas caused by printing, or unwanted areas caused by wear.
[0053] Please refer to this again. Figure 1In addition to the aforementioned boundary area BR and code area CR, barcode 100 may also include an isolation area IR. The isolation area IR surrounds the boundary area BR, isolating the code area CR and boundary area BR from another code area CR and another boundary area BR. In short, the isolation area IR is used to isolate the code area CR and boundary area BR of different barcodes. In one embodiment, the isolation area IR can make the entire barcode more visible in the background image.
[0054] In one embodiment, the isolation region IR and the boundary region BR have the same width. For example, as shown... Figure 1 As shown, the widths of the isolation region IR and the boundary region BR are both the widths of the blank area.
[0055] Boundary area (BR) is not limited to Figure 1 The square shown. For example, the boundary region BR can be like... Figure 3 The barcode 300 is a hexagon. In this case, the CR area can still have cells. Figure 3 In one embodiment, the grid can be set smaller to more completely fill the hexagonal code region CR. Alternatively, in one embodiment, if some regions in the code region CR cannot form a complete grid, these regions are ignored when decoding the code region CR. In another embodiment, the boundary region BR can have an irregular shape.
[0056] Figure 4 A block diagram of a barcode processing system according to an embodiment of the present invention is shown, which can be used to read barcodes disclosed in the present invention. Figure 4 As shown, the barcode reader 400 includes a processing circuit 401 and an image sensor 403. The image sensor 403 optically senses the image through a lens 405. The processing circuit 401 determines whether a closed-shaped object (i.e., the aforementioned boundary area BR) exists in the sensed image, and determines the intensity or color order of the code areas CR within the closed-shaped object in the sensed image. It then generates code information based on the intensity or color order of the code areas CR. In short, if the processing circuit 401 determines that a closed-shaped object exists, it begins decoding the code areas CR that should be inside the closed-shaped object.
[0057] The barcode reader 400 can be installed in an electronic device that only has barcode reading functionality, such as a barcode reader used in a store. Alternatively, the barcode reader 400 can be implemented by executing a program on a mobile electronic device. For example, the processing circuit 401 can be a mobile phone's processor, and the image sensor 403 can be a mobile phone's camera. In this case, an application can be installed on the mobile phone, and the mobile phone's processor can execute the application to perform the functions of the barcode reader 400.
[0058] In one embodiment, the barcode reader 400 can be used in a coffee machine. Figure 5A schematic diagram of a coffee machine according to an embodiment of the present invention is shown. Figure 5 As shown, the coffee machine 500 includes a capsule container 501, a liquid injection probe 503, and the aforementioned barcode reader 400. The capsule container 501 is used to hold a capsule. The capsule container 501 can be a separate device specifically designed for capsules, or it can be a notch in any part of the coffee machine 500.
[0059] In one embodiment, the liquid injection probe 503 is used to inject water into the capsule to brew coffee. The structure used to fix the liquid injection probe 503 can vary depending on the coffee machine. Furthermore, in Figure 5 In the embodiments, having with Figure 4 Barcode 400, which has the same structure and function as shown, is fixed on shelf 505 of coffee machine 500, but is not limited thereto.
[0060] In one embodiment, multiple barcodes 100 appear repeatedly on and around the upper surface Sur of the capsule, such as... Figure 6 As shown. In this configuration, the liquid injection probe 503 and the barcode reader 400 face the upper surface Sur of the capsule, and the distance between the barcode reader 400 and the upper surface Sur allows the barcode reader 400 to read at least one complete barcode 100 among multiple barcodes 100. Note that although... Figure 5 , Figure 6 The embodiment is illustrated using barcode 100 as an example, but barcode 100 can also be replaced with other barcodes.
[0061] Please refer to this again. Figure 1 The dimensions of grids BK1, BK11, BK12, BK2, BK21, BK22, BK3, BKa… can be set according to the width of the boundary region BR. For example, in one embodiment, the width of grids BK1, BK11, BK12, BK2, BK21, BK22, BK3, BKa can be the same as the width of the boundary region BR.
[0062] In addition, Figure 1 In addition to the code regions shown, this invention also discloses other code regions. Figure 7 as well as Figure 8 Schematic diagrams of code regions according to different embodiments of the present invention are illustrated. Figure 7 and Figure 8 In this embodiment, the code area includes code cells marked by slashes and includes spaces. A code cell may represent a code, while a space represents the absence of a code and is therefore 0. Also note that spaces may have a specific color, rather than being limited to empty or white.
[0063] exist Figure 7In some embodiments, code region CR1 includes coding grids of different sizes. For example, code region CR1 includes large coding grids BKL1, BKL2, BKL3 and small coding grids BKS1, BKS2, BKS3. The large coding grids BKL1, BKL2, BKL3 and the small coding grids BKS1, BKS2, BKS3 have... Figure 7 The grids within are different colors. Furthermore, in Figure 7 In some embodiments, for example, rows R3 and R6, which are entirely empty, do not represent any code and are used to separate the coding cells in code region CR1 to form sub-code regions. Therefore, according to this rule, the coding cells of rows R1 and R2 form one sub-code region, and the coding cells of rows R4 and R5 form another sub-code region.
[0064] Figure 7 In this embodiment, the large encoding cells BKL1, BKL2, and BKL3 represent a code number (2 in this embodiment). Figure 7 In this embodiment, the sub-code cells BKS1, BKS2, and BKS3 represent another code number (1 in this embodiment). If a column in the sub-code area contains only a space, it means there is no code, and therefore it is 0. Thus, rows R1 and R2 represent code 2(BKL1)-1(BKS1)-2(BKL2)-0(cell)-1(BKS2)-1(BKS3)-2(BKL3). Following the same rule, rows R4 and R5 represent code 11102021.
[0065] exist Figure 8 In some embodiments, only coding grids that follow a specific arrangement represent code numbers; otherwise, the coding grids are ignored. For example, Figure 8 The code region CR2 includes code cells BKC1, BKC2, BKC3, BKC4, BKC5, BKC6, and BKC7, and also includes spaces BKE1, BKE2, and BKE3. Furthermore, in Figure 8 In this embodiment, two consecutive coded cells represent code number 1; otherwise, the coded cells are ignored. Therefore, in Figure 8 In this embodiment, encoding cells BKC1 and BKC2 represent code number 1, space BKE1 represents no code and is therefore 0, encoding cells BKC3 and BKC4 represent code number 1, space BKE2 represents no code and is therefore 0. Encoding cell BKC5 is ignored, space BKE3 represents no code and is therefore 0, and encoding cells BKC6 and BKC7 represent code number 1. Therefore, Figure 8 In the code section, CR2 represents code 101001.
[0066] The specific arrangement mentioned above is not limited to the arrangement in code region CR2. For example... Figure 8As shown in code region CR3, only the code cells that form a square consisting of four code cells represent the code number (1 in this example); the other code cells are ignored. Therefore, code cells BKCa, BKCb, and BKCc in code region CR3 are ignored, and code region CR3 represents code 1101.
[0067] According to the aforementioned embodiments, barcodes can be more easily aligned through closed boundary areas without the need for a frame buffer with large storage space.
[0068] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A barcode, characterized in that, Include: The code section includes highlights, hidden features, and code information; and The boundary area, which surrounds the code area in a closed shape; The decoding direction of this code region is independent of the boundary region; The code information is determined based on at least one of the following: Color order, intensity order, and the relationship between the bright spot and the dark spot; The shape, location, and color of this boundary region are independent of the decoding direction; After obtaining different code information, the different code information is converted into converted code information, and the converted code information corresponds to the same control command; or, after receiving different code information, the different code information directly corresponds to the same control command.
2. The barcode as described in claim 1, characterized in that, The code area contains cells, each cell has a color, and the color order of the code area is the same as the color order of the cells.
3. The barcode as described in claim 1, characterized in that, The boundary area has only one color.
4. The barcode as described in claim 3, characterized in that, The color of the boundary area is the same as the color of the code area.
5. The barcode as described in claim 1, characterized in that, This boundary area does not contain any code information.
6. The barcode as described in claim 1, characterized in that, Further includes: An isolation zone, surrounding the boundary zone, is used to isolate the code zone, the boundary zone, from another code zone, and another boundary zone.
7. The barcode as described in claim 1, characterized in that, The boundary area is colored and does not contain any blank areas.
8. The barcode as described in claim 1, characterized in that, This boundary area has blank areas.
9. The barcode as described in claim 8, characterized in that, When the barcode processing system senses an image containing a boundary area with blank areas, it still determines that the boundary area is a closed shape.
10. A barcode processing system, characterized in that, Include: Image sensor, which senses images optically; A processing circuit is used to determine whether a closed object exists within the sensing image, so as to define a code area within the closed object in the sensing image, wherein the code area includes bright spots and dark spots, and wherein the processing circuit generates code information based on at least one of the following information: color order, intensity order, and the relationship between the bright spot and the dark spot. The decoding direction of this code region is independent of the boundary region; The shape, location, and color of this boundary region are independent of the decoding direction; After obtaining different code information, the different code information is converted into converted code information, and the converted code information corresponds to the same control command; or, after receiving different code information, the different code information directly corresponds to the same control command.
11. The barcode processing system as described in claim 10, characterized in that, The code area contains cells, each cell has a color, and the color order of the code area is the same as the color order of the cells.
12. The barcode processing system as described in claim 10, characterized in that, The boundary area has only one color.
13. The barcode processing system as described in claim 12, characterized in that, The color of the boundary area is the same as the color of the code area.
14. The barcode processing system as described in claim 10, characterized in that, This boundary area does not contain any code information.
15. The barcode processing system as described in claim 10, characterized in that, The boundary area is colored and does not contain any blank areas.
16. The barcode processing system as described in claim 10, characterized in that, This boundary area has blank areas.
17. The barcode processing system as described in claim 16, characterized in that, When the image sensor detects an image containing a boundary region with blank areas, the processing circuit still determines that the boundary region is a closed shape.
18. The barcode processing system as described in claim 10, characterized in that, Further includes: A control circuit is used to generate control commands based on the barcode information to control the barcode processing system; After obtaining different barcode information, the barcode processing system converts the barcode information into converted barcode information and then transmits the converted barcode information to the control circuit. The control circuit generates the control command based on the converted code information.
19. The barcode processing system as described in claim 10, characterized in that, Further includes: A control circuit is used to generate control commands based on the barcode information to control the barcode processing system; After obtaining different barcode information, the barcode processing system directly transmits the barcode information to the control circuit. The control circuit generates the same control command based on different code information.
20. A coffee machine, characterized in that, Include: Capsule container, used to hold capsules; Liquid injection probe; Barcode reader, including: Image sensors, which optically sense images; and A processing circuit is used to determine whether a closed object exists within the sensing image, so as to define a code area within the closed object in the sensing image, wherein the code area includes bright spots and dark spots, and wherein the processing circuit generates code information based on at least one of the following information: color order, intensity order, and the relationship between the bright spot and the dark spot. The decoding direction of this code region is independent of the boundary region; After obtaining different code information, the different code information is converted into converted code information, and the converted code information corresponds to the same control command; or, after receiving different code information, the different code information directly corresponds to the same control command. Multiple barcodes appear repeatedly on the upper surface of the capsule, and each of the multiple barcodes includes the enclosed object and the code area; The liquid injection probe is directed toward the upper surface, and the distance between the probe and the upper surface enables the barcode reader to read at least one complete barcode among the plurality of barcodes.
Citation Information
Patent Citations
Method and system for generating color code as well as method and system for analyzing color code
CN102147873A
Color bar code, code determining method and code determining system
CN110188854A
