Device and method for prolonging service life of photoelectric sensor
Through the combination of the MCU controller, the light intensity and voltage of the photoelectric sensor, the optical signal intensity and voltage are regulated, and the life shortening and abnormal feedback caused by the photoelectric sensor's light decay is solved, and the stability and accuracy are improved and cost reduction.
Patent Information
- Application Number
- CN202411328551.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2025-01-14
- Estimated Expiration
- 2044-09-24
AI Technical Summary
Existing photoelectric sensors are prone to light decay under the influence of factors such as temperature, current and working time, resulting in a shortening of the equipment life. The existing technology cannot effectively extend the life of the photoelectric sensor and promptly feedback abnormalities, especially in remote areas with high maintenance costs.
The MCU controller, light intensity adjustment module and resistance adjustment module are adopted to adjust the duty cycle of the PWM signal and the pull-down resistance value, and adjust the intensity of the emitter end of the photoelectric sensor and the voltage of the receiving end to achieve automatic calibration and life extension.
It effectively delays the shortening of the life of the photoelectric sensor due to light decay, enhances stability and accuracy, reduces labor costs, realizes early warning and remote handling of abnormal risks, and reduces inspection and replacement work.
Smart Images

Figure CN119309607A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of photoelectric sensors, and in particular to a device and method for extending the service life of a photoelectric sensor. Background Art
[0002] In daily life and industrial applications, photoelectric sensors are favored because of their wide application in various fields; however, in actual application, existing photoelectric sensors are affected by factors such as temperature, current, and working hours, and inevitably have light decay problems, which seriously affect the machines and equipment embedded with photoelectric sensors, significantly shorten the life of industrial equipment, and affect the accuracy and stability of industrial equipment; at the same time, considering the timeliness and labor costs of troubleshooting the light decay problem of photoelectric sensors in industrial equipment, especially in remote areas with high maintenance costs, harsh environments, and difficult maintenance, delaying the impact of light decay on machines and promptly reporting abnormalities have become the main directions for solving the problem.
[0003] The existing patent with publication number CN216052701U discloses a photoelectric sensor light decay detection device, which receives the current data signal sent by the current acquisition unit through the main control unit and calculates it, obtains the actual current value of the photoelectric sensor's photosensitive side and sends it to the display unit, and sends the acquisition time and the actual current value to the data storage unit at a preset time interval to realize automatic detection of the photoelectric sensor's light decay, but the patent has a single function and can only detect the light decay current, and cannot prevent the machine from being affected by the light decay phenomenon; the existing patent with publication number CN102708617B discloses a banknote detection method and equipment and a photoelectric sensor adaptive adjustment method and device, including a photoelectric sensor, a micro control unit, a digital-to-analog converter DAC, a driver and a current limiting resistor, and adaptively adjusts the DAC value corresponding to the voltage at the light-emitting end of the photoelectric sensor, and compensates for the DAC value, thereby improving the adaptability of the photoelectric sensor, but the patent can only adjust the light intensity at the light-emitting end, cannot cope with severe light decay, and has a limited time to extend the life of the light decay sensor, which has certain limitations. Summary of the invention
[0004] In order to overcome the defects of the above-mentioned prior art, the present invention provides a device and method for extending the service life of photoelectric sensors, which is used to solve the problems that the existing devices have limited effect in delaying the light decay life of photoelectric sensors and cannot provide timely feedback on photoelectric sensor abnormalities.
[0005] In order to achieve the above technical objectives, the following technical solutions are adopted:
[0006] In a first aspect, an embodiment of the present invention provides a device for extending the service life of a photoelectric sensor, comprising a photoelectric sensor, a light intensity adjustment module, and an MCU controller;
[0007] The PWM end of the MCU controller is connected to the input end of the light intensity adjustment module, and the output end of the light intensity adjustment module is connected to the transmitting end of the photoelectric sensor, so as to adjust the duty cycle of the PWM signal output by the MCU controller and use the light intensity adjustment module to control the light emitting current of the transmitting end of the photoelectric sensor, thereby adjusting the light signal intensity of the transmitting end of the photoelectric sensor;
[0008] The ADC end of the MCU controller is connected to the receiving end of the photoelectric sensor to sample the voltage of the receiving end of the photoelectric sensor.
[0009] Furthermore, it also includes a resistance adjustment module, which includes a first resistance adjustment unit, a second resistance adjustment unit, a first switch K1, and a second switch K2; the input end of the first resistance adjustment unit is connected to the first control end of the MCU controller through the first switch K1, and the output end of the first resistance adjustment unit is connected to the receiving end of the photoelectric sensor;
[0010] The input end of the second resistance adjusting unit is connected to the second control end of the MCU controller through the second switch K2, and the output end of the second resistance adjusting unit is connected to the receiving end of the photoelectric sensor.
[0011] Furthermore, it also includes a host computer, which is connected to the MCU controller to receive the abnormal signal of the photoelectric sensor fed back by the MCU controller and regulate the photoelectric sensor through the MCU controller.
[0012] Furthermore, the light intensity adjustment unit includes a field effect transistor Q1, a resistor R1, a resistor R2, and a resistor R3;
[0013] The drain of the field effect tube Q1 is connected to the emitter end of the photoelectric sensor, the source of the field effect tube Q1 is grounded through a resistor R1, and the gate of the field effect tube Q1 is connected to the PWM end of the MCU controller through a resistor R2; one end of the resistor R3 is connected to the gate of the field effect tube Q1, and the other end is grounded.
[0014] Further, the first regulating resistance unit includes a field effect transistor Q2, a resistor R4, a resistor R5, and a resistor R6;
[0015] The drain of the field effect tube Q2 is connected to the emitter of the photoelectric sensor, and the source of the field effect tube Q2 is grounded through the resistor R4; the gate of the field effect tube Q2 is connected to the resistor R5, the first switch K1 and the first control terminal of the MCU controller in sequence;
[0016] One end of the resistor R6 is connected to the first switch K1 , and the other end is grounded; the ADC end of the MCU controller is connected to the drain of the field effect transistor Q2 .
[0017] Furthermore, the second regulating resistor unit includes a field effect transistor Q3, a resistor R7, a resistor R8, and a resistor R9;
[0018] The drain of the field effect tube Q3 is connected to the emitter of the photoelectric sensor, and the source of the field effect tube Q3 is grounded through the resistor R7; the gate of the field effect tube Q3 is connected to the resistor R8, the second switch K2 and the second control terminal of the MCU controller in sequence;
[0019] One end of the resistor R9 is connected to the second switch K2, and the other end is grounded; the ADC end of the MCU controller is connected to the drain of the field effect transistor Q3.
[0020] Furthermore, the transmitting end of the photoelectric sensor is an infrared transmitting tube, and the receiving end of the photoelectric sensor is an infrared receiving tube; the infrared receiving tube adopts a phototransistor;
[0021] The anode of the infrared emitting tube is connected to the first power supply voltage terminal, and the cathode of the infrared emitting tube is connected to the PWM terminal of the MCU controller through the light intensity adjustment module;
[0022] The collector of the infrared receiving tube is connected to the second power supply voltage terminal, and the emitter of the infrared receiving tube is connected to the first resistance adjustment unit and the second resistance adjustment unit respectively.
[0023] In a second aspect, an embodiment of the present invention provides a method for extending the service life of a photoelectric sensor, which is applied to the device as described above, and includes:
[0024] S1. Send calibration instructions to the MCU controller through the host computer and set the calibration success threshold V ref ;
[0025] S2. After the MCU controller receives the calibration command, it samples the voltage at the receiving end of the photoelectric sensor through the ADC end of the MCU controller to obtain the sampled voltage V ADC ;
[0026] S3, judging the working state of the photoelectric sensor, and determining whether the photoelectric sensor needs to be calibrated according to the working state;
[0027] The S3 specifically includes the following steps:
[0028] S31, the sampling voltage V ADC The calibration success threshold V ref Make comparisons;
[0029] S32, when V ADC ≥V ref , it is considered that the photoelectric sensor is in normal working condition and the photoelectric sensor does not need to be calibrated;
[0030] S33, when V ADC <V ref , the photoelectric sensor is considered to be in a light decay state, and the automatic calibration mechanism is triggered to calibrate the photoelectric sensor. If the calibration is successful, the PWM signal duty cycle of the sensor transmitter is saved and the photoelectric sensor is used normally; if the calibration fails, the life extension mechanism is triggered to recalibrate the photoelectric sensor.
[0031] Further, in S33, the specific steps of the automatic calibration mechanism include:
[0032] By adjusting the duty cycle of the PWM signal output by the MCU controller, the light signal intensity at the transmitting end of the photoelectric sensor is adjusted to change the emitter voltage V at the transmitting end of the photoelectric sensor. RD ;
[0033] The emitter voltage V RD The calibration success threshold V ref Make comparisons;
[0034] When V RD ≥V ref , the photoelectric sensor is considered to be calibrated successfully;
[0035] When V R <V ref , it is considered that the photoelectric sensor calibration has failed;
[0036] The emitter voltage V of the infrared receiving tube RD The calculation formula is:
[0037] V RD =V ADC
[0038] V ADC =I E ·R E
[0039] I E =(1+β)·I B
[0040] In the formula, I E is the emitter current of the infrared receiving tube, I B is the luminous current of the infrared emitting tube; R E is the pull-down resistor of the infrared receiving tube; β is the amplification factor of the infrared receiving tube;
[0041] The luminous current I of the infrared emitting tube B The calculation formula is:
[0042]
[0043] Where V is the first power supply voltage, V f is the on-state voltage of the infrared emitting tube; PWM is the duty cycle of the PWM signal; ɑ is the light decay coefficient; θ1 is the influence coefficient of the installation distance and angle offset of the photoelectric sensor (0≦θ1≦1); θ2 is the dust and environmental influence coefficient.
[0044] Furthermore, in S33, the specific steps of triggering the life extension mechanism include:
[0045] S331, open the first switch K1, close the second switch K2, adjust the pull-down resistor to the first resistance value, and change the emitter voltage V of the infrared receiving tube. RD , calibrate the photoelectric sensor and determine whether the calibration of the photoelectric sensor is successful. If the calibration fails, continue the calibration through step S332;
[0046] S332, close the first switch K1, open the second switch K2, adjust the pull-down resistor to the second resistance value, and change the emitter voltage V of the infrared receiving tube. RD , recalibrate the photoelectric sensor, and determine whether the photoelectric sensor is calibrated successfully;
[0047] The step of judging whether the photoelectric sensor is calibrated successfully specifically includes the following steps:
[0048] The emitter voltage V RD The calibration success threshold V ref Make comparisons;
[0049] When V RD ≥V ref , it is considered that the photoelectric sensor is calibrated successfully, and the PWM signal duty cycle of the sensor transmitter is saved. The photoelectric sensor is used normally, and an alarm signal is sent to the host computer, and the photoelectric sensor is controlled by the host computer;
[0050] When V RD <V ref , the photoelectric sensor calibration is considered to have failed.
[0051] The beneficial effects brought by the embodiments provided by the present invention include:
[0052] The present invention is based on an MCU controller, and regulates the light intensity of the transmitting end and the voltage of the receiving end of the photoelectric sensor through a light intensity regulation module and a resistance regulation module, which can effectively delay the problem of shortening the life of the photoelectric sensor due to light decay, and enhance the stability and accuracy of the photoelectric sensor in various environments; the present invention receives the abnormal signal of the photoelectric sensor fed back by the MCU controller through a host computer, and sends a calibration instruction to the MCU controller to calibrate the photoelectric sensor, which can achieve early warning and handle the abnormal risk of the photoelectric sensor, reduce the troubleshooting and replacement work caused by the abnormal problem of the photoelectric sensor, and reduce the labor cost; the present invention has a simple structure and low cost, can be freely adjusted according to actual use conditions, is adaptable to many scenarios and is easy to implement. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, 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 invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0054] Figure 1 A schematic diagram of a circuit of a device for extending the service life of a photoelectric sensor provided by an embodiment of the present invention:
[0055] Figure 2 A schematic diagram of a device module for extending the service life of a photoelectric sensor provided by an embodiment of the present invention;
[0056] Figure 3 A schematic flow chart of a method for extending the service life of a photoelectric sensor provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0057] In order to make the objectives, technical solutions and advantages of the present disclosure more clearly understood, the present disclosure is further described in detail below in combination with specific embodiments and with reference to the accompanying drawings.
[0058] However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, the description of the known technology is omitted to avoid unnecessary confusion of the concepts of the present disclosure.
[0059] The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The term "comprising" used herein indicates the existence of features, steps, operations, but does not exclude the existence or addition of one or more other features. It should be noted that all terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art, unless otherwise defined. It should be noted that the terms used here should be interpreted as having meanings consistent with the context of this specification, and should not be interpreted in an idealized or overly rigid manner.
[0060] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0061] Example 1
[0062] like Figure 1-Figure 2 As shown, an embodiment of the present invention provides a device for extending the service life of a photoelectric sensor, including a photoelectric sensor, a light intensity adjustment module, an MCU controller, and a resistance adjustment module;
[0063] In some embodiments, the PWM end of the MCU controller is connected to the input end of the light intensity adjustment module, and the output end of the light intensity adjustment module is connected to the transmitting end of the photoelectric sensor, so as to adjust the duty cycle of the PWM signal output by the MCU controller and use the light intensity adjustment module to control the light emitting current of the transmitting end of the photoelectric sensor, thereby adjusting the light signal intensity of the transmitting end of the photoelectric sensor;
[0064] The ADC end of the MCU controller is connected to the receiving end of the photoelectric sensor to sample the voltage of the receiving end of the photoelectric sensor.
[0065] In this embodiment, the resistance adjustment module includes a first resistance adjustment unit, a second resistance adjustment unit, a first switch K1, and a second switch K2.
[0066] Specifically, the input end of the first resistance adjusting unit is connected to the first control end of the MCU controller through the first switch K1, and the output end of the first resistance adjusting unit is connected to the receiving end of the photoelectric sensor; the input end of the second resistance adjusting unit is connected to the second control end of the MCU controller through the second switch K2, and the output end of the second resistance adjusting unit is connected to the receiving end of the photoelectric sensor.
[0067] In some embodiments, the device further includes a host computer, which is connected to the MCU controller to receive an abnormal signal of the photoelectric sensor fed back by the MCU controller and to regulate the photoelectric sensor through the MCU controller.
[0068] In some embodiments, the light intensity adjustment unit includes a field effect transistor Q1, a resistor R1, a resistor R2, and a resistor R3;
[0069] Specifically, the drain of the field effect transistor Q1 is connected to the emitter end of the photoelectric sensor, the source of the field effect transistor Q1 is grounded through the resistor R1, and the gate of the field effect transistor Q1 is connected to the PWM end of the MCU controller through the resistor R2; one end of the resistor R3 is connected to the gate of the field effect transistor Q1, and the other end is grounded.
[0070] In some embodiments, the first regulating resistor unit includes a field effect transistor Q2, a resistor R4, a resistor R5, and a resistor R6;
[0071] Specifically, the drain of the field effect transistor Q2 is respectively connected to the transmitting end of the photoelectric sensor and the ADC end of the MCU controller, and the source of the field effect transistor Q2 is grounded through the resistor R4; the gate of the field effect transistor Q2 is sequentially connected to the resistor R5, the first switch K1 and the first control end of the MCU controller.
[0072] One end of the resistor R6 is connected to the first switch K1 , and the other end is grounded.
[0073] In some embodiments, the second regulating resistor unit includes a field effect transistor Q3, a resistor R7, a resistor R8, and a resistor R9;
[0074] Specifically, the drain of the field effect transistor Q3 is connected to the emitter end of the photoelectric sensor and the ADC end of the MCU controller respectively, and the source of the field effect transistor Q3 is grounded through the resistor R7; the gate of the field effect transistor Q3 is connected to the resistor R8, the second switch K2 and the second control end of the MCU controller in sequence; one end of the resistor R9 is connected to the second switch K2, and the other end is grounded;
[0075] In some embodiments, the transmitting end of the photoelectric sensor is an infrared transmitting tube, and the receiving end of the photoelectric sensor is an infrared receiving tube; the infrared receiving tube is a photosensitive triode;
[0076] Specifically, the anode of the infrared emitting tube is connected to the first power supply voltage terminal, and the cathode of the infrared emitting tube is connected to the PWM terminal of the MCU controller through the light intensity adjustment module; the collector of the infrared receiving tube is connected to the second power supply voltage terminal, and the emitter of the infrared receiving tube is respectively connected to the first resistance adjustment unit and the second resistance adjustment unit.
[0077] In this embodiment, the first power supply voltage is 5V, and the second power supply voltage is 3.3V.
[0078] Example 2
[0079] This embodiment provides a method for extending the service life of a photoelectric sensor, which is applied to the device as described in Embodiment 1, and includes:
[0080] Send calibration instructions to the MCU controller through the host computer and set the calibration success threshold V ref ;
[0081] After the MCU controller receives the calibration instruction, it samples the voltage at the receiving end of the photoelectric sensor through the ADC end of the MCU controller to obtain the sampled voltage V ADC ;
[0082] The sample voltage V ADC The calibration success threshold V ref For comparison, when V ADC ≥V ref , it is considered that the photoelectric sensor is in normal working condition and the photoelectric sensor does not need to be calibrated;
[0083] When V ADC <V ref , it is considered that the sensor has light attenuation, and the automatic calibration mechanism is triggered to calibrate the photoelectric sensor; if the calibration is successful, the PWM signal duty cycle of the sensor transmitter is saved and the photoelectric sensor is used normally; if the calibration fails, the life extension mechanism is triggered to recalibrate the photoelectric sensor.
[0084] In some embodiments, the specific steps of the automatic calibration mechanism include:
[0085] By adjusting the duty cycle of the PWM signal output by the MCU controller, the light signal intensity at the transmitting end of the photoelectric sensor is adjusted to change the emitter voltage V at the transmitting end of the photoelectric sensor. RD ;
[0086] The emitter voltage V RD The calibration success threshold V ref Make comparisons;
[0087] When V RD ≥V ref , the photoelectric sensor is considered to be calibrated successfully;
[0088] When V RD <V ref , the photoelectric sensor calibration is considered to have failed.
[0089] In this embodiment, by increasing the duty cycle of the PWM signal output by the MCU controller, the conduction time of the field effect transistor Q1 in the light intensity regulation module is increased, so that the light emitting current at the transmitting end of the photoelectric sensor becomes larger, so that the light signal intensity at the transmitting end of the photoelectric sensor is enhanced, thereby increasing the emitter voltage V RD becomes larger so that the photoelectric sensor can work normally.
[0090] Specifically, the emitter voltage V RD The calculation formula is:
[0091] V RD =V ADC
[0092] V ADC =I E ·R E
[0093] I E =(1+β)·I B
[0094] In the formula, I E is the emitter current of the infrared receiving tube, I B is the luminous current of the infrared emitting tube; R E is the pull-down resistor of the infrared receiving tube; β is the amplification factor of the infrared receiving tube;
[0095] In this embodiment, the pull-down resistor R E It can be 10K, 15K, 30K. When the calibration success threshold V is set ref When R E Take 10K.
[0096] Specifically, the luminous current I of the infrared emitting tube B The calculation formula is:
[0097]
[0098] Where V f is the on-state voltage of the infrared emitting tube; PWM is the duty cycle of the PWM signal; ɑ is the light decay coefficient; θ1 is the influence coefficient of the installation distance and angle offset of the photoelectric sensor (0≦θ1≦1); θ2 is the dust and environmental influence coefficient.
[0099] In some embodiments, the specific steps of triggering the life extension mechanism include:
[0100] Open the first switch K1, close the second switch K2, adjust the pull-down resistor to 15K, trigger the automatic calibration mechanism, and calibrate the photoelectric sensor;
[0101] When the photoelectric sensor is calibrated successfully, the PWM signal duty cycle can be adjusted back to 0%-100%, and the PWM signal duty cycle of the sensor transmitter is saved. The photoelectric sensor is used normally, and an alarm signal is sent to the host computer, and the photoelectric sensor is controlled by the host computer;
[0102] When the calibration of the photoelectric sensor fails, the first switch K1 is closed, the second switch K2 is opened, the pull-down resistor is adjusted to 30K, the automatic calibration mechanism is triggered, and the photoelectric sensor is recalibrated;
[0103] If the calibration is successful, the duty cycle of the PWM signal at the sensor transmitter is saved and the photoelectric sensor is used normally;
[0104] If the calibration fails, it is considered that the photoelectric sensor can no longer be used.
[0105] In this embodiment, the photoelectric sensor sends an alarm signal to the host computer to remind the user that the photoelectric sensor has experienced light decay and needs to prolong its life. The host computer controls the start and stop of the photoelectric sensor according to actual conditions and reduces the use of the sensor as much as possible.
[0106] In summary, the present invention can effectively delay the problem of shortening the life of the photoelectric sensor due to light decay through the mode of light intensity adjustment and resistance adjustment, and enhance the stability and accuracy of the photoelectric sensor in various environments; before the photoelectric sensor is calibrated, the first switch K1 and the second switch K2 are both opened, and the pull-down resistor R E When the life extension mechanism is triggered, the pull-down resistor R E The pull-down resistor R E Adjust to a larger resistance value to enhance the effect of the life extension mechanism. The present invention receives the abnormal signal of the photoelectric sensor fed back by the MCU controller through the host computer, and sends a calibration instruction to the MCU controller to calibrate the photoelectric sensor, which can achieve early warning and remote processing of the abnormal risk of the photoelectric sensor, reduce the troubleshooting and replacement work caused by the abnormal problem of the photoelectric sensor, and reduce labor costs; the present invention has a simple structure, low cost, can be freely adjusted according to actual use conditions, adapts to many scenarios and is easy to implement.
[0107] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A device for extending the service life of a photoelectric sensor, comprising a photoelectric sensor, characterized in that: It also includes light intensity adjustment module and MCU controller; The PWM end of the MCU controller is connected to the input end of the light intensity adjustment module, and the output end of the light intensity adjustment module is connected to the transmitting end of the photoelectric sensor, so as to adjust the duty cycle of the PWM signal output by the MCU controller and use the light intensity adjustment module to control the light emitting current of the transmitting end of the photoelectric sensor, thereby adjusting the light signal intensity of the transmitting end of the photoelectric sensor; The ADC end of the MCU controller is connected to the receiving end of the photoelectric sensor to sample the voltage of the receiving end of the photoelectric sensor.
2. The device according to claim 1, characterized in that It also includes a resistance adjustment module, which includes a first resistance adjustment unit, a second resistance adjustment unit, a first switch K1, and a second switch K2; the input end of the first resistance adjustment unit is connected to the first control end of the MCU controller through the first switch K1, and the output end of the first resistance adjustment unit is connected to the receiving end of the photoelectric sensor; The input end of the second resistance adjusting unit is connected to the second control end of the MCU controller through the second switch K2, and the output end of the second resistance adjusting unit is connected to the receiving end of the photoelectric sensor.
3. The device according to claim 1, characterized in that The device also includes a host computer, which is connected to the MCU controller and is used to receive an abnormal signal of the photoelectric sensor fed back by the MCU controller, and to regulate the photoelectric sensor through the MCU controller.
4. The device according to claim 1, characterized in that The light intensity adjustment unit includes a field effect transistor Q1, a resistor R1, a resistor R2, and a resistor R3; The drain of the field effect tube Q1 is connected to the emitter end of the photoelectric sensor, the source of the field effect tube Q1 is grounded through a resistor R1, and the gate of the field effect tube Q1 is connected to the PWM end of the MCU controller through a resistor R2; one end of the resistor R3 is connected to the gate of the field effect tube Q1, and the other end is grounded.
5. The device according to claim 2, characterized in that The first regulating resistor unit includes a field effect transistor Q2, a resistor R4, a resistor R5, and a resistor R6; The drain of the field effect tube Q2 is connected to the emitter of the photoelectric sensor, and the source of the field effect tube Q2 is grounded through the resistor R4; the gate of the field effect tube Q2 is connected to the resistor R5, the first switch K1 and the first control terminal of the MCU controller in sequence; One end of the resistor R6 is connected to the first switch K1 , and the other end is grounded; the ADC end of the MCU controller is connected to the drain of the field effect transistor Q2 .
6. The device according to claim 2, characterized in that The second regulating resistor unit includes a field effect transistor Q3, a resistor R7, a resistor R8, and a resistor R9; The drain of the field effect tube Q3 is connected to the emitter of the photoelectric sensor, and the source of the field effect tube Q3 is grounded through the resistor R7; the gate of the field effect tube Q3 is connected to the resistor R8, the second switch K2 and the second control terminal of the MCU controller in sequence; One end of the resistor R9 is connected to the second switch K2, and the other end is grounded; the ADC end of the MCU controller is connected to the drain of the field effect transistor Q3.
7. The device according to claim 2, characterized in that The transmitting end of the photoelectric sensor is an infrared transmitting tube, and the receiving end of the photoelectric sensor is an infrared receiving tube; the infrared receiving tube adopts a photosensitive triode; The anode of the infrared emitting tube is connected to the first power supply voltage terminal, and the cathode of the infrared emitting tube is connected to the PWM terminal of the MCU controller through the light intensity adjustment module; The collector of the infrared receiving tube is connected to the second power supply voltage terminal, and the emitter of the infrared receiving tube is connected to the first resistance adjustment unit and the second resistance adjustment unit respectively.
8. A method for extending the service life of a photoelectric sensor, applied to the device according to any one of claims 1 to 7, characterized in that: include: S1. Send calibration instructions to the MCU controller through the host computer and set the calibration success threshold V ref ; S2. After the MCU controller receives the calibration command, it samples the voltage at the receiving end of the photoelectric sensor through the ADC end of the MCU controller to obtain the sampled voltage V ADC ; S3, judging the working state of the photoelectric sensor, and determining whether the photoelectric sensor needs to be calibrated according to the working state; The S3 specifically includes the following steps: S31, the sampling voltage V ADC The calibration success threshold V ref Make comparisons; S32, when V ADC ≥V ref , it is considered that the photoelectric sensor is in normal working condition and the photoelectric sensor does not need to be calibrated; S33, when V ADC <V ref , the photoelectric sensor is considered to be in a light decay state, and the automatic calibration mechanism is triggered to calibrate the photoelectric sensor. If the calibration is successful, the PWM signal duty cycle of the sensor transmitter is saved and the photoelectric sensor is used normally; if the calibration fails, the life extension mechanism is triggered to recalibrate the photoelectric sensor.
9. The method according to claim 8, characterized in that In S33, the specific steps of the automatic calibration mechanism include: By adjusting the duty cycle of the PWM signal output by the MCU controller, the light signal intensity at the transmitting end of the photoelectric sensor is adjusted to change the emitter voltage V at the transmitting end of the photoelectric sensor. RD ; The emitter voltage V RD The calibration success threshold V ref Make comparisons; When V RD ≥V ref , the photoelectric sensor is considered to be calibrated successfully; When V RD <V ref , it is considered that the photoelectric sensor calibration has failed; The emitter voltage V of the infrared receiving tube RD The calculation formula is: V RD =V ADC V ADC =I E ·R E AND E =(1+β)·I B In the formula, I E is the emitter current of the infrared receiving tube, I B is the luminous current of the infrared emitting tube; R E is the pull-down resistor of the infrared receiving tube; β is the amplification factor of the infrared receiving tube; The luminous current I of the infrared emitting tube B The calculation formula is: Where V is the first power supply voltage, V f is the on-state voltage of the infrared emitting tube; PWM is the duty cycle of the PWM signal; ɑ is the light decay coefficient; θ1 is the influence coefficient of the installation distance and angle offset of the photoelectric sensor (0≦θ1≦1); θ2 is the dust and environmental influence coefficient.
10. The method according to claim 8, characterized in that In S33, the specific steps of triggering the life extension mechanism include: S331, open the first switch K1, close the second switch K2, adjust the pull-down resistor to the first resistance value, and change the emitter voltage V of the infrared receiving tube. RD , calibrate the photoelectric sensor and determine whether the calibration of the photoelectric sensor is successful. If the calibration fails, continue the calibration through step S332; S332, close the first switch K1, open the second switch K2, adjust the pull-down resistor to the second resistance value, and change the emitter voltage V of the infrared receiving tube. RD , recalibrate the photoelectric sensor, and determine whether the photoelectric sensor is calibrated successfully; The step of judging whether the photoelectric sensor is calibrated successfully specifically includes the following steps: The emitter voltage V RD The calibration success threshold V ref Make comparisons; When V RD ≥V ref , it is considered that the photoelectric sensor is calibrated successfully, and the PWM signal duty cycle of the sensor transmitter is saved. The photoelectric sensor is used normally, and an alarm signal is sent to the host computer, and the photoelectric sensor is controlled by the host computer; When V RD <V ref , the photoelectric sensor calibration is considered to have failed.
Citation Information
Patent Citations
Paper currency detection method and equipment and self-adaptive regulating method and device for photoelectric sensor
CN102708617B
Mine infrared gas sensor with automatic calibration function
CN102419311A
Light projection adjustment system for photoelectric sensor
CN110312342A
Light emitting diode driving circuit, light emitting circuit and light emitting panel
CN219609991U
LED lighting that can reduce deterioration and extend life by defective LED elements
KR102340887B1