A line body count detection method, device and electronic equipment

By setting the calibration benchmark and time base difference detection on the online body, the efficiency and accuracy problems of counting detection on the high-speed detection pipeline were solved, and stable correction of product counting was achieved, thus improving detection efficiency and accuracy.

CN115238849BActive Publication Date: 2026-06-26LCFC HEFEI ELECTRONICS TECH

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
LCFC HEFEI ELECTRONICS TECH
Filing Date
2022-07-20
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

On high-speed inspection lines, counting and detecting the same product suffers from low efficiency and insufficient accuracy. In particular, due to the instability of information and the influence of external factors at different inspection stations, the counting is prone to deviation and errors are difficult to detect in a timely manner.

Method used

By determining the motion time from the first sensor to the adjacent second sensor on the production line as the calibration benchmark, the time base difference of the sensor-collected products is calculated. Based on the difference, counting errors are detected and count corrections are performed, including resetting or restoring the correct count.

Benefits of technology

This improves the efficiency and accuracy of the line's counting and detection of the same product, ensures the stability and consistency of product counting, and reduces detection errors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115238849B_ABST
    Figure CN115238849B_ABST
Patent Text Reader

Abstract

The application provides a line body count detection method and device and electronic equipment; the method comprises the following steps: determining a fixed value of a movement time of a line body from a first sensor to a second sensor adjacent to the first sensor as a verification reference; determining a first time base of a first product collected by the first sensor and a second time base of the first product collected by the second sensor; determining a time base difference value of the first time base and the second time base; and detecting whether an error occurs in the count of the first product based on a difference value between the time base difference value and the verification reference. The line body count detection method provided by the application can improve the efficiency and accuracy of line body count detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of production line counting and detection, and in particular to a production line counting and detection method, apparatus and electronic equipment. Background Technology

[0002] Currently, when independent units in a high-speed inspection line count and inspect the same product, errors often fail to be detected promptly due to instability of information and the influence of external factors, leading to discrepancies in the counting of the same product at different inspection stations. Therefore, improving the efficiency and accuracy of the line's counting and inspection of the same product is crucial to improving the overall efficiency and accuracy of the line's product inspection. Summary of the Invention

[0003] This application provides a method, apparatus, and electronic device for counting and detecting production lines, which can improve the efficiency and accuracy of counting and detecting the same product on the production line.

[0004] The technical solution of this application embodiment is implemented as follows:

[0005] In a first aspect, embodiments of this application provide a line counting detection method, including:

[0006] A fixed value is set for the motion time from the first sensor to the adjacent second sensor on the line as the verification benchmark;

[0007] Determine a first time base for the first sensor to collect data on the first product and determine a second time base for the second sensor to collect data on the first product;

[0008] Determine the time base difference between the first time base and the second time base;

[0009] The system detects whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark.

[0010] In the above scheme, the step of detecting whether the counting of the first product has an error based on the difference between the time base difference and the verification benchmark includes:

[0011] If the difference between the time base difference and the verification benchmark is greater than the time threshold, it is determined that the counting of the first product has been incorrect.

[0012] If the difference between the time base difference and the verification benchmark is less than or equal to the time threshold, then it is determined that the counting of the first product has not been erroneous.

[0013] In the above scheme, after detecting whether the counting of the first product has an error based on the difference between the time base difference and the verification benchmark, the method includes:

[0014] If the counting of the first product is incorrect, the counting of the first product is corrected based on the first count of the first product at the first sensor and the first time base, and the second count of the first product at the second sensor and the second time base.

[0015] In the above scheme, the count correction of the first product includes:

[0016] Determine the N time bases corresponding to the N products before the first product reaches the second sensor;

[0017] The correct count of the first product is determined based on the N differences between the second time base and the N time bases respectively; where N is an integer greater than 2.

[0018] In the above scheme, determining the correct count of the first product based on the N differences between the second time base and the N time bases includes:

[0019] If none of the N differences are within the preset threshold, it is determined that the counting of the first product is abnormal, and abnormal processing is performed on the first sensor or the second sensor.

[0020] If one of the N differences is within a preset threshold, then the target count is determined based on the target time base corresponding to the target difference, and the second count is restored to the target count.

[0021] In the above scheme, the line counting detection method further includes:

[0022] If the line contains at least three sensors, then the time base of the first product and the calibration benchmark are counted and detected based on every two adjacent sensors.

[0023] In the above scheme, if the line body includes at least three sensors, then after counting and detecting the time base of the first product and the verification benchmark based on every two adjacent sensors, the method includes:

[0024] If at least one of the first sensor and the second sensor on the production line makes an error in counting the first product, then the counts of all sensors on the production line are reset to zero.

[0025] Secondly, embodiments of this application provide a thread counting and detection device, the thread counting and detection device comprising:

[0026] The calibration benchmark determination module is used to determine a fixed value for the motion time from the first sensor to the adjacent second sensor on the line as the calibration benchmark.

[0027] The time base determination module is used to determine the first time base for the first sensor to collect data on the first product and to determine the second time base for the second sensor to collect data on the first product.

[0028] A time base difference determination module is used to determine the time base difference between the first time base and the second time base;

[0029] The counting detection module is used to detect whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark.

[0030] Thirdly, embodiments of this application provide an electronic device, the electronic device comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to execute the line counting detection method provided in embodiments of this application.

[0031] Fourthly, embodiments of this application provide a computer-readable storage medium, the storage medium including a set of computer-executable instructions, which, when executed, are used to perform the line counting detection method provided in embodiments of this application.

[0032] The line counting detection method provided in this application establishes a fixed value for the movement time from a first sensor to an adjacent second sensor on the line as a calibration benchmark; determines a first time base for the first sensor to collect data on the first product and a second time base for the second sensor to collect data on the first product; determines the time base difference between the first and second time bases; and detects whether an error has occurred in the counting of the first product based on the difference between the time base difference and the calibration benchmark. This line counting detection method improves the efficiency and accuracy of product counting detection on the line, and is also applicable to lines containing multiple sets of detection sensors for counting the same product. Attached Figure Description

[0033] The accompanying drawings are provided to better understand this solution and do not constitute a limitation of this application. Wherein:

[0034] Figure 1 This is a schematic diagram of an optional processing flow of the line counting detection method provided in the embodiments of this application;

[0035] Figure 2 This is a schematic diagram of counting detection based on four counting sensors provided in an embodiment of this application;

[0036] Figure 3This is a schematic diagram of an optional processing flow of the line counting detection and correction method provided in the embodiments of this application;

[0037] Figure 4 This is a schematic diagram of counting detection based on two counting sensors provided in an embodiment of this application;

[0038] Figure 5 This is a flowchart illustrating the counting correction process performed by the two counting sensors in this application embodiment after a counting error occurs;

[0039] Figure 6 This is a flowchart illustrating the counting correction process performed by the four counting sensors in this application embodiment after a counting error occurs;

[0040] Figure 7 This is a schematic diagram of an optional device structure of the line counting and detection device provided in the embodiments of this application;

[0041] Figure 8 This is a block diagram of an electronic device for a line counting detection method provided in an embodiment of this application. Detailed Implementation

[0042] To make the objectives, technical solutions, and advantages of this application clearer, the application will be further described in detail below with reference to the accompanying drawings. The described embodiments should not be regarded as limitations on this application. All other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0043] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0044] In the following description, the terms "first" and "second" are used merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that "first" and "second" may be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.

[0045] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing embodiments of this application only and is not intended to limit this application.

[0046] Before providing a further detailed description of the embodiments of this application, the technical solutions involved in the embodiments of this application that address the existing technologies are described below:

[0047] 1. Directly using counting sensors at different workstations to count the same product is a method that cannot detect counting errors in the counting sensors at different workstations in a timely manner.

[0048] 2. Adding multiple sets of detection sensors between the counting sensors of adjacent workstations and cross-checking between multiple sets of detection sensors can detect counting errors in a timely manner, but it cannot reliably identify which workstation's counting sensor has made a counting error.

[0049] 3. When the counting sensor at a workstation makes a counting error, the counting error can be solved by clearing the wires and then resetting the zero. However, as the number of workstations increases and the counting error frequency increases, the system efficiency decreases accordingly. In severe cases, it can cause the counting sensor at the workstation to count erratically, resulting in a decline in the quality of the production line.

[0050] To address the problems existing in the aforementioned methods provided by related technologies, this application provides a line counting detection method, device, and electronic device that can detect whether counting sensors at different workstations have made errors in counting the same product, and when counting errors occur, correct the counting of the corresponding erroneous counting sensors, thereby improving the counting detection efficiency and accuracy of the line for the same product.

[0051] The following describes a counting detection method provided by an embodiment of this application. See also... Figure 1 , Figure 1 This is a schematic diagram of an optional processing flow of the counting detection method provided in the embodiments of this application. The following will be combined with... Figure 1 The steps S101-S104 shown are combined with Figure 2 Please provide an explanation.

[0052] Step S101: Determine a fixed value for the motion time from the first sensor to the adjacent second sensor on the line as a verification benchmark.

[0053] High-speed assembly line equipment in a factory can also be considered a production line. In some PC (Personal Computer) assembly line inspection scenarios, such as... Figure 2 As shown, Figure 2 This diagram illustrates the counting and detection functions of sensors at four workstations on the production line. Figure 2In the process, when PCs flow through the production line, the keyboard is inspected for defects at station A, the display screen for defects at station B, and the logo for defects at station C. At station D, the keyboard, display screen, and logo inspection results from stations A, B, and C are combined. If all three are qualified, the PC proceeds to the next process. If any one of them is unqualified, the unqualified PC is removed from the production line, thus eliminating unqualified products.

[0054] On the production line, by counting the products passing through stations A, B, C, and D, and based on the product counts at these four different stations, it can be determined whether the products passing through the four stations are the same product.

[0055] In some application scenarios, if ten products, namely product 1, product 2, product 3, ..., product 10, pass through station A in sequence, and due to external factors, the counting sensor at station B fails to count the 5th product correctly, then the counting sensor at station B will set the count for the 6th product to 5. As a result, when station D counts the data for the 5th product, it is actually counting the judgment results of the 5th product at station A, the 6th product at station B, and the 5th product at station C, causing a matching error in station D and affecting the quality of the production line.

[0056] In some embodiments, the movement time from the first sensor to the adjacent second sensor on the production line is a fixed value. The fixed movement time from the first sensor to the second sensor on the production line can be used as a verification benchmark. The counting sensor at station A can be referred to as the first sensor, and the counting sensor at station B can be referred to as the second sensor. The first sensor and the second sensor are adjacent to each other.

[0057] Step S102: Determine the first time base for the first sensor to collect data on the first product and determine the second time base for the second sensor to collect data on the first product.

[0058] In some embodiments, a stable time base can be established in the control system of the production line using a timed interrupt method. The control system can generate a timed interrupt every 10ms. The time base variable is an integer, counting from 1, meaning it increments by 1 every 10ms. Using a timed interrupt method to determine the time base ensures its stability. Furthermore, detecting all workstations on the production line based on this time base, compared to traditional methods that use individual timing, ensures consistency in timing across all workstations and avoids detection errors caused by inconsistencies in timing between individual workstations.

[0059] In some embodiments, when the first product passes by the first sensor, the first sensor counts the first product and records the first time base corresponding to the first product at the first sensor.

[0060] At the same time, when the first product passes the second sensor, the second sensor will also count the first product and record the second time base corresponding to the first product when it passes the second sensor.

[0061] Step S103: Determine the time base difference between the first time base and the second time base.

[0062] In some embodiments, when the first product reaches the second sensor after passing through the first sensor, the time base difference between the two time bases can be calculated based on the first time base corresponding to the first sensor and the second time base corresponding to the first product at the second sensor.

[0063] Step S104: Detect whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark.

[0064] In some embodiments, after determining the time base difference between the first time base corresponding to the first sensor and the second time base corresponding to the first product in the second sensor, the time base difference can be compared with a calibration benchmark. If the difference between the time corresponding to the time base difference and the time corresponding to the calibration benchmark is greater than a time threshold, it is determined that the first sensor or the second sensor has made an error in counting the first product. If the difference between the time corresponding to the time base difference and the calibration benchmark is less than or equal to the time threshold, it is determined that the first sensor and the second sensor have not made an error in counting the first product.

[0065] The following describes a method for counting detection and correcting erroneous counts provided by an embodiment of this application. See also... Figure 3 , Figure 3 This is a schematic diagram of an optional processing flow of the line counting detection and correction method provided in the embodiments of this application. The following will be combined with... Figure 3 The S301-S305 shown will be explained.

[0066] Step S301: Determine a fixed value for the motion time from the first sensor to the adjacent second sensor on the line as a verification benchmark.

[0067] In some embodiments, a fixed motion time from the first sensor to the second sensor on the line can be used as a calibration benchmark, wherein the first sensor and the second sensor are adjacent to each other.

[0068] Step S302: Determine the first time base for the first sensor to collect data on the first product and determine the second time base for the second sensor to collect data on the first product.

[0069] In some embodiments, a stable time base can be established in the control system of the online system by using a timed interrupt method. The control system can generate a timed interrupt every 10ms, and the time base variable is an integer, counting from 1, meaning the time base variable increments by 1 every 10ms.

[0070] In some embodiments, when the first product passes by the first sensor, the first sensor counts the first product and records the first time base corresponding to the first product at the first sensor.

[0071] At the same time, when the first product passes the second sensor, the second sensor will also count the first product and record the second time base corresponding to the first product when it passes the second sensor.

[0072] Step S303: Determine the time base difference between the first time base and the second time base.

[0073] In some embodiments, when the first product reaches the second sensor after passing through the first sensor, the time base difference between the two time bases can be calculated based on the first time base corresponding to the first sensor and the second time base corresponding to the first product at the second sensor.

[0074] Step S304: Detect whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark.

[0075] In some embodiments, if the difference between the time corresponding to the time base difference value and the time corresponding to the calibration benchmark is greater than a time threshold, it is determined that the first sensor or the second sensor has made a mistake in counting the first product.

[0076] Step S305: If the counting of the first product is incorrect, the counting of the first product is corrected based on the first count of the first product in the first sensor and the first time base, and the second count of the first product in the second sensor and the second time base.

[0077] In some embodiments, if an error occurs in the counting of the first product, the first sensor determines N time bases corresponding to the N products preceding the first product to the second sensor. The correct count of the first product can be determined based on the N differences between the second time base and the aforementioned N time bases. Then, the counting of the first product is corrected based on the correct count. Here, N is an integer greater than 2.

[0078] As an example, a counting error is detected when the first product reaches the second sensor. Because the production line is continuously running, the product at the first sensor at this time might be the fourth product after the first product. That is, five products, including the first product, have already passed the first sensor before the first product reaches it. Therefore, based on the second time base and the five time bases at which the five products arrived at the first sensor, five differences between these five time bases and the second time base can be determined to confirm the correct count of the first product. The specific value of N can be determined according to actual needs.

[0079] In some embodiments, if none of the N determined differences are within a preset threshold, it is determined that the counting of the first product is abnormal, and abnormal processing is performed on the first sensor or the second sensor.

[0080] As an example, if the first product is missed by the first sensor, and the second sensor detects an abnormality in the count of the first product, and the count of the first product that meets the requirements cannot be found through the product count of the first sensor, an abnormality handling operation will be triggered, and the first product will be removed from the line, and the line will no longer perform count correction on the first product.

[0081] In some embodiments, if one of the N differences is within a preset threshold, the target count is determined based on the target time base corresponding to the target difference, and the second count is restored to the target count.

[0082] In some embodiments, if the production line contains three or more sensors, and the product passes sequentially through the first sensor, second sensor, third sensor, fourth sensor, ... Nth sensor on the production line, then counting detection is performed on the time base and calibration benchmark of the first product based on every two adjacent sensors. That is, counting detection is performed based on the first sensor and the second sensor, the second sensor and the third sensor, the third sensor and the fourth sensor, ..., the (N-1)th sensor and the Nth sensor, respectively, and counting detection is performed on the first product based on every two adjacent sensors.

[0083] If at least one of the first and second sensors on the production line makes an error in counting the first product, the counts of all sensors are reset to zero, and the production line restarts counting the products. If the third sensor or any sensor after the third sensor on the production line makes an error in counting the first product, the erroneous sensor is corrected.

[0084] The following is based on Figure 4 The diagram illustrates the counting detection using two counting sensors. Figure 5The flowchart shown in this embodiment illustrates the counting correction process performed after two counting sensors encounter a counting error.

[0085] Step 501: The second sensor detects an error in the counting of the first product. (For example...) Figure 4 As shown, the first product moves from the first sensor to the second sensor on the production line. The sensor at station A can be referred to as the first sensor, and the sensor at station B can be referred to as the second sensor. When the first sensor detects the first product, it determines the current first count and first time base of the first product. When the second sensor detects the first product, it determines the current second count and second time base of the first product. Simultaneously, it determines the time base difference between the second time base and the first time base. If the difference between the time base difference and the verification benchmark is within a preset time threshold, the second sensor determines that the counting of the first product has an error and executes step 502.

[0086] As an example, if the calibration baseline is 10s, and the time base variable is incremented by 1 every 10ms, then the calibration baseline is equivalent to 1000 time bases, and the time threshold is 20 time bases.

[0087] If the first product is the current 5th product, the first product's first time base when it arrives at the first sensor is 20000, but it is not counted;

[0088] The second product is the current sixth product. When the second product arrives at the first sensor, the third time base is 20200. Since the first product has not been counted by the first sensor, the first sensor will count the second product as the count of the first product, which is 5.

[0089] When the first product arrives at the second sensor, the second time base is 21800, and the count is 5.

[0090] When the second product arrives at the second sensor, the fourth time base is 22000, and the count is 6.

[0091] At this time, the time base difference between the first time base and the second time base is 800. If the difference between the time base difference and the verification benchmark is greater than the preset time threshold, it is determined that the counting of the first product has an error.

[0092] Step 502: Determine the N time bases corresponding to the N products before the first product arrives at the second sensor.

[0093] The value of N here can be determined based on the actual situation.

[0094] As an example, when the second sensor detects an error in the counting of the first product, it will use the current product count of the first sensor at the current moment as a reference to determine the N time bases corresponding to the first N products respectively.

[0095] If N is set to 5, when the first sensor reaches the second sensor at the second time base, the product count of the first sensor is 9. That is, when the second sensor detects a counting error, the first sensor is currently receiving the 9th product. Taking the 9th product received by the first sensor as a reference, the 5 time bases corresponding to the first 5 products are determined respectively.

[0096] The time base of the first sensor is 21600 when the 8th product arrives, 21400 when the 7th product arrives, 21200 when the 6th product arrives, 21000 when the 5th product arrives, and 20500 when the 4th product arrives.

[0097] Step 503: Determine the N differences between the second time base and the N time bases respectively.

[0098] As an example, taking the 9th product reached by the first sensor as a reference, the time base difference between the second time base and the first sensor corresponding to the previous 5 products is determined. Specifically, the time base difference between the second time base and the 8th product reached by the first sensor is 200, the time base difference between the second time base and the 7th product reached by the first sensor is 400, the time base difference between the second time base and the 6th product reached by the first sensor is 600, the time base difference between the second time base and the 5th product reached by the first sensor is 800, and the time base difference between the second time base and the 4th product reached by the first sensor is 1200.

[0099] Step 504: Determine whether the above N time base difference values ​​are within a preset threshold. If none of these time base difference values ​​are within the preset threshold, proceed to step 505; otherwise, proceed to step 506.

[0100] As an example, the five time base differences mentioned above are 200, 400, 600, 800, and 1200, respectively. The verification benchmark is equivalent to 1000 time bases, and the preset threshold is 20. The difference between these time base differences and the verification benchmark is greater than the preset threshold, and these time base differences are not within the preset threshold. Therefore, step 505 is executed.

[0101] Step 505, Count Anomaly Handling. If the differences between the N products determined above are not within the preset threshold, it indicates that the count of the first product on the first sensor does not match the count of the first product on the second sensor, and the first product may have been missed. In this case, the first product is directly removed from the production line. That is, the 5th product is removed from the production line because the count is incorrect and no matching product can be found.

[0102] Step 506: Determine the correct count.

[0103] If one of the differences among the N products determined in the above steps is within a preset threshold, then the target time base corresponding to the target difference is determined to determine the target count, and the product count is restored.

[0104] As an example, after the 5th product, i.e. the first product, is missed and removed, the second product arrives at the second sensor. At this time, the corresponding fourth time base is 22000, and the count of the second product is 6. Because the second time base of the second product when it was at the first sensor is 20200, the time base difference between the two is 800 time bases, which is not within the preset threshold. At this time, the second sensor will detect that the second product has a counting error.

[0105] At the fourth time base, the first sensor has received the 10th product. Using the 10th product as a reference, the time base of the 9th product reached by the first sensor is 21800, the time base of the 8th product is 21600, the time base of the 7th product is 21400, the time base of the 6th product is 21200, and the time base of the 5th product is 21000. Determine the time base difference between this third time base and the time base of the previous 5 products arriving at the first sensor.

[0106] The time base difference between the third time base and the 9th product reached by the first sensor is 200, the time base difference between the third time base and the 8th product reached by the first sensor is 400, the time base difference between the third time base and the 7th product reached by the first sensor is 600, the time base difference between the third time base and the 6th product reached by the first sensor is 800, and the time base difference between the third time base and the 5th product reached by the first sensor is 1000.

[0107] It can be observed that the five time base differences mentioned above are 200, 400, 600, 800, and 1000, respectively. The calibration benchmark is equivalent to 1000 time bases, while the preset threshold is 20. Among these time base differences, only the time base difference when the first sensor reaches the 5th product is within the preset threshold.

[0108] Therefore, it is determined that the sixth product reached by the second sensor is actually a match for the fifth product reached by the first sensor.

[0109] Step 507: Restore the correct count to the system.

[0110] As an example, if it is determined that the second product reached by the second sensor is actually a match for the fifth product reached by the first sensor, then the count of the second product by the second sensor is changed to 5.

[0111] The following flowchart illustrates the counting correction process performed in this application after multiple counting sensors have encountered counting errors. See [link to flowchart]. Figure 6 , Figure 6 This is a flowchart illustrating the counting correction process performed after four counting sensors encounter counting errors, as provided in this application embodiment.

[0112] Step 601: Count and detect the time base and calibration benchmark of the first product based on every two adjacent sensors on the production line.

[0113] If the production line includes three or more counting sensors, and the product passes sequentially through the first sensor, second sensor, third sensor, fourth sensor, ... Nth sensor on the line, counting detection can be performed based on the first and second sensors, the second and third sensors, the third and fourth sensors, ..., the (N-1)th and Nth sensors, respectively, with each pair of adjacent sensors performing counting detection on the first product. Proceed to step 602.

[0114] Step 602: Determine whether either the first or second sensor on the production line has a counting error. If a counting error is detected in either the first or second sensor, proceed to step 604; otherwise, proceed to step 603.

[0115] Step 603: Determine if other sensors have encountered counting errors. If counting errors are detected in other sensors, proceed to step 605.

[0116] Step 604: Clear the count of the first sensor and continue to step 605.

[0117] Step 605: Perform count calibration on other sensors. Specifically, when the count of the first sensor is reset to zero, and then the count calibration of other sensors is performed based on the first sensor, it is equivalent to resetting the count of all sensors to zero.

[0118] Figure 7 This is a schematic diagram of an optional device structure for the counting detection device provided in an embodiment of this application. The counting detection device 700 includes a calibration benchmark determination module 701, a time base determination module 702, a time base difference determination module 703, and a counting detection module 704.

[0119] The calibration benchmark determination module 701 is used to determine a fixed value of the motion time from the first sensor to the adjacent second sensor on the line as a calibration benchmark.

[0120] Time base determination module 702 is used to determine a first time base for the first sensor to collect data on the first product and to determine a second time base for the second sensor to collect data on the first product.

[0121] The time base difference determination module 703 is used to determine the time base difference between the first time base and the second time base;

[0122] The counting detection module 704 is used to detect whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark.

[0123] In some embodiments, the counting detection module 704 is configured to: determine that the counting of the first product has occurred if the difference between the time base difference and the verification benchmark is greater than a time threshold; and determine that the counting of the first product has not occurred if the difference between the time base difference and the verification benchmark is less than or equal to the time threshold.

[0124] In some embodiments, the counting detection module 704 is configured to: if an error occurs in the counting of the first product, perform counting correction on the first product based on the first count of the first product in the first sensor and the first time base, and the second count of the first product in the second sensor and the second time base.

[0125] In some embodiments, the counting detection module 704 is further configured to: determine the N time bases corresponding to the N products before the arrival of the first product by the first sensor; and determine the correct count of the first product based on the N differences between the second time base and the N time bases; wherein N is an integer greater than 2.

[0126] In some embodiments, the counting detection module 704 is further configured to: if none of the N differences are within a preset threshold, determine that the counting of the first product is abnormal, and perform abnormal processing on the first sensor or the second sensor.

[0127] If one of the N differences is within a preset threshold, then the target count is determined based on the target time base corresponding to the target difference, and the second count is restored to the target count.

[0128] In some embodiments, the counting detection module 704 is further configured to: if at least three sensors are included, perform counting detection on the time base of the first product and the calibration benchmark based on every two adjacent sensors respectively.

[0129] In some embodiments, the counting detection module 704 is further configured to: if at least one of the first sensor and the second sensor on the line makes an error in counting the first product, then reset the counts of all sensors on the line to zero.

[0130] It should be noted that the counting detection device of this application embodiment is similar to the counting detection method embodiment described above, and has similar beneficial effects as the method embodiment, therefore, it will not be described in detail. For any technical details not covered in the counting detection device provided in this application embodiment, please refer to... Figures 1 to 6 The meaning is understood in accordance with the description of any of the accompanying drawings.

[0131] Figure 8 A schematic block diagram of an example electronic device 800 that can be used to implement embodiments of the present disclosure is shown. The electronic device 800 is used to implement the counting detection method of the embodiments of the present disclosure. In some alternative embodiments, the electronic device 800 can implement the counting detection method provided in the embodiments of this application by running a computer program. For example, the computer program can be a software module in an operating system; it can be a native application (APP), i.e., a program that needs to be installed in the operating system to run; it can also be an applet, i.e., a program that only needs to be downloaded to a browser environment to run; or it can be an applet that can be embedded in any APP. In short, the above-mentioned computer program can be any form of application, module, or plugin.

[0132] In practical applications, electronic device 800 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms. Cloud technology refers to a hosting technology that unifies hardware, software, and network resources within a wide area network (WAN) or local area network (LAN) to achieve data computation, storage, processing, and sharing. Electronic device 800 can be a smartphone, tablet, laptop, desktop computer, smart speaker, smart TV, smartwatch, etc., but is not limited to these.

[0133] Electronic devices are intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. Electronic devices can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices, in-vehicle terminals, and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the present application described and / or claimed herein.

[0134] like Figure 8 As shown, the electronic device 800 includes a computing unit 801, which can perform various appropriate actions and processes according to a computer program stored in a read-only memory (ROM) 802 or a computer program loaded from a storage unit 808 into a random access memory (RAM) 803. The RAM 803 may also store various programs and data required for the operation of the electronic device 800. The computing unit 801, ROM 802, and RAM 803 are interconnected via a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.

[0135] Multiple components in electronic device 800 are connected to I / O interface 805, including: input unit 806, such as keyboard, mouse, etc.; output unit 807, such as various types of displays, speakers, etc.; storage unit 808, such as disk, optical disk, etc.; and communication unit 809, such as network card, modem, wireless transceiver, etc. Communication unit 809 allows electronic device 800 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0136] The computing unit 801 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the computing unit 801 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 801 performs the various methods and processes described above, such as the counting detection method. For example, in some alternative embodiments, the counting detection method can be implemented as a computer software program tangibly contained in a machine-readable medium, such as storage unit 808. In some alternative embodiments, part or all of the computer program can be loaded and / or installed on the electronic device 800 via ROM 802 and / or communication unit 809. When the computer program is loaded into RAM 803 and executed by the computing unit 801, one or more steps of the counting detection method described above can be performed. Alternatively, in other embodiments, the computing unit 801 can be configured as a counting detection method by any other suitable means (e.g., by means of firmware).

[0137] This application provides a computer-readable storage medium storing executable instructions, wherein the executable instructions are stored and when executed by a processor, the processor will execute the counting detection method provided in this application.

[0138] In some embodiments, the computer-readable storage medium may be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or it may be a variety of devices including one or any combination of the above-mentioned memories.

[0139] In some embodiments, executable instructions may take the form of a program, software, software module, script, or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a standalone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.

[0140] As an example, executable instructions can be deployed to execute on a single computing device, or on multiple computing devices located in one location, or on multiple computing devices distributed across multiple locations and interconnected via a communication network.

[0141] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0142] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0143] It should be understood that in the various embodiments of this application, the sequence number of each implementation process does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0144] The above are merely embodiments of this application and are not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, and improvements made within the spirit and scope of this application are included within the scope of protection of this application.

Claims

1. A method for counting and detecting lines, characterized in that, The method includes: A fixed value is set for the motion time from the first sensor to the adjacent second sensor on the line as the verification benchmark; The control system generates a timed interrupt at fixed time intervals and generates an integer time base variable that starts from an initial value and increments with each interrupt. The number of interruptions when the first sensor collects data on the first product is determined as the first time base, and the number of interruptions when the second sensor collects data on the first product is determined as the second time base; Determine the time base difference between the first time base and the second time base; The difference between the time base difference and the verification benchmark is used to detect whether an error has occurred in the counting of the first product; After detecting whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark, the method includes: If the counting of the first product is incorrect, the counting of the first product is corrected based on the first count of the first product in the first sensor and the first time base, and the second count of the first product in the second sensor and the second time base. The count correction for the first product includes: Determine the N time bases corresponding to the N products before the first product reaches the second sensor; The correct count of the first product is determined based on the N differences between the second time base and the N time bases respectively; where N is an integer greater than 2.

2. The method according to claim 1, characterized in that, The step of detecting whether the counting of the first product has been erroneous based on the difference between the time base difference and the verification benchmark includes: If the difference between the time base difference and the verification benchmark is greater than the time threshold, it is determined that the counting of the first product has been incorrect. If the difference between the time base difference and the verification benchmark is less than or equal to the time threshold, then it is determined that the counting of the first product has not been erroneous.

3. The method according to claim 1, characterized in that, The step of determining the correct count of the first product based on the N differences between the second time base and the N time bases includes: If none of the N differences are within the preset threshold, it is determined that the counting of the first product is abnormal, and abnormal processing is performed on the first sensor or the second sensor. If one of the N differences is within a preset threshold, then the target count is determined based on the target time base corresponding to the target difference, and the second count is restored to the target count.

4. The method according to claim 1, characterized in that, The line counting detection method further includes: If the line contains at least three sensors, then the time base of the first product and the calibration benchmark are counted and detected based on every two adjacent sensors.

5. The method according to claim 4, characterized in that, If the line body contains at least three sensors, then after counting and detecting the time base of the first product and the calibration benchmark based on every two adjacent sensors, the method includes: If at least one of the first sensor and the second sensor on the production line makes an error in counting the first product, then the counts of all sensors on the production line are reset to zero.

6. A line counting and detection device, characterized in that, The device includes: The calibration benchmark determination module is used to determine a fixed value for the motion time from the first sensor to the adjacent second sensor on the line as the calibration benchmark. The time base determination module is used to control the system to generate timed interrupts at fixed time intervals and generate an integer time base variable that starts from an initial value and increments with each interruption; it determines the number of interruptions when the first sensor collects the first product as the first time base and determines the number of interruptions when the second sensor collects the first product as the second time base; A time base difference determination module is used to determine the time base difference between the first time base and the second time base; The counting detection module is used to detect whether an error has occurred in the counting of the first product based on the difference between the time base difference and the verification benchmark. The counting detection module is further configured to, if an error occurs in the counting of the first product, perform counting correction on the first product based on the first count of the first product in the first sensor and the first time base, and the second count of the first product in the second sensor and the second time base; The counting and detection module is further configured to determine the N time bases corresponding to the N products before the first product reaches the second sensor; and to determine the correct count of the first product based on the N differences between the second time base and the N time bases; wherein N is an integer greater than 2.

7. An electronic device, characterized in that, The electronic device includes: At least one processor; and a memory communicatively connected to said at least one processor; The memory stores instructions that can be executed by the at least one processor, which, when executed by the at least one processor, enables the at least one processor to perform the method according to any one of claims 1-5.

8. A computer-readable storage medium, characterized in that, The storage medium includes a set of computer-executable instructions, which, when executed, are used to perform the line counting detection method according to any one of claims 1-5.