CN113988104A - Method and device for decoding bar code, scanning equipment and storage medium - Google Patents

Method and device for decoding bar code, scanning equipment and storage medium Download PDF

Info

Publication number
CN113988104A
CN113988104A CN202111611733.5A CN202111611733A CN113988104A CN 113988104 A CN113988104 A CN 113988104A CN 202111611733 A CN202111611733 A CN 202111611733A CN 113988104 A CN113988104 A CN 113988104A
Authority
CN
China
Prior art keywords
decoded
chip
code
decoding
image
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
CN202111611733.5A
Other languages
Chinese (zh)
Other versions
CN113988104B (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.)
Beijing Unigroup Tsingteng Microsystems Co Ltd
Original Assignee
Beijing Unigroup Tsingteng Microsystems 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 Beijing Unigroup Tsingteng Microsystems Co Ltd filed Critical Beijing Unigroup Tsingteng Microsystems Co Ltd
Priority to CN202111611733.5A priority Critical patent/CN113988104B/en
Publication of CN113988104A publication Critical patent/CN113988104A/en
Application granted granted Critical
Publication of CN113988104B publication Critical patent/CN113988104B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K7/00Methods or arrangements for sensing record carriers, e.g. for reading patterns
    • G06K7/10Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation
    • G06K7/10544Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation by scanning of the records by radiation in the optical part of the electromagnetic spectrum
    • G06K7/10821Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation by scanning of the records by radiation in the optical part of the electromagnetic spectrum further details of bar or optical code scanning devices
    • G06K7/1098Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation by scanning of the records by radiation in the optical part of the electromagnetic spectrum further details of bar or optical code scanning devices the scanning arrangement having a modular construction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K7/00Methods or arrangements for sensing record carriers, e.g. for reading patterns
    • G06K7/10Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation
    • G06K7/14Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation using light without selection of wavelength, e.g. sensing reflected white light
    • G06K7/1404Methods for optical code recognition
    • G06K7/1408Methods for optical code recognition the method being specifically adapted for the type of code
    • G06K7/14131D bar codes

Landscapes

  • Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Electromagnetism (AREA)
  • Health & Medical Sciences (AREA)
  • General Health & Medical Sciences (AREA)
  • Toxicology (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The application relates to the technical field of bar codes and discloses a method for decoding bar codes, which is applied to scanning equipment, wherein the scanning equipment is provided with a plurality of chips, and each chip corresponds to a chip code; coding the chip into a chip with preset codes as a main chip; each chip is used for decoding the bar code; the method for decoding the bar code comprises the following steps: the main chip acquires the code system number and the total number of chips of the bar code to be decoded; determining chips to be decoded in each chip by the main chip according to the number of the code systems and the total number of the chips; the main chip acquires an image to be decoded containing a bar code to be decoded by using the chip to be decoded and decodes the bar code to be decoded in the image to be decoded. The chips to be decoded are determined in the chips by the main chip, so that the main chip can acquire the images to be decoded by using the chips to be decoded and decode the bar codes to be decoded in the images in parallel, and the decoding efficiency is improved. The application also discloses a device, scanning equipment and a storage medium for decoding the bar code.

Description

Method and device for decoding bar code, scanning equipment and storage medium
Technical Field
The present application relates to the field of barcode technologies, and for example, to a method and an apparatus for barcode decoding, a scanning device, and a storage medium.
Background
At present, bar codes are graphic symbols used for representing various data information, and bar code identification equipment is acquisition and conversion equipment which is specially used for restoring the graphic symbols into the data information. Barcode identification technology has been developed for many years, and barcode identification devices are rapidly becoming popular in many industries and applications. At present, image type bar code scanning devices are more and more on the market to adapt to bar code scanning reading and decoding under various application environments, for example, a patent with publication number CN201725346U discloses a serial bus type bar code decoding chip and a bar code decoding device, a patent with publication number CN101833639A discloses a bar code decoding device supporting multi-program parallel processing, a patent with publication number CN101840492A discloses a bar code decoding device supporting multi-code system parallel processing, a patent with publication number CN201859457U discloses a bar code decoding chip, a patent with publication number CN105654004A discloses a method and a chip for intelligently gating bar code decoding, at least dozens of bar code systems, along with the increase of the bar code systems supported by the scanning devices, the time required by the scanning devices to execute decoding algorithms is longer and longer, under the background of the demand of pursuing more code systems and excellent code scanning performance, the decoding efficiency of scanning devices is increasingly not meeting the requirements of users.
In the process of implementing the embodiments of the present disclosure, it is found that at least the following problems exist in the related art: when the scanning device adopting the multi-core chip performs decoding, resources stored in the random access memory need to be shared through the bus, so that under the condition that one core occupies the bus, other cores can only wait, and the decoding efficiency is low.
Disclosure of Invention
The following presents a simplified summary in order to provide a basic understanding of some aspects of the disclosed embodiments. This summary is not an extensive overview nor is intended to identify key/critical elements or to delineate the scope of such embodiments but rather as a prelude to the more detailed description that is presented later.
The embodiment of the disclosure provides a method and a device for decoding bar codes, scanning equipment and a storage medium, so as to improve the decoding efficiency under the condition of decoding bar codes of a plurality of code systems.
In some embodiments, the method is applied to a scanning device, wherein the scanning device is provided with a plurality of chips, and each chip corresponds to a chip code; coding the chip into a chip with preset codes as a main chip; each chip is used for decoding a bar code, and the method for decoding the bar code comprises the following steps: the main chip acquires the code system number and the total number of chips of the bar code to be decoded; determining a chip to be decoded in each chip by the main chip according to the number of the code systems and the total number of the chips; and the main chip acquires the image to be decoded containing the bar code to be decoded by using the chip to be decoded and decodes the bar code to be decoded in the image to be decoded.
In some embodiments, the means for barcode decoding comprises: a processor and a memory storing program instructions, the processor being configured to, upon execution of the program instructions, perform the method for barcode decoding described above.
In some embodiments, the scanning device comprises: the device for decoding the bar code is described above.
In some embodiments, the storage medium stores program instructions that, when executed, perform the method for barcode decoding described above.
The barcode decoding method and device, the scanning device and the storage medium provided by the embodiment of the disclosure can achieve the following technical effects: the code system quantity and the chip total quantity of the bar code to be decoded are obtained through the main chip, the main chip determines the chip to be decoded in each chip according to the code system quantity and the chip total quantity, the main chip can obtain the image to be decoded containing the bar code to be decoded by utilizing the chip to be decoded and decode the bar code to be decoded in the image to be decoded, therefore, under the condition that a plurality of code systems and a plurality of chips are arranged, the image to be decoded does not need to be obtained through bus shared resources, each chip to be decoded can obtain the image to be decoded containing the bar code to be decoded and decode the bar code to be decoded in the image to be decoded in parallel, the decoding efficiency is improved, and the satisfaction degree of a user is improved.
The foregoing general description and the following description are exemplary and explanatory only and are not restrictive of the application.
Drawings
One or more embodiments are illustrated by way of example in the accompanying drawings, which correspond to the accompanying drawings and not in limitation thereof, in which elements having the same reference numeral designations are shown as like elements and not in limitation thereof, and wherein:
FIG. 1 is a schematic diagram of a method for barcode decoding provided by embodiments of the present disclosure;
FIG. 2 is a schematic diagram of another method for barcode decoding provided by embodiments of the present disclosure;
FIG. 3 is a schematic diagram of a scanning device provided by embodiments of the present disclosure;
FIG. 4 is a diagram illustrating a hardware structure of a scanning device according to an embodiment of the present disclosure;
FIG. 5 is a schematic diagram of a method for decoding with four chips according to an embodiment of the disclosure;
FIG. 6 is a schematic diagram of an apparatus for decoding barcodes according to an embodiment of the present disclosure.
Reference numerals:
1: a power management circuit module; 2: a chip; 2-1: a first chip; 2-2: a second chip; 2-3: a third chip; 2-n: an nth chip; 3: a camera module; 4: a light module; 5: a communication bus interface; 6: a code scanning control interface; 7: a first chip request interface; 8: a second chip request interface; 9: the n-1 th chip requests an interface.
Detailed Description
So that the manner in which the features and elements of the disclosed embodiments can be understood in detail, a more particular description of the disclosed embodiments, briefly summarized above, may be had by reference to the embodiments, some of which are illustrated in the appended drawings. In the following description of the technology, for purposes of explanation, numerous details are set forth in order to provide a thorough understanding of the disclosed embodiments. However, one or more embodiments may be practiced without these details. In other instances, well-known structures and devices may be shown in simplified form in order to simplify the drawing.
The terms "first," "second," and the like in the description and in the claims, and the above-described drawings of embodiments of the present disclosure, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It should be understood that the data so used may be interchanged under appropriate circumstances such that embodiments of the present disclosure described herein may be made. Furthermore, the terms "comprising" and "having," as well as any variations thereof, are intended to cover non-exclusive inclusions.
The term "plurality" means two or more unless otherwise specified.
In the embodiment of the present disclosure, the character "/" indicates that the preceding and following objects are in an or relationship. For example, A/B represents: a or B.
The term "and/or" is an associative relationship that describes objects, meaning that three relationships may exist. For example, a and/or B, represents: a or B, or A and B.
The term "correspond" may refer to an association or binding relationship, and a corresponds to B refers to an association or binding relationship between a and B.
Referring to fig. 1, an embodiment of the present disclosure provides a method for decoding a barcode, which is applied to a scanning device, where the scanning device is provided with a plurality of chips, and each chip corresponds to a chip code; coding the chip into a chip with preset codes as a main chip; each chip is used for decoding the bar code; the method for decoding the bar code comprises the following steps:
step S101, the main chip acquires the code system number and the total number of chips of the bar code to be decoded.
And S102, determining a chip to be decoded in each chip by the main chip according to the number of the code systems and the total number of the chips.
Step S103, the main chip acquires the image to be decoded containing the bar code to be decoded by using the chip to be decoded and decodes the bar code to be decoded in the image to be decoded.
By adopting the method for decoding the bar code provided by the embodiment of the disclosure, the code system number and the total number of chips of the bar code to be decoded are obtained through the main chip, and the main chip determines the chip to be decoded in each chip according to the code system number and the total number of chips, so that the main chip can obtain the image to be decoded containing the bar code to be decoded by utilizing the chip to be decoded and decode the bar code to be decoded in the image to be decoded, therefore, under the condition of having a plurality of code systems and a plurality of chips, the image to be decoded is obtained without sharing resources through a bus, each chip to be decoded can obtain the image to be decoded containing the bar code to be decoded and decode the bar code to be decoded in the image to be decoded in parallel, the decoding efficiency is improved, and the satisfaction degree of a user is improved.
Optionally, encoding the chip into a chip with a preset code as a main chip includes: and coding the chip into a first-bit coded chip as a main chip.
Optionally, the chip code corresponding to each chip is a fixed code.
Optionally, before the main chip obtains the number of code systems of the bar code to be decoded and the total number of chips, the method further includes: and under the condition of receiving a decoding starting instruction sent by a user, the main chip enters a decoding mode.
Optionally, when the main chip acquires the image to be decoded including the barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, the main chip triggers the chip to be decoded to enter a decoding mode.
Optionally, after the main chip acquires the image to be decoded including the barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, the method further includes: the main chip acquires decoding time; and under the condition that the decoding time is greater than the preset decoding time, the main chip triggers the chip to be decoded to stop decoding so as to exit the decoding mode. Optionally, the decoding time is an accumulated time after the main chip enters the decoding mode; optionally, the accumulated time after the main chip enters the decoding mode is obtained by a timer built in the scanning device.
Optionally, after the main chip acquires the image to be decoded including the barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, the method further includes: and under the condition that the main chip receives a decoding stopping instruction sent by a user, triggering the chip to be decoded to stop decoding so as to exit the decoding mode.
In some embodiments, the master chip outputs a low level through the code scanning control interface on the master chip to trigger the chip to be decoded to stop decoding so as to exit the decoding mode.
Optionally, the determining, by the master chip, the chip to be decoded in each chip according to the number of code systems and the total number of chips includes: the method comprises the steps that a main chip obtains a first code system code corresponding to a bar code to be decoded under the condition that the number of code systems is smaller than or equal to the total number of chips; and the main chip determines the chip corresponding to the chip code which is the same as the first code system code as the chip to be decoded. Therefore, under the condition that the number of the code systems is less than or equal to the total number of the chips, the main chip acquires the first code system codes corresponding to the bar codes to be decoded, and determines the chips corresponding to the chip codes which are the same as the first code system codes as the chips to be decoded, so that the chips to be decoded correspond to the code system codes corresponding to the bar codes to be decoded one by one, and under the condition that a plurality of code systems exist, the chips are utilized to the maximum extent, so that the chips to be decoded are selected to decode in parallel, the decoding efficiency is improved, and the satisfaction degree of a user is improved.
Optionally, the first code system code corresponding to the barcode to be decoded is obtained by: the main chip acquires a code system of a bar code to be decoded, which is input by a user; the main chip encodes the code system to obtain a first code system code.
Optionally, the first code system code corresponding to the barcode to be decoded is obtained by: the main chip acquires a code system of a bar code to be decoded, which is set by a user; the main chip encodes the code system to obtain a first code system code.
Optionally, encoding the code system to obtain a first code system code, including: and (3) coding the code system of the bar code to be decoded in sequence from 1 to obtain a first code system code.
Optionally, the main chip acquires an image to be decoded including a barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, including: the main chip takes the first code system code as a first code system code to be decoded and distributes the first code system code to the chip to be decoded; the main chip utilizes the chip to be decoded to acquire the image to be decoded containing the bar code to be decoded in parallel and decodes the bar code to be decoded corresponding to the first code system code in the image to be decoded. Therefore, the main chip distributes the first code system code to the chip to be decoded as the first code system code to be decoded, and utilizes the chip to be decoded to acquire the image to be decoded containing the bar code to be decoded in parallel and decode the bar code to be decoded corresponding to the first code system code in the image to be decoded, so that each chip to be decoded can acquire the image to be decoded containing the bar code to be decoded in parallel and decode the bar code corresponding to the first code system code in the distributed image to be decoded, and the decoding efficiency is improved.
Optionally, the allocating, by the master chip, the first code system code as the first code system code to be decoded to the chip to be decoded includes: and the main chip takes the first code system code as a first code system code to be decoded and distributes the first code system code to a chip to be decoded corresponding to the chip code which is the same as the first code system code to be decoded.
Optionally, the allocating, by the master chip, the first code system code as the first code system code to be decoded to the chip to be decoded includes: and the main chip distributes the first code system codes as first code system codes to be decoded to the chips to be decoded in sequence according to the size of the first code system codes. Therefore, each chip is only used for decoding the bar code of the code system corresponding to the first code system code to be decoded distributed, and decoding efficiency is improved.
In some embodiments, when the number of code systems is less than or equal to the total number of chips and the chips to be decoded are non-master chips, the master chip generates a decoding code system instruction corresponding to the first code system code to be decoded; the main chip sends a decoding code system instruction corresponding to the first code system code to be decoded to a chip to be decoded corresponding to the chip code same as the first code system code through the communication bus interface, and the main chip acquires an image to be decoded containing the bar code to be decoded in parallel by using the chip to be decoded and decodes the bar code to be decoded corresponding to the first code system code in the image to be decoded.
In some embodiments, the number of the code systems is 1, and the main chip is a chip to be decoded, so that the main chip directly utilizes the chip to be decoded to acquire an image to be decoded including a barcode to be decoded and decodes the barcode to be decoded in the image to be decoded.
Optionally, the main chip concurrently acquires an image to be decoded including a barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded corresponding to the first barcode to be decoded in the image to be decoded, including: the main chip utilizes the chip to be decoded to acquire the image to be decoded containing the bar code to be decoded in parallel and utilizes the decoding algorithm corresponding to the first code to be decoded code allocated to the image to be decoded to decode the bar code to be decoded corresponding to the first code to be decoded code in the image to be decoded.
Optionally, the main chip concurrently acquires the image to be decoded including the barcode to be decoded by using the chip to be decoded, including: and the main chip utilizes the chip to be decoded to parallelly acquire the image which is shot by the camera device and contains the bar code to be decoded. Optionally, the camera device comprises a camera.
Optionally, the main chip, after acquiring, in parallel, an image to be decoded including a barcode to be decoded by using the chip to be decoded and decoding the barcode to be decoded corresponding to the first barcode system code to be decoded in the image to be decoded, further includes: the main chip acquires the decoding condition of a chip to be decoded; when the decoding condition of any chip to be decoded is successful, the main chip triggers all chips to be decoded to stop decoding the bar code corresponding to the first code system code to be decoded; when the decoding condition of the chip to be decoded is decoding failure, the main chip allocates a first code system code to the chip to be decoded again; optionally, the value of the first to-be-decoded code system code is the same as the value of the chip code of the to-be-decoded chip.
In some embodiments, when the chip to be decoded is a non-master chip, the master chip determines that the decoding of the chip to be decoded is completed when receiving that the output of the request interface corresponding to the chip to be decoded is a high level. The main chip outputs an inquiry instruction to the chip to be decoded through the communication bus interface so as to acquire the decoding condition of the chip to be decoded. And under the condition that the decoding condition fed back by the chip to be decoded is successful, the main chip outputs low level to each chip to be decoded through the code scanning control interface so as to trigger all the chips to be decoded to stop decoding the bar code corresponding to the first code system code to be decoded. And under the condition that the decoding condition fed back by the chip to be decoded is decoding failure, the main chip allocates a first code system code to the chip to be decoded again, and acquires the image to be decoded containing the bar code to be decoded by using the chip to be decoded and decodes the bar code to be decoded in the image to be decoded.
Optionally, the master chip is connected in parallel with the other chips. Alternatively, the main chip controls other chips by changing the high potential or the low potential of the scan control level. Optionally, the main chip triggers a non-main chip in the chip to be decoded to enter a decoding mode by controlling the scanning code control level to be a high potential; the main chip controls the level to be a low potential by controlling the code scanning, triggers a non-main chip in the chip to be decoded to exit the decoding mode, and enters an idle state.
Referring to fig. 2, an embodiment of the present disclosure provides a method for decoding a barcode, which is applied to a scanning device, where the scanning device is provided with a plurality of chips, and each chip corresponds to a chip code; coding the chip into a chip with preset codes as a main chip; each chip is used for decoding the bar code; the method for decoding the bar code comprises the following steps:
step S201, the main chip acquires the code system number and the total number of chips of the bar code to be decoded.
Step S202, the main chip obtains a first code system code corresponding to the bar code to be decoded when the code system number is less than or equal to the total number of the chips.
Step S203, the main chip determines a chip corresponding to the chip code identical to the first code system code as a chip to be decoded.
And step S204, the main chip distributes the first code system code as a first code system code to be decoded to the chip to be decoded.
In step S205, the main chip concurrently obtains the image to be decoded including the barcode to be decoded by using the chip to be decoded, and decodes the barcode to be decoded corresponding to the first barcode to be decoded in the image to be decoded.
Thus, the code system number and the chip total number of the bar code to be decoded are obtained through the main chip, the main chip obtains a first code system code corresponding to the bar code to be decoded when the code system number is less than or equal to the chip total number, the main chip determines a chip corresponding to the chip code which is the same as the first code system code as the chip to be decoded, then the main chip distributes the first code system code as the first code system code to the chip to be decoded, and uses the chip to be decoded to obtain the image to be decoded containing the bar code to be decoded in parallel and decodes the bar code to be decoded corresponding to the first code system code in the image to be decoded, thereby enabling the main chip to determine the chip to be decoded in each chip and enabling the chip to be decoded to decode the bar code corresponding to the code system under the condition that the code system number is less than or equal to the chip total number, and maximally utilizing the chips, therefore, under the condition of having a plurality of code systems, a plurality of chips to be decoded can be selected to be decoded in parallel, so that the decoding efficiency is improved, and the satisfaction degree of a user is improved.
In some embodiments, the number of code systems is m, the total number of chips is n, and m is less than or equal to n. And under the condition that the main chip receives the code scanning instruction or the code scanning signal through the external interface, the main chip determines that a decoding starting instruction is received, and enters a decoding mode. The main chip acquires the code system quantity and the total quantity of chips of the bar code to be decoded. And the main chip determines the chips to be decoded in each chip according to the number of the code systems and the total number of the chips. The main chip determines a chip corresponding to a chip code identical to the first code system code as a chip to be decoded, namely, the chip with the chip codes from 1 to m is determined as a chip to be decoded, and the chip with the chip codes from m +1 to n is a chip not to be decoded, wherein the chip not to be decoded does not decode the bar code corresponding to the first code system code. The main chip outputs a code scanning control level as a high level through an output code scanning control interface, and triggers a non-main chip in the chip to be decoded to enter a decoding mode; and under the condition that the request level received by the master chip and sent by the non-master chip in the chips to be decoded is a high level, determining that the non-master chip in the chips to be decoded already enters a decoding mode. And the main chip distributes the first code system code as a first code system code to be decoded to the chip to be decoded through a communication bus. The main chip utilizes the chip to be decoded to parallelly acquire an image to be decoded containing a bar code to be decoded and decodes the bar code to be decoded corresponding to a first code to be decoded in the image to be decoded; and the value of the first code system code to be decoded is the same as the value of the chip code of the chip to be decoded. For example, the chip code of the chip to be decoded is 1, and the first code system to be decoded allocated to the chip to be decoded with the chip code of 1 is 1; the chip code of the chip to be decoded is 2, and the first code system code to be decoded allocated to the chip to be decoded with the chip code of 2 is 2. Under the condition that the chip to be decoded is a non-main chip, after the chip to be decoded finishes decoding, outputting a request level as a high level through a corresponding request interface; under the condition that the main chip receives a request level output by the chip to be decoded is a high level, the main chip sends an inquiry instruction to inquire the decoding condition of the chip to be decoded through the communication bus interface and triggers the chip to be decoded to reply the decoding condition; when the decoding condition received by the main chip is successful, the main chip outputs a code scanning control level to be a low level through a code scanning control interface, triggers the chip to be decoded to exit a decoding mode and enters an idle state; and the main chip reads the decoding result from the successfully decoded chip to be decoded and outputs the decoding result through the external interface. Under the condition that the decoding condition received by the main chip is decoding failure, a first code system code to be decoded is redistributed to the chip to be decoded; the main chip utilizes the chip to be decoded to acquire the image to be decoded containing the bar code to be decoded in parallel and decodes the bar code to be decoded corresponding to the first code system code in the image to be decoded. Under the condition that the chip to be decoded is a main chip, after the chip to be decoded is decoded successfully, the main chip outputs a code scanning control level to be a low level through a code scanning control interface, triggers a non-main chip in the chip to be decoded to exit a decoding mode and enters an idle state; the main chip outputs a decoding result through an external interface; the master chip exits the decode mode. Under the condition that the main chip receives a decoding stopping instruction, the main chip outputs a code scanning control level to be a low level through a code scanning control interface, triggers a non-main chip in the chip to be decoded to exit a decoding mode and enter an idle state, and finishes code scanning; the master chip exits the decode mode.
Optionally, the determining, by the master chip, the chip to be decoded in each chip according to the number of code systems and the total number of chips includes: under the condition that the number of the code systems is larger than the total number of the chips, the main chip determines each chip as a chip to be distributed; the main chip acquires a second code system code corresponding to the bar code to be decoded; and the main chip determines a chip to be decoded in the chips to be distributed according to the second code system code. Therefore, under the condition that the number of the code systems is larger than the total number of the chips, all the chips need to decode the bar codes to be decoded, the main chip determines each chip as the chip to be decoded, the chip to be decoded can be utilized to decode the bar codes to be decoded to the maximum utilization rate, and the decoding efficiency is improved.
Optionally, the obtaining, by the main chip, a second barcode corresponding to the barcode to be decoded includes: the main chip acquires a code system of a bar code to be decoded, which is input by a user; the main chip encodes the code system to obtain a second code system code.
Optionally, the obtaining, by the main chip, a second barcode corresponding to the barcode to be decoded includes: the main chip acquires a code system of a bar code to be decoded, which is set by a user; the main chip encodes the code system to obtain a second code system code.
Optionally, the determining, by the master chip, a chip to be decoded in the chips to be allocated according to the second code scheme code includes: and the main chip determines the chip to be distributed corresponding to the chip code which is the same as the second code system code as the chip to be decoded. Therefore, the chip to be distributed corresponding to the chip code which is the same as the second code system code is determined as the chip to be decoded by the main chip conveniently, the chip to be distributed and the second code system code to be decoded are in one-to-one correspondence, and each chip is utilized to the maximum extent and orderly, so that the decoding efficiency is improved, and the satisfaction degree of a user is improved.
Optionally, the main chip acquires an image to be decoded including a barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, including: the main chip distributes the second code system code as a second code system code to be decoded to the chip to be decoded; the main chip triggers a chip to be decoded to obtain the current decoding round number and the historical decoding round number; the historical decoding round number is the current decoding round number obtained when the chip to be decoded is decoded last time; the main chip triggers the chip to be decoded to acquire an image to be decoded containing a bar code to be decoded in parallel by using the chip to be decoded and decode the bar code to be decoded corresponding to a second code to be decoded in the image to be decoded under the condition that the current decoding round number is different from the historical decoding round number; optionally, the main chip sends the current decoding round number to the chip to be decoded, and triggers the chip to be decoded to receive the current decoding round number and obtain the historical decoding round number; optionally, the historical decoding round number is stored in the chip to be decoded. Therefore, the second code system code is distributed to the chip to be decoded as the second code system code to be decoded through the main chip, the chip to be decoded is triggered to obtain the current decoding round number and the historical decoding round number, and the chip to be decoded is triggered to use the chip to be decoded to obtain the image to be decoded containing the bar code to be decoded in parallel and decode the bar code to be decoded corresponding to the second code system code in the image to be decoded under the condition that the decoding round number is different from the historical decoding round number, so that the chip to be decoded can determine the method for obtaining the image to be decoded containing the bar code through the decoding round number, the chip to be decoded can be prevented from obtaining the wrong image to be decoded and decoding the wrong bar code, and the use experience of a user is improved. Meanwhile, the main chip triggers the chip to be decoded to automatically acquire the image containing the bar code through the number of decoding rounds without manual setting, so that the decoding efficiency is improved.
Optionally, the allocating, by the master chip, the second code system code as a second code system code to be decoded to the chip to be decoded includes: and the main chip distributes the second code system codes to be decoded to the chips to be decoded in sequence according to the size of the second code system codes. Therefore, each chip is only used for decoding the bar code of the code system corresponding to the second code system code to be decoded distributed, and decoding efficiency is improved.
Optionally, the main chip triggers the chip to be decoded to acquire the image including the barcode, which is shot by the camera device, under the condition that both the historical decoding round number and the current decoding round number are the preset initial decoding round number.
Optionally, the method for barcode decoding further comprises: the main chip triggers the chip to be decoded to acquire a historical decoding image and decode the bar code to be decoded in the historical decoding image under the condition that the current decoding round number is the same as the historical decoding round number; the historical decoded image is a decoded image obtained last time by a chip to be decoded. Therefore, the main chip triggers the chip to be decoded to acquire the decoded image acquired last time by the chip to be decoded and decode the bar code to be decoded in the decoded image under the condition that the current decoding round number is the same as the historical decoding round number, so that the chip to be decoded can determine the method for acquiring the image to be decoded containing the bar code through the decoding round number, thereby avoiding the chip to be decoded from acquiring the wrong image to be decoded and decoding the wrong bar code, and improving the use experience of a user. Meanwhile, the main chip triggers the chip to be decoded to automatically acquire the image containing the bar code through the number of decoding rounds without manual setting, so that the decoding efficiency is improved.
Optionally, after the main chip acquires the image to be decoded including the barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, the method further includes: the main chip acquires the decoding condition of a chip to be decoded; under the condition that the decoding condition of any chip to be decoded is successful, the main chip triggers all chips to be decoded to stop decoding the bar code corresponding to the second code system code to be decoded; when the decoding condition of any chip to be decoded is decoding failure, the main chip acquires the minimum unallocated second code system code to be decoded and allocates the minimum unallocated second code system code to the chip to be decoded which is decoding failure; and the main chip decodes the bar code corresponding to the second code system code to be decoded distributed by the main chip by using the chip to be decoded.
In some embodiments, the second coded encoding comprises: 1. 2, 3, 4 and 5. The chip code of the chip to be distributed comprises the following steps: 1. 2 and 3. And the main chip determines the chip to be allocated corresponding to the chip code which is the same as the second code system code as the chip to be decoded, and then determines the chip to be allocated with the chip code of 1, the chip code of 2 and the chip code of 3 as the chip to be decoded. Distributing the second code system code 1 as a second code system code to be decoded to a chip to be decoded with a chip code of 1; distributing the second code system code 2 as a second code system code to be decoded to a chip to be decoded with the chip code of 2; distributing the second code system code 3 as a second code system code to be decoded to a chip to be decoded with the chip code of 3; and the main chip decodes the bar code corresponding to the second code system code to be decoded distributed by each chip to be decoded. Under the condition that the decoding condition of any chip to be decoded is decoding failure, the main chip acquires the minimum unallocated second code system code to be decoded, namely a second code system code 4 to be decoded corresponding to the second code system code 4, and allocates the second code system code 4 to the chip to be decoded which is decoding failure; and the main chip decodes the bar code corresponding to the second code system code 4 to be decoded distributed by the chip to be decoded which fails to be decoded. Then, under the condition that the decoding condition of any chip to be decoded is decoding failure, the main chip acquires the minimum unassigned second code system code to be decoded, namely a second code system code 5 to be decoded corresponding to the second code system code 5, and assigns the second code system code 5 to be decoded to the chip to be decoded which is decoding failure; and the main chip decodes the bar code corresponding to the second code system code 5 to be decoded distributed by the chip to be decoded which fails in decoding.
Optionally, under the condition that all second to-be-decoded code system codes are distributed, the main chip adds 1 to the current decoding round number; and the main chip triggers the chip to be decoded to determine the current decoding round number as the historical decoding round number.
In some embodiments, the number of codes is m, the total number of chips is n, and m > n. And under the condition that the main chip receives the code scanning instruction or the code scanning signal through the external interface, the main chip determines that a decoding starting instruction is received, and enters a decoding mode. The main chip takes all chips as chips to be distributed; the main chip outputs a code scanning control level as a high level through an output code scanning control interface, and triggers each non-main chip to enter a decoding mode; and under the condition that the request level received by the master chip is high level, determining that each non-master chip enters a decoding mode. The main chip acquires a second code system code corresponding to the bar code to be decoded; the main chip determines a chip to be distributed corresponding to the chip code which is the same as the second code system code as a chip to be decoded; the main chip distributes the second code system code as a second code system code to be decoded to the chip to be decoded; the main chip acquires the current decoding round number and the historical decoding round number, sequentially allocates a second code system code to be decoded for the chip to be decoded through a communication bus, sends the current decoding round number, and triggers the chip to be decoded to receive the current decoding round number and acquire the historical decoding round number; under the condition that the main chip completes the distribution of the codes of each second code system to be decoded, the main chip automatically adds 1 to the current decoding round number; and the main chip triggers the chip to be decoded to determine the current decoding round number as the historical decoding round number. The main chip triggers the chip to be decoded to acquire a historical decoding image and decode the bar code to be decoded in the historical decoding image under the condition that the current decoding round number is the same as the historical decoding round number; the historical decoding image is a decoding image obtained by a chip to be decoded last time; and the main chip triggers the chip to be decoded to acquire the image to be decoded containing the bar code to be decoded in parallel by using the chip to be decoded and decode the bar code to be decoded corresponding to the second code to be decoded in the image to be decoded under the condition that the current decoding round number is different from the historical decoding round number. Under the condition that the chip to be decoded is a non-main chip, after the chip to be decoded finishes decoding, outputting a request level as a high level through a corresponding request interface; and under the condition that the output request level of the chip to be decoded received by the main chip is high level, the main chip sends an inquiry instruction to inquire the decoding condition of the chip to be decoded through the communication bus interface, and triggers the chip to be allocated to reply the decoding condition. When the decoding condition received by the main chip is decoding failure, the main chip acquires the minimum unallocated second code system code to be decoded and allocates the minimum unallocated second code system code to the chip to be decoded, which is failed in decoding; and the main chip decodes the bar code corresponding to the second code system code to be decoded distributed by the main chip by using the chip to be decoded. When the decoding condition received by the main chip is successful, the main chip outputs a code scanning control level to be a low level through a code scanning control interface, triggers the chip to be decoded to exit a decoding mode and enters an idle state; the main chip outputs a decoding result through an external interface; the master chip exits the decode mode. Under the condition that the main chip receives a decoding stopping instruction, the main chip outputs a code scanning control level to be a low level through a code scanning control interface, triggers a non-main chip in the chip to be decoded to exit a decoding mode, enters an idle state and finishes code scanning; the master chip exits the decode mode.
With reference to fig. 3, an embodiment of the present disclosure provides a scanning device, where the scanning device is provided with a plurality of chips; the chip code is that the chip of the preset code is the main chip, and other chips are non-main chips; the scanning device includes: power management circuit module 1, a plurality of chips 2, camera module 3 and light module 4. The power management circuit module 1 is configured to provide voltage for each chip 2, the camera module 3 and the light module 4; the camera module 3 is configured to be controlled by the main chip to acquire an image containing a bar code; the light module 4 comprises a light supplement lamp and a positioning lamp; the light module 4 is configured to be controlled by the main chip to assist the camera module in acquiring the decoded image. The light supplement lamp is configured to be controlled by the main chip to illuminate to obtain a bright and clear picture under the condition that the camera module scans codes and picks up the picture; the positioning lamp is configured to be controlled by the main chip to emit light spots with preset shapes and preset colors through illumination to indicate the central position of the shooting of the camera module; the preset shape comprises a word line or a dot and the like; the main chip comprises an external interface communication module, a light control module, an application configuration module, a chip communication module, a camera control module, an image acquisition module, a code system distribution module and a decoding module; wherein the external interface communication module is configured to realize communication with an external device; the light control module is configured to control the light module to assist the camera module in acquiring the decoded image; the application configuration module is configured to set application functions of the scanning device or a configuration thereof; the chip communication module is configured to communicate with other chips; the camera control module is configured to control the camera module to acquire an image containing a bar code; the image acquisition module is configured to acquire an image containing a bar code and shot by the camera module; the code system distribution module is configured to acquire the code system number and the total number of chips of the bar code to be decoded; determining chips to be decoded in each chip according to the number of the code systems and the total number of the chips; under the condition that the number of code systems is less than or equal to the total number of chips, acquiring a first code system code corresponding to a bar code to be decoded; determining a chip corresponding to the chip code which is the same as the first code system code as a chip to be decoded; distributing the first code system code as a first code system code to be decoded to a chip to be decoded; determining each chip as a chip to be distributed under the condition that the number of the code systems is greater than the total number of the chips; acquiring a second code system code corresponding to the bar code to be decoded; determining a chip to be decoded in the chips to be distributed according to the second code system code; distributing the second code system code as a second code system code to be decoded to a chip to be decoded; the decoding module is configured to decode the bar code to be decoded corresponding to the first code system code to be decoded or the second code system code to be decoded which is distributed to the decoding module. Optionally, setting an application function or a configuration thereof of the scanning device includes: setting with external communication protocols, setting of coded data format conversion, setting of data editing, and/or setting of decoding device configuration, etc. The main chip is also configured to be connected with other devices through the external interface module. The external interface comprises a power supply pin, a communication interface, a code scanning trigger pin, an indicator light control output module and a buzzer control output module; the communication interface may be one or more of a USB (Universal Serial Bus) interface and a UART (Universal Asynchronous Receiver/Transmitter) interface. Each non-main chip is configured to acquire a convex image acquired by the camera module; decoding the bar code to be decoded in the image by using a preset decoding algorithm, and communicating with the main chip through a plurality of interfaces; optionally, setting the application function or the configuration thereof includes: setting with external communication protocols, setting of coded data format conversion, setting of data editing, and/or setting of decoding device configuration, etc.
Optionally, each chip comprises an independent processor, an image acquisition module and a memory, so that each chip can acquire and store an image containing a bar code shot by the camera module, and the image of the bar code is acquired without waiting for the idle bus, thereby realizing parallel acquisition of the image, facilitating parallel decoding of the bar code in the image and improving decoding efficiency.
With reference to fig. 4, an embodiment of the present disclosure provides a hardware structure of a scanning device, where the scanning device is provided with a plurality of chips; the chip with the chip code of the first code is a main chip, and other chips are non-main chips; the hardware structure of the scanning device comprises: camera module 3, light module 4 and a plurality of chips. Optionally, the chips include a first chip 2-1, a second chip 2-2, a third chip 2-3 and an nth chip 2-n; wherein, the first chip 2-1 is a main chip. Optionally, the master chip includes a communication bus interface 5, a scan code control interface 6, and a chip request interface with each non-master chip. Optionally, each chip request interface includes: a first chip request interface 7, a second chip request interface 8 and an n-1 chip request interface 9. The first chip request interface 7 is used for communication between the first chip 2-1 and the second chip 2-2; the second chip request interface 8 is used for communication between the first chip 2-1 and the second chip 2-3; the n-1 chip request interface 9 is used for communication between the first chip 2-1 and the second chip 2-n; the main chip is connected with each non-main chip in parallel through a communication bus interface. The camera module 3 is configured to be controlled by the main chip to acquire an image containing a bar code; sending the collected images to each chip; the light module 4 is controlled by the main chip to assist the second camera module to collect images; the main chip is configured to control the camera module to collect an image containing a bar code; controlling a light module to assist a camera module to acquire an image; sending one or more of a decoding code system instruction corresponding to a first code system code to be decoded, a decoding code system instruction corresponding to a second code system code to be decoded, a current decoding round number and a historical decoding round number to each non-main chip through a communication bus interface; receiving a decoding result sent by a non-master chip which is successfully decoded through a communication bus interface; respectively receiving the high level output by each non-master chip through a first chip request interface, a second chip request interface or an n-1 chip request interface so as to determine that each non-master chip completes decoding; the non-master chip is configured to receive one or more of a decoding code system instruction corresponding to a first code system code to be decoded, a decoding code system instruction corresponding to a second code system code to be decoded, a current decoding round number and a historical decoding round number, which are sent by the master chip, through the communication bus interface; under the condition of successful decoding, sending a decoding result through a communication bus interface; acquiring an image containing a bar code acquired by a camera module; and under the condition that the decoding is completed, outputting a high level to the main chip through the first chip request interface, the second chip request interface or the n-1 chip request interface.
Optionally, each chip is a processing chip.
Optionally, the host chip configures and controls the camera using an I2C (Inter-Integrated Circuit) interface.
Optionally, each chip is connected in parallel with the camera module through an Interface such as an image dvp (digital Video port) Interface or an MIPI (Mobile Industry Processor Interface). In this way, the image collected by the camera module can be acquired by all chips.
Optionally, the main chip controls the light module through a GPIO (General Purpose Input/Output). Optionally, the chips are interconnected through a communication bus Interface, which includes but is not limited to SPI (Serial Peripheral Interface), I2C, and the like. Optionally, the master chip outputs the scan control level to each non-master chip through the scan control interface. Optionally, the code scanning control interface comprises a GPIO interface. Optionally, each non-master chip outputs a request level to the master chip through its corresponding chip request interface. Optionally, the chip request interface comprises a GPIO interface. Optionally, the main chip is connected to the other devices through an external interface, and optionally, the external interface includes a USB interface, a UART interface, a GPIO interface, or the like.
Fig. 5 is a schematic diagram of the decoding method using four chips according to this embodiment, as shown in fig. 5. The first chip is selected as a main chip, and the second chip, the third chip and the fourth chip are non-main chips. After the first chip allocates the code system to each core, in a fourth preset time period T1, the second chip, the third chip and the fourth chip of the first chip acquire the image acquired by the camera module in parallel, and decode the bar code to be decoded in the image in a fifth time period T2 until the decoding is completed. Because each chip can acquire images from the camera module and the resource of each chip is shared independently, the decoding process is completely carried out in parallel without waiting for the decoding of other chips to be finished, and the decoding efficiency is improved.
As shown in fig. 6, an embodiment of the present disclosure provides an apparatus for decoding a barcode, which includes a processor (processor) 600 and a memory (memory) 601. Optionally, the apparatus may also include a Communication Interface 602 and a bus 603. The processor 600, the communication interface 602, and the memory 601 may communicate with each other via a bus 603. The communication interface 602 may be used for information transfer. The processor 600 may invoke logic instructions in the memory 601 to perform the method for barcode decoding of the above-described embodiments.
By adopting the device for decoding the bar code provided by the embodiment of the disclosure, the code system number and the total number of chips of the bar code to be decoded are acquired through the main chip, and the main chip determines the chip to be decoded in each chip according to the code system number and the total number of chips, so that the main chip can acquire the image to be decoded containing the bar code to be decoded by utilizing the chip to be decoded and decode the bar code to be decoded in the image to be decoded, thereby acquiring the image to be decoded without sharing resources through a bus under the condition of a plurality of code systems and a plurality of chips, each chip to be decoded can acquire the image to be decoded containing the bar code to be decoded and decode the bar code to be decoded in the image to be decoded in parallel, improving the decoding efficiency and improving the satisfaction degree of a user.
In addition, the logic instructions in the memory 601 may be implemented in the form of software functional units and stored in a computer readable storage medium when the logic instructions are sold or used as independent products.
The memory 601 is a computer-readable storage medium, and can be used for storing software programs, computer-executable programs, such as program instructions/modules corresponding to the methods in the embodiments of the present disclosure. The processor 600 executes functional applications and data processing by executing program instructions/modules stored in the memory 601, i.e., implements the method for barcode decoding in the above-described embodiments.
The memory 601 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to the use of the terminal device, and the like. In addition, the memory 601 may include a high speed random access memory, and may also include a non-volatile memory.
The embodiment of the disclosure provides scanning equipment, which comprises the device for decoding the bar code.
By adopting the scanning device provided by the embodiment of the disclosure, the code system number and the chip total number of the bar code to be decoded are acquired through the main chip, and the main chip determines the chip to be decoded in each chip according to the code system number and the chip total number, so that the main chip can acquire the image to be decoded containing the bar code to be decoded by using the chip to be decoded and decode the bar code to be decoded in the image to be decoded, and under the condition that a plurality of code systems and a plurality of chips are provided, the image to be decoded is acquired without sharing resources through a bus, and each chip to be decoded can acquire the image to be decoded containing the bar code to be decoded and decode the bar code to be decoded in the image to be decoded in parallel, thereby improving the decoding efficiency and improving the satisfaction degree of a user.
Embodiments of the present disclosure provide a storage medium storing computer-executable instructions configured to perform the above-described method for barcode decoding.
Embodiments of the present disclosure provide a computer program product comprising a computer program stored on a computer readable storage medium, the computer program comprising program instructions which, when executed by a computer, cause the computer to perform the above-described method for barcode decoding.
The computer-readable storage medium described above may be a transitory computer-readable storage medium or a non-transitory computer-readable storage medium.
The technical solution of the embodiments of the present disclosure may be embodied in the form of a software product, where the computer software product is stored in a storage medium and includes one or more instructions to enable a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method of the embodiments of the present disclosure. And the aforementioned storage medium may be a non-transitory storage medium comprising: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes, and may also be a transient storage medium.
The above description and drawings sufficiently illustrate embodiments of the disclosure to enable those skilled in the art to practice them. Other embodiments may incorporate structural, logical, electrical, process, and other changes. The examples merely typify possible variations. Individual components and functions are optional unless explicitly required, and the sequence of operations may vary. Portions and features of some embodiments may be included in or substituted for those of others. Furthermore, the words used in the specification are words of description only and are not intended to limit the claims. As used in the description of the embodiments and the claims, the singular forms "a", "an" and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. Similarly, the term "and/or" as used in this application is meant to encompass any and all possible combinations of one or more of the associated listed. Furthermore, the terms "comprises" and/or "comprising," when used in this application, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof. Without further limitation, an element defined by the phrase "comprising an …" does not exclude the presence of other like elements in a process, method or apparatus that comprises the element. In this document, each embodiment may be described with emphasis on differences from other embodiments, and the same and similar parts between the respective embodiments may be referred to each other. For methods, products, etc. of the embodiment disclosures, reference may be made to the description of the method section for relevance if it corresponds to the method section of the embodiment disclosure.
Those of skill in the art would appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software may depend upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the disclosed embodiments. It can be clearly understood by the skilled person that, for convenience and brevity of description, the specific working processes of the system, the apparatus and the unit described above may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the embodiments disclosed herein, the disclosed methods, products (including but not limited to devices, apparatuses, etc.) may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units may be merely a logical division, and in actual implementation, there may be another division, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form. The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to implement the present embodiment. In addition, functional units in the embodiments of the present disclosure may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). In some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. In the description corresponding to the flowcharts and block diagrams in the figures, operations or steps corresponding to different blocks may also occur in different orders than disclosed in the description, and sometimes there is no specific order between the different operations or steps. For example, two sequential operations or steps may in fact be executed substantially concurrently, or they may sometimes be executed in the reverse order, depending upon the functionality involved. Each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented by special purpose hardware-based systems that perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.

Claims (10)

1. A method for decoding bar codes is applied to scanning equipment and is characterized in that the scanning equipment is provided with a plurality of chips, and each chip corresponds to a chip code; coding the chip into a chip with preset codes as a main chip; each chip is used for decoding the bar code; the method comprises the following steps:
the main chip acquires the code system number and the total number of chips of the bar code to be decoded;
determining a chip to be decoded in each chip by the main chip according to the number of the code systems and the total number of the chips;
and the main chip acquires the image to be decoded containing the bar code to be decoded by using the chip to be decoded and decodes the bar code to be decoded in the image to be decoded.
2. The method of claim 1, wherein determining, by a master chip, chips to be decoded among the chips according to the number of code systems and the total number of chips comprises:
the main chip acquires a first code system code corresponding to the bar code to be decoded under the condition that the code system number is less than or equal to the total number of the chips;
and the main chip determines the chip corresponding to the chip code which is the same as the first code system code as the chip to be decoded.
3. The method of claim 2, wherein the main chip acquires an image to be decoded containing a barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, comprising:
the main chip distributes the first code system code as a first code system code to be decoded to the chip to be decoded;
and the main chip utilizes the chip to be decoded to parallelly acquire an image to be decoded containing a bar code to be decoded and decodes the bar code to be decoded corresponding to the first code to be decoded in the image to be decoded.
4. The method of claim 1, wherein determining, by a master chip, chips to be decoded among the chips according to the number of code systems and the total number of chips comprises:
under the condition that the number of the code systems is larger than the total number of the chips, the main chip determines each chip as a chip to be distributed;
the main chip acquires a second code system code corresponding to the bar code to be decoded;
and the main chip determines a chip to be decoded in the chips to be distributed according to the second code system code.
5. The method of claim 4, wherein the master chip determines a chip to be decoded among the chips to be allocated according to the second code scheme code, comprising:
and the main chip determines the chip to be distributed corresponding to the chip code which is the same as the second code system code as the chip to be decoded.
6. The method according to claim 4 or 5, wherein the main chip acquires an image to be decoded containing a barcode to be decoded by using the chip to be decoded and decodes the barcode to be decoded in the image to be decoded, and the method comprises the following steps:
the main chip distributes the second code system code as a second code system code to be decoded to the chip to be decoded;
the main chip triggers a chip to be decoded to obtain the current decoding round number and the historical decoding round number; the historical decoding round number is the current decoding round number obtained when the chip to be decoded is decoded last time;
and triggering a chip to be decoded by the main chip under the condition that the current decoding round number is different from the historical decoding round number, and acquiring an image to be decoded containing a bar code to be decoded in parallel by using the chip to be decoded and decoding the bar code to be decoded corresponding to the second code to be decoded in the image to be decoded.
7. The method of claim 6, further comprising:
the main chip triggers a chip to be decoded to acquire a historical decoding image and decode a bar code to be decoded in the historical decoding image under the condition that the current decoding round number is the same as the historical decoding round number; and the historical decoded image is a decoded image obtained last time by the chip to be decoded.
8. An apparatus for barcode decoding comprising a processor and a memory storing program instructions, wherein the processor is configured to perform the method for barcode decoding of any one of claims 1 to 7 when executing the program instructions.
9. A scanning device comprising the apparatus for barcode decoding of claim 8.
10. A storage medium storing program instructions which, when executed, perform a method for barcode decoding according to any one of claims 1 to 7.
CN202111611733.5A 2021-12-27 2021-12-27 Method and device for decoding bar code, scanning equipment and storage medium Active CN113988104B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111611733.5A CN113988104B (en) 2021-12-27 2021-12-27 Method and device for decoding bar code, scanning equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111611733.5A CN113988104B (en) 2021-12-27 2021-12-27 Method and device for decoding bar code, scanning equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113988104A true CN113988104A (en) 2022-01-28
CN113988104B CN113988104B (en) 2022-04-19

Family

ID=79734536

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111611733.5A Active CN113988104B (en) 2021-12-27 2021-12-27 Method and device for decoding bar code, scanning equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113988104B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115860034A (en) * 2023-02-14 2023-03-28 北京紫光青藤微系统有限公司 Decoding method, decoding device, decoding chip and code scanning equipment

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101833641A (en) * 2010-06-01 2010-09-15 福建新大陆电脑股份有限公司 Bar code decoding chip
CN101882199A (en) * 2010-05-25 2010-11-10 福建新大陆电脑股份有限公司 Bus type bar code decoding chip
CN101882208A (en) * 2010-06-01 2010-11-10 福建新大陆电脑股份有限公司 Bar code decoding chip and bar code decoding device based on virtual interface
US20110290884A1 (en) * 2010-06-01 2011-12-01 Fujian Newland Computer Co., Ltd. Bar code decoding device
US20140027517A1 (en) * 2011-05-24 2014-01-30 Huizhou Tcl Mobile Communication Co., Ltd Mobile terminal and decoding method thereof
CN103559474A (en) * 2013-11-04 2014-02-05 福建新大陆自动识别技术有限公司 Bar code decoding device and method
CN104298953A (en) * 2014-10-27 2015-01-21 苏州睿新捷信息科技有限公司 Method and system for recognizing barcodes in batches
CN105654004A (en) * 2015-12-30 2016-06-08 福建联迪商用设备有限公司 Intelligent gating barcode decoding method and chip
CN109241806A (en) * 2018-08-10 2019-01-18 北京龙贝世纪科技股份有限公司 A kind of multi-code recognition methods and identifying system simultaneously

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101882199A (en) * 2010-05-25 2010-11-10 福建新大陆电脑股份有限公司 Bus type bar code decoding chip
CN101833641A (en) * 2010-06-01 2010-09-15 福建新大陆电脑股份有限公司 Bar code decoding chip
CN101882208A (en) * 2010-06-01 2010-11-10 福建新大陆电脑股份有限公司 Bar code decoding chip and bar code decoding device based on virtual interface
US20110290884A1 (en) * 2010-06-01 2011-12-01 Fujian Newland Computer Co., Ltd. Bar code decoding device
US20140027517A1 (en) * 2011-05-24 2014-01-30 Huizhou Tcl Mobile Communication Co., Ltd Mobile terminal and decoding method thereof
CN103559474A (en) * 2013-11-04 2014-02-05 福建新大陆自动识别技术有限公司 Bar code decoding device and method
CN104298953A (en) * 2014-10-27 2015-01-21 苏州睿新捷信息科技有限公司 Method and system for recognizing barcodes in batches
CN105654004A (en) * 2015-12-30 2016-06-08 福建联迪商用设备有限公司 Intelligent gating barcode decoding method and chip
CN109241806A (en) * 2018-08-10 2019-01-18 北京龙贝世纪科技股份有限公司 A kind of multi-code recognition methods and identifying system simultaneously

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
刘峰: "一种基于虚拟NAND闪存接口的条码解码芯片及设备的设计方案", 《福建电脑》 *
耿艳鹏: "基于MIPI接口的双通道并行解码方案研究", 《通讯世界》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115860034A (en) * 2023-02-14 2023-03-28 北京紫光青藤微系统有限公司 Decoding method, decoding device, decoding chip and code scanning equipment

Also Published As

Publication number Publication date
CN113988104B (en) 2022-04-19

Similar Documents

Publication Publication Date Title
US9087250B2 (en) Cell phone reading mode using image timer
CN107292808B (en) Image processing method and device and image coprocessor
CN1773474B (en) Sharing single host controller with multiple functional devices
CN113988104B (en) Method and device for decoding bar code, scanning equipment and storage medium
CN104971499B (en) Game providing server
US8482754B2 (en) Providing a plurality of processing units for an image forming apparatus
CN104270740B (en) A kind of detection method of neck T cards and SIM card altogether
CN104715218A (en) Network card-reading terminal for resident identification cards
CN114145006A (en) Scheduling method and device of artificial intelligence resources, storage medium and chip
WO2020083019A1 (en) Decoding method based on multi-core processor, terminal device and storage medium
CN106533976B (en) data packet processing method and device
CN113709495B (en) Synchronous decoding method based on PCIE buffer mechanism
CN112506828A (en) Transmission configuration method and device for direct memory access
JPH01278173A (en) Image reader
CN112434800A (en) Control device and brain-like computing system
US10867363B2 (en) Device and method for accelerating graphics processor units, and computer readable storage medium
CN107124575A (en) A kind of media processing method, device and media server
CN114513380B (en) Method and device for controlling household electrical appliance, household electrical appliance and storage medium
WO2015038154A1 (en) Grouping and compressing similar photos
CN115801102A (en) Method, device and storage medium for downlink data
US3461432A (en) Bi-directional code converter
CN112615739B (en) Method and system for adapting OCP3.0 network card in multi-host application environment
CN114125456A (en) Data processing method and system and electronic equipment
CN112292672A (en) Switching control method, electronic equipment and computer readable storage medium
CN116501507B (en) Method for interrupt processing, interrupt control module, processor, and storage medium

Legal Events

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