Intelligent detection method and system for the number of certificates
By designing intelligent detection methods and systems for certificate quantity, using components such as lifting motors, lifting rods, photoelectric switches, cameras and suction cups, the problem of difficult to automatically calculate the number and change amounts of certificates in the certificate warehouse is solved, and the efficiency and convenience of automatic verification of certificates is achieved.
Patent Information
- Application Number
- CN202411488131.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-24
- Publication Date
- 2025-03-04
- Estimated Expiration
- 2044-10-24
AI Technical Summary
The existing automatic verification device for certificates is difficult to automatically calculate the number of documents and the number of documents in the certificate warehouse, which leads to the inability to promptly know the number and changes of documents in the certificate warehouse during the inspection process.
An intelligent detection method and system for the amount of documents is designed, using components such as lifting motors, hoisting rods, photoelectric switches, cameras and suction cups to detect the current of the lifting motor in real time, calculate the number of running steps, collect the ID image for character recognition, and rotate the ID bin so that the ridge side of the ID bin is facing the preset direction. The suction cup is used to absorb the last ID to calculate the remaining ID in the ID bin.
The number of documents and the number of documents in the certificate warehouse is automatically calculated to ensure that the document inspection device can promptly know the number and changes of documents in the certificate warehouse, so as to automatically control whether the claw hand continues to grab the documents, which will help the smooth completion of automatic document inspection.
Smart Images

Figure CN119027951B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of automatic certificate inspection, and more specifically, to an intelligent certificate quantity detection method and detection system. Background Art
[0002] In some public places, it is necessary to check the passenger's documents, and the checking process includes operations such as turning pages of documents, stamping, document information recognition, and document labeling. In order to achieve high efficiency, intelligence, and convenience in document checking, an automatic document checking device can be used to check documents, for example, a multi-station document checking device shown in the patent with publication number CN118097091A can be used to automatically check documents. The multi-station document checking device can check multiple documents, and multiple documents are placed in the document bin during the inspection. However, since the documents in the document bin are grabbed one by one by the claw hand to the tray assembly, the number of documents put in at the beginning and the change in the amount of documents in the document bin during the grabbing process can be known during the automatic document checking process, so that the multi-station document checking device can automatically know whether it is necessary to continue to drive the claw hand to work. Summary of the invention
[0003] In view of the existing technology, the technical problem solved by this application is to provide an intelligent detection method and detection system for the number of certificates, which can automatically calculate the number of certificates in the certificate warehouse and the change in the certificates in the certificate warehouse, so that the number of certificates in the certificate warehouse can be known at any time when the subsequent certificate inspection device is working, which helps to smoothly complete the automated inspection of certificates.
[0004] In order to solve the above technical problems, in the first aspect, the present application provides an intelligent method for detecting the amount of documents, which is used in a document quantity detection system, and the document quantity detection system includes a support seat, a first photoelectric switch arranged on the support seat, a lifting motor arranged on the support seat, a document bin arranged above and below the support seat and having an opening, and a lifting rod connected to the lifting motor, the lifting motor is used to drive the lifting rod to penetrate into the document bin to drive the stacked documents in the document bin to move toward the opening, the lifting rod is provided with a first photoelectric baffle moving therewith, and when the lifting rod is located at an initial low position away from the document bin, the first photoelectric baffle blocks the light beam of the photoelectric switch, including:
[0005] The current of the lifting motor is detected in real time using a current sampling circuit connected to the control module;
[0006] When the first photoelectric switch connected to the control module is at a low level, the number of operation steps Step1 of the lifting motor driven by the control module at this moment is obtained;
[0007] When the current of the lifting motor reaches the stall current, the number of operation steps of the lifting motor driven by the control module at this moment, Step 2, is obtained;
[0008] Calculate the total number of certificates N1 in the certificate warehouse according to the number of operation steps Step1 and the number of operation steps Step2;
[0009] Use the camera to collect the top certificate Cer of the N1 certificates exposed by the opening top Image of the ID card;
[0010] Perform character recognition on the document image, and obtain the rotation angle θ of the rotating motor driven by the control module based on the character recognition result. The rotating motor drives the document bin to rotate so that the document Cer top The ridgeline side of the device faces a predetermined orientation; and
[0011] The suction cup connected to the control module at the opening is used to suck the topmost document and calculate the remaining number of documents N2 in the document bin: N2=N1-1.
[0012] In a possible implementation, the total number of documents N1 in the document bin is calculated based on the number of operation steps Step1 and the number of operation steps Step2, which is: N1 = H1÷H3, H1 = H2-D, D1 = Step1×d, D2 = Step2×d, D = D2-D1; wherein H1 is the height of the documents stacked in the current document bin, H3 is the thickness of each document, H2 is the thickness of the document bin, D is the stroke difference between the positions of the lifting rod when it moves from the initial low position to the position when the lifting motor generates a stall current, D1 is the total stroke distance of the lifting rod movement at the initial low position at this moment, and D2 is the total stroke distance of the lifting rod movement at this moment when the lifting motor generates a stall current.
[0013] In a possible implementation, when the certificate is placed in the certificate compartment, the opening exposes the character content on the top certificate, and the certificate has identification characters F1 and F2 with positional continuity, wherein the identification characters F1 and F2 are arranged in sequence from the spine side of the certificate to the page opening side; character recognition is performed on the certificate image, and the rotation angle θ of the rotary motor driven by the control module is obtained based on the character recognition result, including:
[0014] Establish the image coordinate system with the upper left corner of the image as the origin O;
[0015] Perform character recognition on the document image to obtain a detection box Box1 of the identification character F1 and a detection box Box2 of the identification character F2 in the document image;
[0016] Based on the center point O of the detection box Box1 F1 Coordinates and the center point O of the detection box Box2 F2 Coordinates, determine the arrangement of the identification characters F1 and F2 along the X-axis and the Y-axis, and calculate the rotation angle θ according to the arrangement.
[0017] In a possible implementation, the preset position is located on the side of the negative Y-axis of the X-axis of the image coordinate system, and the arrangement of the identification characters F1 and F2 along the X-axis and the Y-axis is determined, and the rotation angle θ is calculated according to the arrangement, which is:
[0018] When the center point O F1 The vertical coordinate and center point O F2 If the absolute value of the difference between the vertical coordinates of is greater than the set threshold T, the identification character F1 and the identification character F2 are arranged vertically along the Y axis;
[0019] When the center point O F1 The horizontal coordinate and center point O F2 If the absolute value of the difference between the horizontal coordinates of is greater than the set threshold T, the identification character F1 and the identification character F2 are arranged horizontally along the X-axis;
[0020] When arranged vertically, if the center point O F1 The vertical coordinate is less than the center point O F The vertical coordinate of the top certificate is oriented to the preset direction and the rotation angle θ is 0 degrees. If the center point O F1 The vertical coordinate is greater than the center point O F The vertical coordinate of , the rotation angle θ is 180 degrees along the first direction or the second direction;
[0021] When arranged horizontally, if the center point O F1 The horizontal coordinate y F1 Smaller than the center point O F The horizontal coordinate of the center point O is θ, and the rotation angle θ is 90 degrees along the first direction; if the center point O F1 The horizontal coordinate is greater than the center point O F The horizontal coordinate of , the rotation angle θ is 90 degrees along the second direction;
[0022] The first direction and the second direction are opposite directions to each other.
[0023] In a second aspect, the present application also provides a system for detecting the number of certificates, which includes:
[0024] Support seat;
[0025] The certificate module comprises a certificate bin arranged above and below the rotary motor and the support base and driven to rotate by the rotary motor, wherein an opening is formed on a side of the certificate bin away from the support base;
[0026] A lifting module, comprising a lifting motor installed on the support seat and a lifting rod connected to the lifting motor, wherein the lifting motor is used to drive the lifting rod to move in and out of the document bin to push the document in the document bin to the opening;
[0027] A suction cup disposed at the opening, used to suck up the certificate at the opening;
[0028] A first photoelectric switch disposed on the support seat and a first photoelectric baffle disposed on the lifting rod, wherein when the lifting motor drives the lifting rod to move away from the document bin to an initial low position, the photoelectric baffle blocks the light beam emitted by the photoelectric switch;
[0029] A main control module and a current sampling circuit, wherein the main control module is connected to the current sampling circuit, the suction cup, the first photoelectric switch, the lifting motor and the rotating motor, the main control module is used to control the rotation direction and the number of operation steps of the lifting motor and the rotating motor, and the current sampling circuit is used to collect the current of the lifting motor;
[0030] a camera connected to the main control module, wherein the camera and the suction cup are located on a side of the document compartment having an opening; and
[0031] The computing unit is connected to the main control module and is used to execute the above-mentioned intelligent detection method for the number of certificates to obtain the remaining number in the certificate warehouse.
[0032] In a possible implementation, the document balance detection system also includes a motor driver chip; the first photoelectric switch is connected to one of the I / O pins of the main control module; the other three I / O pins of the main control module are respectively connected to the step input pin, direction input pin and enable input pin of the motor driver chip, the bridge A output pin of the motor driver chip is connected to one of the windings of the lifting motor, and the bridge B output pin of the motor driver chip is connected to the other winding of the lifting motor; the current sampling circuit is connected to another I / O pin of the main control module and is connected to the bridge A current setting reference input pin, the bridge B current setting reference input pin and the voltage stabilization output pin of the motor driver chip.
[0033] In a possible implementation, the current sampling circuit includes a reference power supply circuit, a sampling resistor, a differential amplifier, a low-pass filter circuit and a current limiting reference voltage circuit; the reference power supply circuit is connected to a first power supply and a reference input pin REF of the differential amplifier; two ends of the sampling resistor are respectively connected to a grounded negative input pin IN- of the differential amplifier and a positive input pin IN+ connected to the current limiting reference voltage circuit; the current limiting reference voltage circuit is connected to a bridge A current setting reference input pin, a bridge B current setting reference input pin and a voltage stabilization output pin of the motor drive chip; the low-pass filter circuit is connected to an output pin OUT of the differential amplifier and an I / O pin of the main control module; a power pin VS of the differential amplifier is connected to a second power supply and is grounded through a first capacitor.
[0034] In a possible implementation, the reference power supply circuit includes a first resistor and a second resistor and a second capacitor connected in parallel to each other; one end of the second resistor and the second capacitor connected in parallel is connected to the reference input pin REF of the differential amplifier and one end of the first resistor, the other end of the second resistor and the second capacitor connected in parallel is grounded, and the other end of the first resistor is connected to the first power supply.
[0035] In one possible implementation, the low-pass filter circuit includes a third resistor and a third capacitor; one end of the third capacitor is grounded, the other end of the third capacitor is connected to one end of the third resistor and to an I / O pin of the main control module, and the other end of the third resistor is connected to the output pin OUT of the differential amplifier.
[0036] In one possible implementation, the current limiting reference voltage circuit includes a variable resistor and a fourth capacitor; the two fixed terminals of the variable resistor are respectively connected to the voltage stabilization output pin of the motor driver chip and the positive input pin IN+ of the differential amplifier, and the variable terminal of the variable resistor is connected to the bridge A current setting reference input pin and the bridge B current setting reference input pin of the motor driver chip; the two ends of the fourth capacitor are respectively connected to the two fixed terminals of the variable resistor.
[0037] The effective effect of the intelligent detection method and detection system of the number of certificates provided by the present application is: the number of certificates in the certificate bin is calculated by the number of steps of the lifting motor that drives the lifting rod to move when the lifting rod is in the initial low position and the number of steps when the lifting motor current reaches the stall current value when the lifting rod is in the high position. After judging that the spine side of the top certificate faces the preset position to wait for the suction cup, when the suction cup sucks the top certificate, the certificate in the certificate bin changes, so that the remaining amount after the change in the certificate bin can be obtained. It can automatically calculate the number of certificates in the certificate bin and the amount of change of certificates in the certificate bin, so that the number of certificates in the certificate bin can be known at any time when the subsequent certificate inspection device is working, and the certificate inspection device can automatically know the changes of certificates in the certificate bin, so that it can automatically control whether the claw hand needs to continue to grab the certificates in the certificate bin, which is conducive to the smooth completion of the automatic inspection of certificates. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0039] Figure 1This is a structural diagram of the document module, lifting module, support base and gripper of the document quantity detection system of an embodiment of the present application.
[0040] Figure 2 This is a structural block diagram of the components connected to the main control module of the certificate quantity detection system in an embodiment of the present application.
[0041] Figure 3 This is a connection structure diagram of the certificate module and the connection module of an embodiment of the present application.
[0042] Figure 4 This is a flow chart of the intelligent method for detecting the number of certificates according to an embodiment of the present application.
[0043] Figure 5 This is a circuit diagram of a motor driver chip according to an embodiment of the present application.
[0044] Figure 6 is a circuit diagram of a current sampling circuit according to an embodiment of the present application.
[0045] Figure 7 This is a circuit diagram of the main control module of an embodiment of the present application.
[0046] Figure 8 This is a schematic diagram of the lifting rod of an embodiment of the present application moving from an initial low position to a high position.
[0047] Fig. 9 This is a schematic diagram of the top certificate in an embodiment of the present application with the spine side facing the preset position when the identification characters are arranged vertically.
[0048] Fig.10 This is a schematic diagram of the spine side of the top certificate in the embodiment of the present application being arranged vertically with respect to the preset position.
[0049] Fig.11 This is a schematic diagram showing that the spine side orientation of the identification characters of the top certificate of the embodiment of the present application is 90 degrees different from the preset position when the spine side orientation is horizontally arranged.
[0050] Fig.12 This is another schematic diagram of the top certificate in the embodiment of the present application, in which the identification characters of the top certificate are arranged horizontally and the spine side direction is 90 degrees different from the preset position.
[0051] Fig.13 This is a schematic diagram of the spine side and open pages of the certificate of an embodiment of the present application. DETAILED DESCRIPTION
[0052] In order to make the technical problems, technical solutions and beneficial effects to be solved by the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0053] It should be noted that when an element is referred to as being "fixed to" or "disposed on" another element, it can be directly on the other element or indirectly on the other element. When an element is referred to as being "connected to" another element, it can be directly connected to the other element or indirectly connected to the other element.
[0054] It should be understood that the terms "length", "width", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inside", "outside", etc., indicating the orientation or position relationship, are based on the orientation or position relationship shown in the drawings, and are only for the convenience of describing the present application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as a limitation on the present application.
[0055] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of the features. In the description of this application, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0056] The intelligent detection method and detection system of the certificate quantity of the present application will now be described in detail with reference to the accompanying drawings.
[0057] Please refer to Figures 1 to 3 The document quantity detection system provided in the embodiment of the present application includes a support base 10, a document module 20, a lifting module 30, a suction cup 40, a main control module, a current sampling circuit, a camera 50 and a computing unit.
[0058] Specifically, the document module 20 includes a rotating motor 21 and a document bin 22. The document bin 22 is arranged above and below the support base 10 and is driven to rotate by the rotating motor 21. An opening 221 is provided on the side of the document bin 22 away from the support base 10. The lifting module 30 includes a lifting motor 31 installed on the support base 10 and a lifting rod 32 connected to the lifting motor 31. The lifting motor 31 is used to drive the lifting rod 32 to enter and exit the document bin 22 to push the document in the document bin 22 to the opening 221. The suction cup 40 is arranged at the opening 221 and is used to suck up the document at the opening 221. The support base 10 is also provided with a first photoelectric switch 11 and the lifting rod 32 is provided with a first photoelectric baffle 321. When the lifting motor 31 drives the lifting rod 32 to move away from the document bin 22 to the initial low position, the first photoelectric baffle 321 blocks the light beam emitted by the first photoelectric switch 11. The main control module is connected to the current sampling circuit, the suction cup 40, the first photoelectric switch 11, the lifting motor 31, the rotating motor 21 and the camera 50. The main control module is used to control the rotation direction and the number of steps of the lifting motor 31 and the rotation direction and the number of steps of the rotating motor 21. The current sampling circuit is used to collect the current of the lifting motor 31. The camera 50 is connected to the main control module and is located with the suction cup 40 on the side of the document compartment 22 with the opening 221, that is, the camera 50 and the suction cup 40 are located above the document compartment 22 at the same time, and the collection surface of the camera 50 is arranged toward the opening 221, and is used to collect the documents in the document compartment.
[0059] Among them, the document bin 22 is designed to only allow multiple documents to be placed in a stacked form. When the lifting motor 31 drives the lifting rod 32 to penetrate into the document bin 22 and lift the multiple documents in the document bin 22 to the opening 221, the opening 221 of the document bin 22 will expose the top document. Then, when the camera 50 is used to collect the document image, the image of the top document is obtained. The operation unit is connected to the main control module, so the operation unit can achieve communication connection with other components of the document quantity detection system. The operation unit can obtain the image collected by the camera 50, the signal of the first photoelectric switch 11, the state of the lifting motor 31, and the state of the lifting motor 31, wherein the state of each motor includes the number of running steps and the running direction at each moment; the operation unit is used to implement the intelligent detection method of the document quantity of the document bin 22 to obtain the remaining number in the document bin 22. The specific implementation process of the intelligent detection method of the document quantity is as follows.
[0060] It is worth noting that multiple certificates are stacked and placed in the certificate bin 22. Due to gravity, multiple certificates are stacked and placed at the bottom of the certificate bin 22. The lifting motor 31 can drive the lifting rod 32 to move up and down relative to the certificate bin 22. The initial low position can be understood as the initial position when the lifting rod 32 has not entered, that is, the lifting rod 32 is far away from the lowest position of the certificate bin 22. The initial low position is designed in advance. When the lifting rod 32 is at the initial low position, the photoelectric baffle on the lifting rod 32 just blocks the light beam of the photoelectric switch on the support seat 10; when the lifting motor 31 drives the lifting rod 32 to move upward from the initial low position, the photoelectric baffle does not block the light beam of the photoelectric switch. The lifting rod 32 enters the document bin 22 and one end thereof abuts against the document in the document bin 22. As the lifting rod 32 moves upward, the document is driven to move upward. The opening 221 is arranged above the document bin 22. When the top document among the multiple documents moves to the topmost position of the document bin 22, due to the blocking effect of the bin wall of the document bin 22, the lifting motor 31 continues to rotate to drive the lifting rod 32 to move upward, and the document in the document bin 22 cannot continue to move upward. At this time, due to the external force blocking effect of the bin wall of the document bin 22, the lifting motor 31 has a similar stall phenomenon. At this time, the current of the lifting motor 31 suddenly changes compared with the normal rotation. The sudden change in current is called blocking current. When the lifting motor 31 generates blocking current, it means that the lifting motor 31 has driven the lifting rod 32 to rise to the highest position. The lifting rod 32 can no longer drive the document to continue to move upward. At this time, the lifting motor 31 stops rotating. At this point, the suction cup 40 sucks the top document among the multiple documents at the opening 221.
[0061] Please refer to Figure 4 The method for intelligently detecting the number of certificates includes the following steps S100 to S700:
[0062] Step S100: using a current sampling circuit connected to the control module to detect the current of the lifting motor in real time;
[0063] Step S200: when the first photoelectric switch connected to the control module is at a low level, obtaining the operation step number Step1 of the lifting motor driven by the control module at this moment;
[0064] Step S300: when the current of the lifting motor reaches the stall current, obtaining the number of operation steps Step2 of the lifting motor driven by the control module at this moment;
[0065] Step S400: Calculate the total number N1 of certificates in the certificate bin according to the number of operation steps Step 1 and the number of operation steps Step 2;
[0066] Step S500: Using a camera to capture the topmost certificate Cer among the N1 certificates exposed by the opening top Image of the ID card;
[0067] Step S600: Perform character recognition on the document image, obtain the rotation angle θ of the rotating motor driven by the control module based on the character recognition result, and drive the document bin to rotate by the rotating motor so that the document Cer top The ridgeline side of the device faces a preset orientation;
[0068] Step S700: Use the suction cup 40 located at the opening and connected to the control module to suck the topmost document, and calculate the remaining number of documents N2 in the document bin: N2=N1-1.
[0069] Refer to Figures 5 to 7 The document balance detection system also includes a motor driver chip U1, which is connected to the main control module U3, the winding of the lifting motor and the current sampling circuit. The main control module U3 controls the rotation direction and the number of operation steps of the lifting motor through the motor driver chip U1, and the current sampling circuit is used to collect the current of the lifting motor.
[0070] Understandably, the current sampling circuit can collect the current of the lifting motor at any time, and can know when the motor is blocked and generates a blocking current. The number of documents currently lifted by the lifting rod can be known by controlling the number of steps of the lifting motor through the main control module U3 and the motor driver chip U1 and the current sampling circuit. Specifically, after the lifting rod and the lifting motor are designed, the distance of the lifting rod movement is known when the lifting motor moves for each step. Assume that the distance of the lifting rod movement is d when the lifting motor rotates for each step. The lifting rod moves from the initial low position to the high position for a driving stroke, and the high position is understood as the position where the lifting rod drives the document to move when the lifting motor is blocked and generates a blocking current. The main control module U3 controls the number of steps of the lifting motor, so the number of steps of the lifting motor at every moment is also known, so the number of steps of the lifting motor at the current moment when the lifting rod is in the initial low position is known, and the current number of steps of the lifting motor when the lifting rod moves to the high position and the lifting motor is blocked and generates a blocking current is also known. Among them, at the initial low position, when the first photoelectric baffle blocks the light beam of the first photoelectric switch, the first photoelectric switch generates a low-level signal and feeds back to the main control module; the stall current can be understood as a sudden change in current threshold.
[0071] like Figure 8As shown, assuming that in a driving stroke, the number of steps of the lifting motor at the current moment when the lifting rod is in the initial low position is Step1, and the current number of steps of the lifting motor when the lifting rod moves to the high position and the lifting motor is blocked and generates a blocking current is Step2, then the total stroke distance D1 corresponding to the lifting rod at the initial low position is: D1= Step1×d, and the total stroke distance D2 corresponding to the lifting rod at the high position is: D2= Step2×d, then in this driving stroke, the stroke difference D of the lifting rod from the initial low position to the high position is: D= D2-D1, and the height occupied by all the stacked documents in the document bin is H1=H2-D, where H2 is the height of the document bin, and the height direction is the length in the direction of movement of the lifting rod. After the document bin is designed, the height H2 of the document bin can be known and determined. In a fixed inspection location, the same type of documents are usually inspected, so the thickness of each document is known, which is the length of the document along the moving direction of the lifting rod after it is placed in the document bin. Assuming that the thickness of each document is H3, the current number of documents N in the document bin is: N=H1÷H3. When the value of D÷H3 is a decimal, rounding can be adopted; after the lifting rod drives all the documents to move to the high position, the suction cup 40 will absorb the last document, and then the lifting motor will drive the lifting rod back to the initial low position.
[0072] The main control module U3 can be a main control chip of model ATMEGA328, and the motor driver chip U1 can be a motor driver chip U1 of model DRV8825. The photoelectric switch is connected to one of the I / O pins PC5 of the main control module U3. The other three I / O pins of the main control module U3 are respectively connected to the step input pin, direction input pin and enable input pin of the motor driver chip U1. Specifically, the I / O pin PD4, I / O pin PD5 and I / O pin PD6 of the main control module U3 are respectively connected to the enable input pin nENBL, direction input pin DIR and step input pin STEP of the motor driver chip U1. The bridge A output pin A of the motor driver chip U1 is connected to one of the windings of the lifting motor, specifically, the bridge A output pin AOUT1 and the bridge A output pin AOUT2 of the motor driver chip U1 are connected to the two ends of one of the windings of the lifting motor; the bridge B output pin of the motor driver chip U1 is connected to the other winding of the lifting motor, specifically, the bridge A output pin BOUT1 and the bridge A output pin BOUT2 of the motor driver chip U1 are connected to the two ends of the other winding of the lifting motor. In this way, the main control module U3 controls the rotation direction and operation steps of the lifting motor through the output signals of the I / O pins PD5 and PD6.
[0073] Further Figures 5 to 7As shown, the current sampling circuit is connected to another I / O pin PC0 of the main control module U3 and is connected to the bridge A current setting reference input pin AVREF, the bridge B current setting reference input pin BVREF and the regulated voltage output pin V3P3OUT of the motor driver chip U1.
[0074] Specifically, the current sampling circuit includes a reference power supply circuit, a sampling resistor R6, a differential amplifier U2, a low-pass filter circuit and a current-limiting reference voltage circuit. The reference power supply circuit is connected to the first power supply and the reference input pin REF of the differential amplifier U2. One end of the sampling resistor R6 is connected to the grounded negative input pin IN- of the differential amplifier U2 and the other end of the sampling resistor R6 is connected to the positive input pin IN+ connected to the current-limiting reference voltage circuit. The current-limiting reference voltage circuit is connected to the bridge A current setting reference input pin AVREF, the bridge B current setting reference input pin BVREF and the voltage-stabilizing output pin V3P3OUT of the motor driver chip U1. The low-pass filter circuit is connected to the output pin OUT of the differential amplifier U2 and the I / O pin PC0 of the main control module U3. In addition, the power pin VS of the differential amplifier U2 is connected to the second power supply and is grounded through the first capacitor. In this way, the main control module U3 collects the working current of the lifting motor at all times through the current sampling circuit.
[0075] Further Figures 5 to 7 As shown, the reference power supply circuit includes a first resistor R8 and a second resistor R9 and a second capacitor connected in parallel with each other. Specifically, one end of the second resistor R9 and the second capacitor C7 connected in parallel is connected to the reference input pin REF of the differential amplifier U2 and one end of the first resistor R8, the other end of the second resistor R9 and the second capacitor C7 connected in parallel is grounded, and the other end of the first resistor R8 is connected to the first power supply.
[0076] Further Figures 5 to 7 As shown, the low-pass filter circuit includes a third resistor R12 and a third capacitor. Specifically, one end of the third capacitor is grounded, the other end of the third capacitor is connected to one end of the third resistor R12 and to an I / O pin PC0 of the main control module U3, and the other end of the third resistor R12 is connected to the output pin OUT of the differential amplifier U2.
[0077] Further Figures 5 to 7As shown, the current limiting reference voltage circuit includes a variable resistor R4 and a fourth capacitor C5. Specifically, the two fixed terminals of the variable resistor R4 are respectively connected to the voltage stabilization output pin of the motor driver chip U1 and the positive input pin IN+ of the differential amplifier U2, and the variable terminal of the variable resistor R4 is connected to the bridge A current setting reference input pin and the bridge B current setting reference input pin of the motor driver chip U1; the two ends of the fourth capacitor C5 are respectively connected to the two fixed terminals of the variable resistor R4.
[0078] For certificates, their covers generally have identifying characters indicating the certificate type, the country or region to which the certificate belongs, etc., i.e., the aforementioned identification characters. Character recognition is performed on the certificate image of the top certificate in step S500. Since there are multiple certificates placed in the certificate bin, the top certificate is the certificate farthest from the lifting rod. The top certificate is the certificate exposed by the opening among all the certificates lifted by the lifting rod; the characters include but are not limited to words, graphics, numbers, operation symbols, punctuation marks, patterns, etc., and the character recognition method involved in step S600 can be any recognition algorithm in the prior art. It is understandable that when a certificate inspection device is used to inspect a certificate, the same certificate inspection device generally inspects the same type of certificates, that is, multiple certificates stacked up and down in the certificate compartment are the same type of certificates. For the same type of certificates, there must be multiple identical identification characters on the certificate cover, that is, there are two identification characters with position continuity. Position continuity refers to two identification characters that are close to each other in position. The two identification characters can be marked as identification characters F1 and identification characters F2, such as Figures 9 to 13 As shown; when the documents are placed in the document compartment, all the documents can be placed with the same side facing upward, that is, facing the opening. For example, the front side of all the documents can be placed facing the opening. In this way, for all the documents, the identification characters F1 and F2 are the same. Furthermore, the identification characters F1 and F2 are arranged in sequence from the spine side of the document to the open page side. The spine side refers to the side of the document that is bound and connected, and the open page side is the side of the document that can be opened by turning the pages. The spine side and the open page side are as shown in FIG. Fig.12 The opening of the document compartment is designed such that after the document is turned into the document compartment, the identification characters F1 and F2 with continuous positions can be exposed through the opening.
[0079] As mentioned above, in step S400, when the lifting rod lifts the documents in the document bin, while monitoring the current of the lifting motor, the main control module U3 controls the number of operation steps of the lifting motor when the lifting rod is in the initial low position and the number of operation steps of the lifting motor when the lifting rod is in the high position, and calculates the total number N1 in the document bin. The number N1 is the number of documents in the document bin at this moment. However, in the process of document inspection, it is also necessary to calculate the change in the documents in the document bin, that is, when the last document Cer top The ridge side of the certificate is facing the preset direction, and then the main control module U3 will control the suction cup 40 to absorb the top certificate Cer top The suction cup 40 is a vacuum suction cup 40. When the suction cup 40 sucks up a document, the pressure inside the suction cup 40 will change. At this time, the main control module U3 of the document remaining detection system can know that the suction cup 40 has sucked up a document. At this time, the number of documents in the document warehouse decreases by one.
[0080] It is worth noting that the document balance detection system further includes a gripper 60 located on one side of the document compartment, and the gripper 60 is located on the same side of the upper and lower suction cups 40 and the document side. top , because the certificate Cer sucked by the suction cup 40 top Due to the effect of gravity, the claw hand 60 set on one side of the document compartment can smoothly grasp the document Cer top Grab the document inspection device and place it on the tray assembly. top When the claw hand 60 grabs the document with its spine side facing, the preset orientation of the document spine in step S600 is the same as the side of the document bin on which the claw hand 60 grabs the document.
[0081] In one embodiment, referring to Figures 9 to 12 For step S600, character recognition is performed on the document image, and the rotation angle θ of the rotating motor driven by the control module is obtained based on the character recognition result, including the following steps S610 to S630.
[0082] Step S610: Establish an image coordinate system with the upper left corner of the image as the origin O, wherein the established image coordinate system is as follows: Figures 9 to 12 shown.
[0083] Step S620: Perform character recognition on the document image to obtain a detection box Box1 for the identification character F1 and a detection box Box2 for the identification character F2 in the document image; the character recognition method for the document image adopts any existing recognition algorithm, and outputs the detection box of each character after recognition.
[0084] Step S630: Based on the center point O of the detection box Box1 F1Coordinates and the center point O of the detection box Box2 F2 Coordinates, determine the arrangement of the identification characters F1 and F2 along the X-axis and the Y-axis, and calculate the rotation angle θ according to the arrangement.
[0085] Further, when the aforementioned preset position is located on the side indicated by the negative direction of the Y axis of the X axis of the image coordinate system, the implementation process of step S630 specifically includes the following steps:
[0086] When the center point O F1 The vertical coordinate and center point O F2 If the absolute value of the difference between the vertical coordinates of is greater than the set threshold T, the identification character F1 and the identification character F2 are arranged vertically along the Y axis;
[0087] When the center point O F1 The horizontal coordinate and center point O F2 If the absolute value of the difference between the horizontal coordinates of is greater than the set threshold T, the identification character F1 and the identification character F2 are arranged horizontally along the X-axis;
[0088] When arranged vertically, if the center point O F1 The vertical coordinate is less than the center point O F The vertical coordinate of the top certificate is oriented to the preset direction and the rotation angle θ is 0 degrees. If the center point O F1 The vertical coordinate is greater than the center point O F The vertical coordinate of , the rotation angle θ is 180 degrees along the first direction or the second direction;
[0089] When arranged horizontally, if the center point O F1 The horizontal coordinate is smaller than the center point O F The horizontal coordinate of the center point O is θ, and the rotation angle θ is 90 degrees along the first direction; if the center point O F1 The horizontal coordinate is greater than the center point O F The horizontal coordinate of , the rotation angle θ is 90 degrees along the second direction;
[0090] The first direction and the second direction are opposite directions to each other.
[0091] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application should be included in the protection scope of the present application.
Claims
1. A method for intelligently detecting the number of certificates, which is used in a certificate number detection system, characterized in that: The document quantity detection system includes a support base, a first photoelectric switch arranged on the support base, a lifting motor arranged on the support base, a document bin arranged above and below the support base and having an opening, and a lifting rod connected to the lifting motor, the lifting motor is used to drive the lifting rod to penetrate into the document bin to drive the stacked documents in the document bin to move toward the opening, the lifting rod is provided with a first photoelectric baffle moving with the lifting rod, and when the lifting rod is located at an initial low position away from the document bin, the first photoelectric baffle blocks the light beam of the first photoelectric switch, including: The current of the lifting motor is detected in real time using a current sampling circuit connected to the control module; When the first photoelectric switch connected to the control module is at a low level, the number of operation steps Step1 of the lifting motor driven by the control module at this moment is obtained; When the current of the lifting motor reaches the stall current, the number of operation steps of the lifting motor driven by the control module at this moment, Step 2, is obtained; Calculate the total number of certificates N1 in the certificate warehouse according to the number of operation steps Step1 and the number of operation steps Step2; Use the camera to collect the top certificate Cer of the N1 certificates exposed by the opening top Image of the ID card; Perform character recognition on the document image, and obtain the rotation angle θ of the rotating motor driven by the control module based on the character recognition result. The rotating motor drives the document bin to rotate so that the document Cer top The ridgeline side of the device faces a predetermined orientation; and Use the suction cup connected to the control module at the opening to suck up the top certificate, and calculate the remaining number of certificates N2 in the certificate bin: N2=N1-1; The total number of certificates N1 in the certificate bin is calculated according to the number of operation steps Step1 and Step2, which is: N1 = H1÷H3, H1 = H2-D, D1 = Step1×d, D2 = Step2×d, D = D2-D1; wherein H1 is the height of the certificates stacked in the current certificate bin, H3 is the thickness of each certificate, H2 is the thickness of the certificate bin, D is the stroke difference between the positions of the lifting rod moving from the initial low position to the position when the lifting motor generates a stall current, D1 is the total stroke distance of the lifting rod moving at the initial low position at this moment, D2 is the total stroke distance of the lifting rod moving at this moment when the lifting motor generates a stall current, and d is the stroke distance of the lifting rod moving when the lifting motor rotates one step.
2. The method for intelligently detecting the number of certificates as claimed in claim 1, characterized in that: When the certificate is placed in the certificate compartment, the opening exposes the character content on the last certificate, and the certificate has identification characters F1 and F2 with positional continuity, wherein the identification characters F1 and F2 are arranged in sequence from the spine side of the certificate to the page opening side; character recognition is performed on the certificate image, and the rotation angle θ of the rotary motor driven by the control module is obtained based on the character recognition result, including: Establish the image coordinate system with the upper left corner of the image as the origin O; Perform character recognition on the document image to obtain a detection box Box1 of the identification character F1 and a detection box Box2 of the identification character F2 in the document image; Based on the center point O of the detection box Box1 F1 Coordinates and the center point O of the detection box Box2 F2 Coordinates, determine the arrangement of the identification characters F1 and F2 along the X-axis and the Y-axis, and calculate the rotation angle θ according to the arrangement.
3. The method for intelligently detecting the number of certificates as claimed in claim 2, characterized in that: The preset position is located on the side indicated by the positive direction of the X axis and the negative direction of the Y axis of the image coordinate system, and the arrangement of the identification characters F1 and F2 along the X axis and the Y axis is determined, and the rotation angle θ is calculated according to the arrangement, which is: When the center point O F1 The vertical coordinate and center point O F2 If the absolute value of the difference between the vertical coordinates of is greater than the set threshold T, the identification character F1 and the identification character F2 are arranged vertically along the Y axis; When the center point O F1 The horizontal coordinate and center point O F2 If the absolute value of the difference between the horizontal coordinates of is greater than the set threshold T, the identification character F1 and the identification character F2 are arranged horizontally along the X-axis; When arranged vertically, if the center point O F1 The ordinate is greater than the center point O F2 The vertical coordinate of the top certificate is oriented to the preset direction and the rotation angle θ is 0 degrees. If the center point O F1 The vertical coordinate is less than the center point O F2 The vertical coordinate of , the rotation angle θ is 180 degrees along the first direction or the second direction; When arranged horizontally, if the center point O F1 The horizontal coordinate is smaller than the center point O F2 The horizontal coordinate of the center point O is θ, and the rotation angle θ is 90 degrees along the first direction; if the center point O F1 The horizontal coordinate is greater than the center point O F2 The horizontal coordinate of , the rotation angle θ is 90 degrees along the second direction; The first direction and the second direction are opposite directions to each other.
4. A system for detecting the number of certificates, characterized in that: include: Support seat; The certificate module comprises a certificate compartment which is arranged above and below the rotating motor and driven to rotate by the rotating motor, and an opening is formed on a side of the certificate compartment away from the supporting base; A lifting module, comprising a lifting motor installed on the support seat and a lifting rod connected to the lifting motor, wherein the lifting motor is used to drive the lifting rod to move in and out of the document bin to push the document in the document bin into the opening; A suction cup disposed in the opening, used to suck up the document in the opening; A first photoelectric switch disposed on the support seat and a first photoelectric baffle disposed on the lifting rod, wherein when the lifting motor drives the lifting rod to move away from the document bin to an initial low position, the first photoelectric baffle blocks the light beam emitted by the first photoelectric switch; A main control module and a current sampling circuit, wherein the main control module is connected to the current sampling circuit, the suction cup, the first photoelectric switch, the lifting motor and the rotating motor, the main control module is used to control the rotation direction and the number of operation steps of the lifting motor and the rotating motor, and the current sampling circuit is used to collect the current of the lifting motor; A camera connected to the main control module, wherein the camera and the suction cup are located on a side of the document compartment having an opening; as well as The computing unit is connected to the main control module and is used to execute the intelligent detection method for the number of certificates as described in any one of claims 1 to 3 to obtain the remaining number in the certificate warehouse.
5. The document quantity detection system as claimed in claim 4, characterized in that: The document quantity detection system also includes a motor driver chip; the first photoelectric switch is connected to one of the I / O pins of the main control module; the other three I / O pins of the main control module are respectively connected to the step input pin, direction input pin and enable input pin of the motor driver chip, the bridge A output pin of the motor driver chip is connected to one of the windings of the lifting motor, and the bridge B output pin of the motor driver chip is connected to the other winding of the lifting motor; the current sampling circuit is connected to another I / O pin of the main control module and is connected to the bridge A current setting reference input pin, the bridge B current setting reference input pin and the voltage stabilization output pin of the motor driver chip.
6. The document quantity detection system according to claim 5, characterized in that: The current sampling circuit includes a reference power supply circuit, a sampling resistor, a differential amplifier, a low-pass filter circuit and a current-limiting reference voltage circuit; the reference power supply circuit is connected to a first power supply and a reference input pin REF of the differential amplifier; two ends of the sampling resistor are respectively connected to a grounded negative input pin IN- of the differential amplifier and a positive input pin IN+ connected to the current-limiting reference voltage circuit; the current-limiting reference voltage circuit is connected to a bridge A current setting reference input pin, a bridge B current setting reference input pin and a voltage stabilization output pin of the motor drive chip; the low-pass filter circuit is connected to an output pin OUT of the differential amplifier and an I / O pin of the main control module; a power pin VS of the differential amplifier is connected to a second power supply and is grounded through a first capacitor.
7. The document quantity detection system according to claim 6, characterized in that: The reference power supply circuit includes a first resistor and a second resistor and a second capacitor connected in parallel to each other; one end of the second resistor and the second capacitor connected in parallel is connected to the reference input pin REF of the differential amplifier and one end of the first resistor, the other end of the second resistor and the second capacitor connected in parallel is grounded, and the other end of the first resistor is connected to the first power supply.
8. The document quantity detection system according to claim 6, characterized in that: The low-pass filter circuit includes a third resistor and a third capacitor; one end of the third capacitor is grounded, the other end of the third capacitor is connected to one end of the third resistor and to an I / O pin of the main control module, and the other end of the third resistor is connected to the output pin OUT of the differential amplifier.
9. The system for detecting the number of certificates as claimed in claim 6, characterized in that: The current limiting reference voltage circuit includes a variable resistor and a fourth capacitor; the two fixed terminals of the variable resistor are respectively connected to the voltage stabilization output pin of the motor driver chip and the positive input pin IN+ of the differential amplifier, and the variable terminal of the variable resistor is connected to the bridge A current setting reference input pin and the bridge B current setting reference input pin of the motor driver chip; the two ends of the fourth capacitor are respectively connected to the two fixed terminals of the variable resistor.
Citation Information
Patent Citations
Automatic identification and adjustment mechanism and automatic identification and adjustment method
CN118083535A
Multi-station certificate checking device and checking method
CN118097091A