Sensor failure detection method for automation equipment

By using PLC and storage devices to record the contrast signal of the falling edge of the sensor in the automation equipment, the sensor self-detection is achieved, and the problem of equipment failure caused by sensor failure is solved, and the efficiency and safety of the automated transmission system are improved.

CN120213104APending Publication Date: 2025-06-27ZHEJIANG SAFUN IND
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510334072.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-20
Publication Date
2025-06-27

AI Technical Summary

Technical Problem

In automation equipment, when the sensor fails or is blocked by obstacles, the sensor may be output all the time, and the controller will always work without workpieces, resulting in equipment failure and affecting the operating efficiency and safety of the automated transmission system.

Method used

The PLC is used as the controller, and the high and low levels output by the sensor are used as the operating signals, and the falling edge output by the sensor is recorded as the reference signal by the storage device, so as to realize the self-detection function of the sensor.

Benefits of technology

The self-detection of sensors is realized through software, reducing equipment costs, improving the operating efficiency and safety of automated transmission systems, and avoiding equipment failures.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120213104A_ABST
    Figure CN120213104A_ABST
Patent Text Reader

Abstract

The invention discloses a sensor failure detection method for automation equipment, which adopts a PLC (Programmable Logic Controller) as a controller of the automation equipment, and adopts a high level and a low level output by a sensor as operation signals; a storage device is adopted to record a falling edge output by the sensor last time as a comparison signal; in the equipment operation process, when an operation signal is at a high level, the following logic is executed and a result is output: under the condition that a contrast signal exists, the next operation is continued to be executed, and the current contrast signal is updated; and under the condition that the contrast signal does not exist, a sensor abnormity prompt is output. The defects that in the prior art, when a sensor loses efficacy or the sensor is blocked by an obstacle, the sensor always outputs, a PLC possibly works all the time under the condition that no workpiece exists, and equipment faults are caused are overcome.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of automated equipment, and particularly to a method for detecting sensor failure in automated equipment. Background Art

[0002] With the development of industrial automation and intelligent manufacturing, automated equipment is increasingly widely used in the production process. Sensors can provide accurate data for the controller in real time to support the operation decision-making of the equipment.

[0003] During the operation of automated equipment, if the sensor fails or an obstacle blocks the sensor, resulting in the sensor always having an output, the controller may keep working without a workpiece, leading to equipment failures and affecting the operation efficiency and safety of the entire automated transmission system. Improvements are needed in this regard. Summary of the Invention

[0004] The present invention discloses defects in the prior art, such as when the sensor fails or an obstacle blocks the sensor, resulting in the sensor always having an output, and the PLC may keep working without a workpiece, leading to equipment failures. A new method for detecting sensor failure in automated equipment is provided.

[0005] A method for detecting sensor failure in automated equipment uses a PLC as the controller of the automated equipment. The detection method uses the high level and low level output by the sensor as operating signals, and uses a storage device to record the falling edge of the sensor's previous output as a reference signal.

[0006] During the operation of the equipment, when the operating signal is high level, execute the following logic and output the result:

[0007] If there is a reference signal, continue with the next operation and update the current reference signal.

[0008] If there is no reference signal, output a sensor abnormality prompt.

[0009] In the present invention, by using the high level, low level output by the sensor during normal operation and the falling edge generated by the conversion between the high level and low level as the reference signal, in the form of software, without adding hardware facilities, the self-detection function of the sensor is realized through a sensor combined with a PLC. On the one hand, it can reduce the equipment cost, and on the other hand, it can improve the operation efficiency and safety of the automated transmission system.

[0010] The following also provides several optional methods, which are not additional limitations to the above overall solution, but merely further supplements or optimizations. On the premise of no technical or logical contradictions, each optional method can be combined with the above overall solution separately, or multiple optional methods can be combined with each other.

[0011] Optionally, the detection method includes a material shortage prompt step. By setting a first delay instruction, timing starts when the running signal outputs a low level. When the duration of the low level output of the running signal reaches T1, a material shortage prompt is output.

[0012] Optionally, the detection method includes a first power-on detection step. After the automation device is powered on, the storage device is initialized to generate a reference signal.

[0013] Optionally, register M0 is used to record the running signal. When the sensor detects an object and outputs a high level, M0 is recorded as 1; when the sensor does not detect an object and outputs a low level, M0 is recorded as 0. Register M1 is used as the storage device to record the reference signal. When the falling edge of the sensor output is detected, M1 is recorded as 1; when the reference signal disappears, M1 is recorded as 0. If M0 is 1 and M1 is 0, a sensor abnormality prompt is output.

[0014] Optionally, the detection method further includes a reset step. After the rising edge of the sensor output is detected, M1 is reset to 0.

[0015] Optionally, the detection method further includes an anti-interference step. By setting a second delay instruction, timing starts after the rising edge of the sensor output is detected. When the timing duration reaches T2, M1 is reset to 0.

[0016] Optionally, the detection method further includes a third delay instruction. Timing starts after the rising edge of the sensor output is detected. When the timing duration reaches T3, a sensor abnormality prompt is output.

[0017] Optionally, the detection method further includes setting a first counter to count the number of reference signals within a rated time. If the frequency of the reference signal within the rated time exceeds the preset frequency range, a sensor abnormality prompt is output.

[0018] Optionally, the first power-on detection step includes setting a second counter to accumulate the number of reference signals generated after the automation device is powered on and reset to 0 after the automation device is powered off. When the second counter is 0, the storage device is initialized to generate a reference signal.

[0019] Optionally, the detection method further includes using a debounce module to filter the reference signal and the running signal.

[0020] The beneficial effects of the present invention are as follows:

[0021] 1. In the present invention, the signals output by the sensor are detected, and software-based sensor failure detection is achieved through a preset detection method;

[0022] 2. In the present invention, a first delay instruction, a second delay instruction, and a third delay instruction are set to respectively implement material shortage prompts, prevent abnormal error reports caused by external interference (for example, a mouse passing by), and prevent high-level faults of the sensor, so as to cope with more actual usage scenarios and improve the environmental adaptability of the detection method in the present invention;

[0023] 3. The detection method in the present invention is provided with a first power-on detection step, which is initialized when the device is powered on, to avoid error reports after the sensor is replaced or after the device is restarted after shutdown. BRIEF DESCRIPTION OF THE DRAWINGS

[0024] Figure 1 is a flowchart of Embodiment 1 of the present invention;

[0025] Figure 2 is a flowchart of Embodiment 2 of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0026] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.

[0027] It should be noted that when a component is referred to as being "connected" to another component, it can be directly connected to the other component or there may also be an intermediate component. When a component is considered to be "disposed on" another component, it can be directly disposed on the other component or there may be an intermediate component at the same time.

[0028] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those of ordinary skill in the technical field to which the present invention belongs. The terms used herein in the description of the present invention are only for the purpose of describing specific embodiments and are not intended to limit the present invention. The term "and / or" used herein includes any and all combinations of one or more of the related listed items.

[0029] Embodiment 1

[0030] In one embodiment, as Figure 1As shown, a sensor failure detection method for an automated device is disclosed. By setting the falling edge of the sensor as the reference signal and combining the current output level of the sensor being high or low, the state of the sensor itself is judged. The specific steps are as follows:

[0031] Step 1: According to whether the output of the sensor is high or low, judge whether the material is being transported normally. Output a material shortage prompt at a low level and execute the subsequent steps at a high level;

[0032] Step 2: Judge whether the device is powered on for the first time. If it is not the first power-on, execute Step 3; if it is the first power-on, execute Step 4;

[0033] Step 3: Record the reference signal as M1. M1 = 1 indicates the existence of the reference signal, and M1 = 0 indicates the non-existence of the reference signal; Judge whether the reference signal M1 is 0. If the reference signal M1 = 0, output a sensor abnormality. If the reference signal M1 = 1, execute Step 4;

[0034] Step 4: Reset M1 to 0 and continue to execute the subsequent steps;

[0035] Step 5: When the material leaves the detection range of the sensor and the sensor changes from high level to low level, at this time output the reference signal M1 = 1;

[0036] After Step 5, start to execute Step A.

[0037] It should be explained that the above Steps 1 to 5 are part of the complete operation process of the automated device and are specifically used to detect the state of the sensor. It can be understood that the above Step A is the subsequent step of the operation of the automated device after the material leaves the detection range of the sensor. Step A and the above detection method form a complete operation process of the automated device in a cycle.

[0038] Embodiment 2

[0039] In an embodiment of the present invention, a sensor failure detection method for an automated device is disclosed. This method uses a PLC as the controller of the automated device, and detects the high and low levels output by the sensor as the operation signal; and uses a storage device to record the falling edge of the last output of the sensor as the reference signal.

[0040] During the operation of the device, when the operation signal is high level, it is judged that there is material passing through the sensor currently; when the operation signal is low level, it is judged that there is no material passing through the sensor currently.

[0041] At the same time, it is necessary to combine the corresponding reference signal in the current storage device. If there is a reference signal, then continue to execute the next operation and update the reference signal in the current storage device; if there is no reference signal, then output a sensor abnormality prompt.

[0042] Further, the detection method includes a material shortage prompting step for prompting a material shortage. By setting a first delay instruction (TON1), the timing duration of the first delay instruction is T1. When the running signal outputs a low level, timing starts, and when the duration of the low-level output of the running signal reaches T1, a material shortage prompt is output.

[0043] It should be noted that assuming the time required for the material to pass through the sensor is t, the duration of the first delay instruction is at least 1.5 times t.

[0044] Furthermore, to avoid the interference of the information recorded by the storage device after power-off on the execution of the above detection method after the next device power-on. The detection method includes a first power-on detection step, which initializes the storage device after the automation device is powered on to generate a reference signal.

[0045] In an embodiment of the present invention, the register M0 is used to record the running signal, and the register M1 is used as the storage device to record the reference signal. When the sensor outputs a low level, M0 = 0, and when the sensor outputs a high level, M0 = 1; after the reference signal disappears, M1 = 0; when the falling edge of the sensor output is detected, M1 = 1; if M0 = 1 and M1 = 0, a sensor abnormality prompt is output.

[0046] Further, the detection method further includes a reset step, and after the rising edge of the sensor output is detected, M1 = 0 is output.

[0047] To avoid false alarms caused by external interference to the sensor (such as a mouse passing by or sensor signal jitter). The above detection method further includes an anti-interference step, by setting a second delay instruction (TON2), the duration of the second delay instruction is T2. Timing starts after the rising edge of the sensor output is detected, and when the timing duration reaches T2, M1 is reset to 0.

[0048] It should be noted that the duration of the second delay instruction is related to the time t required for the material to pass through the sensor, that is, related to the conveying speed of the automation device and the material length. The duration of the second delay instruction needs to be less than the duration required for the material to pass through the sensor to avoid interfering with the reference signal generated by the falling edge of the current material passing through.

[0049] To avoid the sensor malfunctioning and continuously outputting a high level, falsely reporting that a material has passed through, the detection method further includes a third delay instruction (TON3), and the timing duration of the third delay instruction is T3. It should be explained that the duration of the third delay instruction is greater than the time t required for the material to pass through the sensor, at least 1.5 times t.

[0050] Start timing after detecting the rising edge of the sensor output. When the timing duration reaches T3, an abnormal sensor prompt is output. It can be understood that the duration of the sensor output M0 = 1 exceeds the duration required for normal materials to pass. At this time, the sensor is faulty or there is an obstruction in front of the sensor.

[0051] To improve the stability of the above detection method and solve the problem of frequent sensor signal jitter. In some embodiments, the detection method further includes setting a first counter CTU1 for counting the number of reference signals within a rated time. If the frequency of the reference signal within the rated time exceeds the preset frequency range, an abnormal sensor prompt is output. It can be understood that the sensor is faulty, resulting in frequent signal jitter.

[0052] Furthermore, in some embodiments, the detection method further includes using a debounce module to filter the reference signal and the running signal. The above debounce module can use software filtering, for example: setting a moving window for multi-period sampling (for example, setting 5 sampling periods); or using a hardware filter, such as an RC circuit, and setting the filtering time.

[0053] In some embodiments, the above first power-on detection step uses a second counter CTU2 to accumulate the number of reference signals generated after the automation device is powered on, and the second counter CTU2 is reset after the automation device is powered off or when it is powered on; when the second counter is 0, the storage device is initialized to generate a reference signal and M1 is set to 1; when the count of the second counter is greater than 0, the initialization operation is skipped.

[0054] Reference Figure 2 , in combination with the above embodiments, the present invention discloses a method for detecting sensor failure for an automation device, specifically as follows:

[0055] S1. After powering on the device, perform the first power-on detection step, which specifically includes: resetting the second counter CTU2 and setting M1 to 1;

[0056] S2. After completing S1, detect the running signal output by the sensor. When the running signal M0 = 0, jump to step S3; when the running signal M0 = 1, jump to step S4;

[0057] S3. Execute the material shortage prompt step, which specifically includes: TON1 starts timing, and the timing duration is T1. When the duration reaches T1, a material shortage prompt is output, indicating that the device is short of materials; (more specifically, the time when TON1 starts timing refers to the instant of the rising edge of the sensor output)

[0058] S4. Detect the reference signal and determine whether M1 is 1. When M1 = 0, output a sensor abnormality prompt (indicating that the falling edge of the previous material passing by is not detected, suggesting a sensor failure); when M1 = 1, simultaneously execute step S5 and step S6.

[0059] S5. Execute the anti-interference step, specifically including: when the running signal M0 = 1, TON2 starts timing, and the timing duration is T2. When the duration reaches T2, output the reference signal M1 = 0; (it needs to be explained that the duration of T2 is less than the duration of a single material passing through the sensor. Before the sensor outputs a falling edge, reset the previously output falling edge to avoid interfering with the next material; at the same time, T2 can also avoid external environmental interferences such as mice passing by the sensor).

[0060] S6. Execute the high-level detection for preventing sensor failure, specifically including: when the running signal M0 = 1, TON3 starts timing, and the timing duration is T3. When the duration reaches T3, output a sensor abnormality prompt; (it needs to be explained that this step is used to detect the long-term output of a high level after a sensor failure, and the duration of T3 is greater than the duration of a single material passing through the sensor).

[0061] S7. When the material leaves the sensor and a falling edge is detected, output M1 = 1.

[0062] S8. If there are still materials passing through the sensor, increment the count of the second counter CTU2 by 1, and loop to execute step S2 to step S8.

[0063] Embodiment Three

[0064] In one embodiment, the status relays M0 and M1 can also be used to replace the registers M0 and M1 in the above embodiments respectively. The status relay automatically resets to zero after power-off, which can simplify the software program through the mechanical structure.

[0065] It can be foreseen that after the device is powered off, the status relays M0 and M1 are 0.

[0066] The difference from the above Embodiment One and Embodiment Two mainly lies in the first power-on detection step. After the device is powered on, when the first material reaches the detection range of the sensor, the status relay M0 changes from 0 to 1. At this time, the status relay M1 is 0, and a timing instruction starts; when the first material leaves the detection range of the sensor, the status relay M0 changes from 1 to 0. If the timing instruction reaches the rated time and the status relay M1 does not change from 0 to 1, output a sensor abnormality prompt.

[0067] The technical features of the above-described embodiments can be combined arbitrarily. For the sake of brevity of description, not all possible combinations of the technical features in the above-described embodiments are described. However, as long as there is no contradiction in the combination of these technical features, it should be considered as falling within the scope described in this specification. When the technical features in different embodiments are embodied in the same drawing, the drawing can be regarded as also disclosing the combination examples of the various embodiments involved.

[0068] The above-described embodiments merely represent several implementation manners of the present invention. The description is relatively specific and detailed, but it should not be construed as a limitation on the scope of the patent application. It should be noted that for those of ordinary skill in the art, without departing from the concept of the present invention, several modifications and improvements can still be made, and these all belong to the protection scope of the present invention.

Claims

1. A sensor failure detection method for automation equipment, using PLC as the controller of the automation equipment, characterized in that: The detection method uses the high level and low level output by the sensor as the operation signal; and uses a storage device to record the falling edge of the sensor's last output as a control signal; During the operation of the device, when the operation signal is high, the following logic is executed and the results are output: If there is a control signal, continue to execute the next step and update the current control signal; If there is no control signal, a sensor abnormality prompt is output.

2. A sensor failure detection method for automation equipment according to claim 1, characterized in that: The detection method includes a material shortage prompting step, by setting a first delay instruction, starting timing when the operation signal outputs a low level, and outputting a material shortage prompting when the duration of the operation signal outputting a low level reaches T1.

3. A sensor failure detection method for automation equipment according to claim 1, characterized in that: The detection method comprises a first power-on detection step, in which the storage device is initialized after the automation device is powered on, and a control signal is generated.

4. A sensor failure detection method for automation equipment according to claim 2, characterized in that: Register M0 is used to record the operation signal. When the sensor detects an object and outputs a high level, M0 is recorded as 1; when the sensor does not detect an object and outputs a low level, M0 is recorded as 0. Register M1 is used as a storage device to record the control signal. When the falling edge of the sensor output is detected, M1 is recorded as 1. After the control signal disappears, M1 is recorded as 0. If M0 is 1 and M1 is 0, the output sensor abnormality prompt is given.

5. A sensor failure detection method for automation equipment according to claim 4, characterized in that: The detection method further comprises a resetting step, wherein M1 is reset to 0 after a rising edge of the sensor output is detected.

6. A sensor failure detection method for automation equipment according to claim 5, characterized in that: The detection method also includes an anti-interference step, by setting a second delay instruction, starting timing after detecting the rising edge of the sensor output, and resetting M1 to 0 when the timing duration reaches T2.

7. A sensor failure detection method for automation equipment according to claim 6, characterized in that: The detection method also includes a third delay instruction, which starts timing after detecting the rising edge of the sensor output, and outputs a sensor abnormality prompt when the timing duration reaches T3.

8. A sensor failure detection method for automation equipment according to claim 1, characterized in that: The detection method further includes setting a first counter for counting the number of control signals within a rated time, and outputting a sensor abnormality prompt if the frequency of the control signal within the rated time exceeds a preset frequency range.

9. A sensor failure detection method for automation equipment according to claim 3, characterized in that: The first power-on detection step includes setting a second counter for accumulating the number of control signals generated after the automation device is powered on, and returning to 0 after the automation device is powered off; When the second counter is 0, the storage device is initialized and a comparison signal is generated.

10. A sensor failure detection method for automation equipment according to claim 1, characterized in that: The detection method further comprises using a de-jitter module to filter the control signal and the operation signal.