Parameter configuration system and configuration method
Through the communication connection between the power supply lead of the photoelectric sensor and the parameter configuration module, the parameter configuration is configured using the amplitude of the power supply voltage, which solves the problem of increasing cost and volume of the photoelectric sensor in the prior art, and realizes efficient and low-complexity parameter configuration.
Patent Information
- Application Number
- CN202510531384.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-25
- Publication Date
- 2025-08-12
AI Technical Summary
The existing photoelectric sensor parameter configuration method requires additional interfaces and devices, resulting in increased product cost and volume, and cannot be suitable for scenarios with strict cost and volume requirements.
The communication connection with the parameter configuration module is achieved through the power supply lead of the photoelectric sensor, and the amplitude change of the power supply voltage is resolved into a high and low level sequence, and the corresponding command is executed accordingly, to avoid additional configuration of special communication pins.
It realizes parameter configuration without increasing the interface and volume, and is suitable for strong electromagnetic interference environments, reducing operation complexity and improving rapid debugging efficiency.
Smart Images

Figure CN120468960A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of sensor technology, and specifically relates to a parameter configuration system and configuration method. Background Art
[0002] A photoelectric sensor is a device that senses light and converts it into electrical signals. It detects the presence or position of an object by sensing changes in light intensity through an internal photosensitive element, converting the light signal into an electrical signal. Based on the light propagation and reception paths, these sensors can be categorized as diffuse, through-beam, and regressive reflective. They are widely used in industrial automation. In specific applications, photoelectric sensor parameters often require configuration based on specific needs, such as output mode selection, detection distance setting, hysteresis setting, and transmission frequency adjustment.
[0003] To meet the needs of these scenarios, existing products mainly add interactive components such as buttons, knobs, indicator lights, and display screens to the products, allowing users to directly operate the sensors to complete parameter settings at the application site, or equip the products with interfaces such as RS485, RS422, and IO-Link, so that users can configure the parameters of the photoelectric sensors with the help of a host computer or other devices. However, this method not only significantly increases product costs, but also increases product size due to the addition of additional devices and leads. It is not suitable for photoelectric sensor products with strict requirements on cost and size. Summary of the Invention
[0004] This application provides a parameter configuration system and configuration method, which can configure the parameters of photoelectric sensors according to actual scenario requirements without increasing the number of interfaces, cables and product volume.
[0005] In order to solve the above technical problems, the present application provides a parameter configuration system, which includes a sensor module provided with a power lead, and a parameter configuration module communicatively connected to the sensor module via the power lead;
[0006] The sensor module is used to receive the power supply voltage transmitted by the parameter configuration module through the power supply lead, and analyze the power supply voltage into a high and low level sequence according to the amplitude change of the power supply voltage;
[0007] The sensor module is also used to compare the high and low level sequence with a preset instruction sequence. When the high and low level sequence matches the preset instruction sequence, the instruction corresponding to the high and low level sequence is executed; when the high and low level sequence does not match the preset instruction sequence, no response is given to the high and low level sequence.
[0008] As a further improvement of the present application, the parameter configuration module includes a transmission unit connected to the power lead for providing a power supply voltage to the sensor module;
[0009] The transmission unit includes a first transmission circuit for transmitting a first voltage to the sensor module, and a second transmission circuit for transmitting a second voltage to the sensor module.
[0010] As a further improvement of the present application, the first transmission circuit includes a first unidirectional conductive element connected to the power lead, and a first load switch connected to the first unidirectional conductive element;
[0011] The second transmission circuit includes a second unidirectional conductive element connected between the power lead and the first unidirectional conductive element, and a second load switch connected to the second unidirectional conductive element;
[0012] The enable pin of the second load switch is in a continuously enabled state. When the enable pin of the first load switch is enabled, the transmission unit transmits a first voltage to the sensor module. When the enable pin of the first load switch is not enabled, the transmission unit transmits a second voltage to the sensor module.
[0013] As a further improvement of the present application, a voltage dividing resistor element and a semiconductor switch element are further provided between the transmission unit and the power lead;
[0014] The voltage dividing resistor element includes a first resistor connected to the semiconductor switch element, and a second resistor connected to the first resistor and the transmission unit, a first end of the semiconductor switch element is connected to the power lead, a second end of the semiconductor switch element is grounded, and a third end of the semiconductor switch element is connected to the first resistor;
[0015] The parameter configuration module is further configured to detect voltage information transmitted by the transmission unit through the power lead. When the semiconductor switch element is turned off, the parameter configuration module detects a first level. When the semiconductor switch element is turned on, the parameter configuration module detects a second level.
[0016] As a further improvement of the present application, the sensor module includes a power supply unit for receiving the power supply voltage, and a controller unit for parsing the changing power supply voltage into a sequence of high and low levels;
[0017] The controller unit includes at least a controller and a comparator. The comparator is used to receive the power supply voltage divider value at the current moment, compare the power supply voltage divider value with a preset voltage threshold, and output a first level to the controller if the power supply voltage divider value at the current moment is higher than the voltage threshold; if the power supply voltage divider value at the current moment is lower than the voltage threshold, output a second level to the controller, so that the controller generates the required high and low level sequence according to the output result of the comparator.
[0018] As a further improvement of the present application, the controller unit further includes a third resistor connected to the power supply unit, and a fourth resistor connected to the third resistor, and the other end of the fourth resistor is grounded;
[0019] The non-inverting input terminal of the comparator is connected between the third resistor and the fourth resistor, and a first capacitor is further arranged between the third resistor and the non-inverting input terminal of the comparator. The other end of the first capacitor is grounded, the inverting input terminal of the comparator is connected to the reference voltage, and the output terminal of the comparator is connected to the controller.
[0020] As a further improvement of the present application, the first level is a high level, and the second level is a low level.
[0021] As a further improvement of the present application, the sensor module further includes an indication unit, which is used to indicate whether the sensor module responds to the high and low level sequence.
[0022] As a further improvement of the present application, the parameter configuration module further includes an LED indication unit and a photoelectric receiving unit;
[0023] The sensor module is further configured to transmit a light signal to the photoelectric receiving unit in response to the high and low level sequence, and the LED indicator unit is configured to indicate whether the photoelectric receiving unit has received the light signal transmitted by the sensor module.
[0024] The present application also provides a parameter configuration method, which is applied to a parameter configuration device and a photoelectric sensor provided with a power lead, wherein the parameter configuration device is communicatively connected to the photoelectric sensor via the power lead, and the method comprises the following steps:
[0025] receiving a power supply voltage transmitted by the parameter configuration device through the power lead;
[0026] parsing the power supply voltage transmitted by the parameter configuration device into a high and low level sequence according to the amplitude change of the power supply voltage;
[0027] The high and low level sequence is compared with a preset instruction sequence. When the high and low level sequence matches the preset instruction sequence, the instruction corresponding to the high and low level sequence is executed; when the high and low level sequence does not match the preset instruction sequence, no response is given to the high and low level sequence.
[0028] The parameter configuration system and configuration method provided in this application have the following beneficial effects:
[0029] This application does not require additional configuration of special communication pins. By reusing the power lead of the photoelectric sensor, a two-way communication connection between the photoelectric sensor and the parameter configuration device can be achieved. This allows the parameter configuration device to send high and low level sequences to the photoelectric sensor while ensuring the normal operation of the photoelectric sensor, and also supports the photoelectric sensor to feedback configuration results or working status and other information. Without adding a dedicated communication interface, two-way interaction between the photoelectric sensor and the parameter configuration device is achieved, reducing the overall volume of the sensor; the amplitude change of the power supply voltage is used as the basis for judging the high and low levels, and it has a stronger noise tolerance, which is suitable for parameter configuration in strong electromagnetic interference environments in industrial sites; it is compatible with the power supply system of existing photoelectric sensors, and the dual needs of photoelectric sensor power supply and parameter configuration can be achieved through the same power lead, reducing the operational complexity of multi-lead connection and effectively improving the efficiency of on-site rapid debugging. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only part of the embodiments of the present application, rather than all the embodiments. For ordinary technicians in this field, without paying any creative work, other drawings obtained based on these drawings are all within the scope of protection of this application.
[0031] Figure 1 It is a structural diagram of the parameter configuration system provided in an embodiment of the present application;
[0032] Figure 2 This is a schematic diagram of the structure of the power supply lead in the parameter configuration system provided in an embodiment of the present application;
[0033] Figure 3 This is a schematic diagram of the structure of a transmission unit in a parameter configuration system provided in an embodiment of the present application;
[0034] Figure 4 This is a schematic diagram of the structure of the controller unit in the parameter configuration system provided by an embodiment of the present application;
[0035] Figure 5 This is a schematic diagram of the structure of a semiconductor switch element in the parameter configuration system provided in an embodiment of the present application;
[0036] Figure 6 This is a flow chart of the parameter configuration method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0037] In order to make the purpose, technical solutions and advantages of this application more clearly understood, this application is further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.
[0038] In order to make the description of the contents of this disclosure more detailed and complete, the following is an illustrative description of the implementation methods and specific examples of this application; however, this is not the only form of implementing or using the specific embodiments of this application. The implementation methods cover the features of multiple specific embodiments and the method steps and their sequence for constructing and operating these specific embodiments. However, other specific embodiments can also be used to achieve the same or equal functions and step sequences. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0039] It should be noted that the terms "first," "second," and the like in the specification and claims of this application and the accompanying drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, such that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0040] In the description of the embodiments of the present application, unless otherwise specified, " / " means or, for example, A / B can mean A or B; "and / or" in the text is merely a description of the association relationship of associated objects, indicating that three relationships may exist, for example, A and / or B can mean: A exists alone, A and B exist at the same time, and B exists alone. In addition, in the description of the embodiments of the present application, "multiple" refers to two or more than two, and other quantifiers should be understood similarly. The preferred embodiments described herein are only used to illustrate and explain the present application, and are not used to limit the present application. In addition, the embodiments of the present application and the features in the embodiments may be combined with each other unless there is a conflict.
[0041] A photoelectric sensor is a device that senses light and converts it into electrical signals. It detects the presence or position of an object by sensing changes in light intensity through an internal photosensitive element. Based on the light propagation and reception paths, these sensors can be categorized as diffuse, through-beam, and regressive reflective. They are widely used in industrial automation. In specific applications, photoelectric sensor parameters often require configuration based on specific needs, such as output mode selection, detection distance setting, hysteresis setting, and transmission frequency adjustment.
[0042] To meet the needs of these scenarios, existing products mainly add interactive components such as buttons, knobs, indicator lights, and display screens to the products, allowing users to directly operate the sensors to complete parameter settings at the application site, or equip the products with interfaces such as RS485, RS422, and IO-Link, so that users can configure the parameters of the photoelectric sensors with the help of a host computer or other devices. However, this method not only significantly increases product costs, but also increases product size due to the need to add additional functions, devices, and leads. This makes it unsuitable for photoelectric sensor products with strict requirements on cost and size.
[0043] Alternatively, the company can add product models that are suitable for different scenarios, or even directly customize specific models for major customers. However, this approach will increase the manufacturer's burden on product management and inventory management, and will require a certain amount of development resources to respond to demand, making it difficult to achieve efficient and economical product supply.
[0044] In view of this, please refer to Figures 1-6 The embodiment of the present application proposes a parameter configuration system and configuration method, which can configure the parameters of the photoelectric sensor according to the actual scene requirements without increasing the number of interfaces, cables and product volume.
[0045] Please refer to Figure 1 , is a structural diagram of a parameter configuration system provided in an embodiment of the present application, wherein the parameter configuration system includes a sensor module provided with a power lead, and a parameter configuration module communicatively connected to the sensor module via the power lead.
[0046] It is understandable that common photoelectric sensors are usually equipped with power leads and output leads. In particular, for the transmitting end of the through-beam photoelectric sensor, only a power lead is usually provided. However, the present application can directly realize the communication connection with the parameter configuration device through the power lead of the photoelectric sensor without increasing the number of interfaces and cables. While providing power supply, it can also realize data transmission and thus perform parameter configuration and firmware upgrades on the sensor, effectively reducing development costs.
[0047] For details, please refer to Figure 2The parameter configuration system includes a parameter configuration device and at least one photoelectric sensor that needs to be configured with parameters. Several photoelectric sensors that need to be configured with parameters are communicated with the parameter configuration device through their own power leads. The parameter configuration device can supply power to the photoelectric sensors while configuring the parameters of the photoelectric sensors.
[0048] Taking at least one sensor module as an example, since photoelectric sensors are usually allowed to operate under a relatively wide power supply voltage, such as 10-30V, 24V±10%, etc., it is necessary to select a higher first voltage VH and a lower second voltage VL within the range of the operating voltage allowed by the photoelectric sensor. That is to say, although there is a difference in higher and lower values between the first voltage and VH and the second voltage VL, in principle, it must be within the range of the operating voltage allowed by the current photoelectric sensor to avoid the first voltage being too high or the second voltage being too low affecting the normal power supply and operation of the photoelectric sensor.
[0049] As an optional implementation, the present application realizes the communication connection between the sensor module and the parameter configuration module through the power lead, and the parameter configuration module transmits a high and low level sequence to the sensor module by changing the power supply voltage output to the photoelectric sensor.
[0050] Furthermore, the sensor module is used to receive the power supply voltage transmitted by the parameter configuration module through the power lead, and parse the transmitted power supply voltage into a high and low level sequence according to the amplitude change of the power supply voltage, that is, the change of the voltage value; if the power supply voltage transmitted by the parameter configuration module to the sensor module at the current moment is the first voltage, the second voltage, and the first voltage, the photoelectric sensor can, under normal operation, identify the high and low level sequence at the current moment as high level-low level-high level (that is, the binary sequence "101") according to the voltage value change of the power supply voltage.
[0051] Of course, the present application does not impose further restrictions on the high and low level sequences in the actual transmission process. The above description is only a specific embodiment of how to parse the power supply voltage into a high and low level sequence according to the amplitude change of the power supply voltage, and does not serve as any restriction on the high and low level sequence. Those skilled in the art should be aware of this.
[0052] After the transmitted power supply voltage is parsed into a high and low level sequence, the sensor module is also used to compare the high and low level sequence with a preset instruction sequence. When the high and low level sequence matches the preset instruction sequence, the instruction corresponding to the high and low level sequence is executed; when the high and low level sequence does not match the preset instruction sequence, no response is given to the high and low level sequence.
[0053] It should be noted that the photoelectric sensor needs to be provided with a supported command list, which is a set of predefined instruction sequences used to control various functions and operations of the photoelectric sensor to achieve different parameter configurations and working modes.
[0054] When the photoelectric sensor receives a high and low level sequence, it will compare the received high and low level sequence with the instruction sequence stored in the command list. If they match, it will perform the corresponding parameter modification or configuration operation. If they do not match, it will report an error through the indicator light or not perform any operation. That is, when the high and low level sequence does not match the preset instruction sequence, it will not respond to the received high and low level sequence.
[0055] This application does not require additional configuration of dedicated communication pins, and uses the amplitude change of the power supply voltage as the basis for judging high and low levels. It has stronger noise tolerance and is suitable for parameter configuration in strong electromagnetic interference environments in industrial sites. Communication connection with parameter configuration equipment can be achieved only through the power lead of the sensor itself, reducing the overall volume of the sensor and being suitable for miniaturized, low-cost photoelectric sensors. It is also compatible with the power supply system of existing photoelectric sensors. Users can achieve the dual needs of power supply and parameter configuration through the same power lead, reducing the operational complexity of multi-lead connection and effectively improving the efficiency of on-site rapid debugging.
[0056] As an optional embodiment, the parameter configuration module provided in the present application includes a transmission unit connected to the power lead for providing a power supply voltage to the sensor module, the transmission unit includes a first transmission circuit for transmitting a first voltage to the sensor module, and a second transmission circuit for transmitting a second voltage to the sensor module.
[0057] For details, please refer to Figure 3 , which is a structural schematic diagram of the transmission unit in the parameter configuration system provided in an embodiment of the present application. The first transmission circuit includes a first unidirectional conductive element D1 connected to the power lead and a first load switch connected in series with the first unidirectional conductive element D1. The second transmission circuit includes a second unidirectional conductive element D2 connected between the power lead and the first unidirectional conductive element D1, and a second load switch connected to the second unidirectional conductive element D2.
[0058] Exemplarily, the present application sets the first unidirectional conductive element D1 and the second unidirectional conductive element D2 in the form of diodes, connects the cathode of the first unidirectional conductive element D1 to the power lead, connects the anode of the first unidirectional conductive element D1 to the first load switch, connects the cathode of the second unidirectional conductive element D2 between the power lead and the first unidirectional conductive element D1, and connects the anode of the second unidirectional conductive element D2 to the second load switch. It can be observed that the enable pin of the first load switch is VH_EN and the enable pin of the second load switch is VL_EN.
[0059] Of course, in actual applications, the first unidirectional conductive element D1 and the second unidirectional conductive element D2 may not be provided, but the first load switch and the second load switch may be directly enabled mutually exclusively, that is, when the enable pin VH_EN of the first load switch is enabled, the enable pin VL_EN of the second load switch is not enabled, and when the enable pin VH_EN of the first load switch is not enabled, the enable pin VL_EN of the second load switch is enabled. In this way, the first voltage and the second voltage are transmitted to the sensor module according to actual needs, thereby realizing switching between high voltage and low voltage.
[0060] However, mutually exclusive enabling of the first load switch and the second load switch may cause interruption in the power supply to the sensor, resulting in restart of the photoelectric sensor. Therefore, the present application sets a first unidirectional conductive element D1 connected to the first load switch, and sets a second unidirectional conductive element D2 connected to the second load switch, and uses the unidirectional conduction characteristics of the diode to protect the second load switch.
[0061] Specifically, when the enable pin VH_EN of the first load switch is enabled, the first load switch is turned on, the first unidirectional conductive element D1 is turned on, and the power supply voltage transmitted to the sensor module and the voltage output by the parameter configuration module differ by almost only a voltage drop of the first unidirectional conductive element D1. The second unidirectional conductive element D2 will be cut off because the cathode voltage is higher than the anode voltage. Therefore, even if the enable pin VL_EN of the second load switch is continuously enabled and the second load switch is continuously turned on, it will not be affected by the higher voltage output by the parameter configuration module.
[0062] Preferably, the present application sets the enable pin of the second load switch to a continuously enabled state, so that when the enable pin of the first load switch is enabled, the transmission unit transmits the first voltage to the sensor module through the first transmission circuit, and when the enable pin of the first load switch is not enabled, the transmission unit transmits the second voltage to the sensor module through the second transmission circuit, thereby realizing uninterrupted switching between the first voltage and the second voltage, avoiding the restart phenomenon of the photoelectric sensor caused by intermittent power supply.
[0063] As an optional implementation, the sensor module provided in the present application includes a power supply unit for receiving the power supply voltage, and a controller unit for parsing the changing power supply voltage into a high and low level sequence.
[0064] For example, please refer to Figure 4 , which is a structural diagram of the controller unit in the parameter configuration system provided in an embodiment of the present application. The controller unit includes at least a controller and a comparator U1A. The present application receives the power supply voltage divider value at the current moment through the comparator U1A, compares the power supply voltage divider value at the current moment with the preset voltage threshold, and outputs the first level or the second level.
[0065] It should be noted that when the voltage transmitted by the parameter configuration module is too high, the transmitted power supply voltage needs to be divided first, so as to divide it into a voltage range that can be detected by the controller unit. In this application, the value after the power supply voltage is divided is called the power supply voltage divider value, and the power supply voltage divider value is compared with the preset voltage threshold. Those skilled in the art should be aware of this.
[0066] In an optional embodiment, if the power supply voltage divider value at the current moment is higher than a preset voltage threshold, a first level is output to the controller; if the power supply voltage divider value at the current moment is lower than the voltage threshold, a second level is output to the controller, so that the controller generates the required high and low level sequence according to the output result of the comparator U1A.
[0067] For details, please refer to Figure 2 In addition to the above-mentioned controller and comparator U1A, the controller unit provided in the present application also includes a third resistor R3 connected to the power supply unit, and a fourth resistor R4 connected to the third resistor R3. In the present application, the other end of the fourth resistor R4 is grounded, and the power supply voltage is divided by the third resistor R3 and the fourth resistor R4. It can be observed that at this time, the same-direction input end of the comparator U1A is connected between the third resistor R3 and the fourth resistor R4. The present application does not impose too many restrictions on the specific resistance values of the above-mentioned third resistor R3 and the fourth resistor R4.
[0068] Preferably, the present application further provides a first capacitor C1 between the third resistor R3 and the same-direction input terminal of the comparator U1A, and the other end of the first capacitor C1 is grounded. The first capacitor C1 filters out small and rapid fluctuations in the power supply voltage, thereby playing a filtering role. The reverse input terminal of the comparator U1A is connected to the reference voltage Vref, and the output terminal of the comparator U1A is connected to the controller so that the controller generates the required high and low level sequence according to the output result of the comparator U1A.
[0069] It is understandable that the controller unit selected for the photoelectric sensor usually has a built-in comparator, so the built-in comparator can be directly applied to compare the current power supply voltage divider value with the preset voltage threshold to output the first level or the second level. Those skilled in the art should know this.
[0070] In a specific embodiment provided, the above-mentioned first level is a high level and the second level is a low level, that is, if the power supply voltage divider value at the current moment is higher than the preset voltage threshold, a high level is output to the controller; if the power supply voltage divider value at the current moment is lower than the voltage threshold, a low level is output to the controller, so that the controller generates the required high and low level sequence according to the output result of the comparator.
[0071] As an optional implementation, when the sensor module executes the high and low level sequence, or does not respond to the high and low level sequence, clear feedback is required so that the staff can debug or reconfigure it. For the photoelectric sensor that has an indicator light, that is, when the sensor module itself includes an indication unit, the indication unit can be used to indicate whether the sensor module responds to the high and low level sequence, such as setting the on and off combination of the indicator light in the indication unit as an indication of whether the high and low level sequence is responded to.
[0072] Of course, for photoelectric sensors without an indicator unit, such as the transmitting end of a through-beam photoelectric sensor, the on-off combination of the transmitting tube in the transmitting end can be used as an indicator of whether to respond to the high and low level sequence. For photoelectric sensors that use invisible light (such as infrared light) for detection, this application also adds an LED indicator unit and a photoelectric receiving unit inside the parameter configuration module.
[0073] Specifically, when the sensor module responds to the high and low level sequence, the transmitting end of the sensor module is also used to transmit an optical signal to the photoelectric receiving unit of the parameter configuration module, and then indicate through the LED indicator unit whether the photoelectric receiving unit has received the optical signal sent by the sensor module.
[0074] It can be understood that the LED indicator unit and photoelectric receiving unit added inside the above-mentioned parameter configuration module can refer to the setting form of the receiving end and indicator unit inside the common photoelectric sensor. This application does not elaborate on the specific setting form and specific circuit structure of the above-mentioned LED indicator unit and photoelectric receiving unit.
[0075] As an optional implementation, the present application can also realize the communication between the sensor module and the parameter configuration module through the power lead, please refer to Figure 5 , is a schematic diagram of the structure of a semiconductor switch element in the parameter configuration system provided in an embodiment of the present application. In the present application, a voltage divider resistor element and a semiconductor switch element Q1 are further provided between the transmission unit and the power lead.
[0076] In an embodiment of the present application, the voltage-dividing resistor element includes a first resistor R1 connected to the semiconductor switching element Q1, and a second resistor R2 connected to the first resistor R1 and the transmission unit. The present application connects the first end of the semiconductor switching element Q1 to the power lead, grounds the second end of the semiconductor switching element Q1, and connects the third end of the semiconductor switching element Q1 to the first resistor R1.
[0077] The present application adds a first resistor R1 and a semiconductor switch element Q1 at the sensor module end, and adds a second resistor R2 at the parameter configuration module end to ensure that when the power supply voltage VOUT transmitted from the parameter configuration module to the sensor module continues to be a higher voltage, that is, when the parameter configuration module does not transmit data to the sensor module but only supplies power to the sensor module, data is transmitted from the sensor module to the parameter configuration module.
[0078] Specifically, the parameter configuration module detects the voltage information transmitted by the transmission unit through the power lead, that is, detects the high and low voltages transmitted by the transmission unit. When CTRL is at a low level and the semiconductor switch element Q1 is turned off, the VOUT of the parameter configuration module is detected as a higher voltage. When CTRL is at a high level and the semiconductor switch element Q1 is turned on, VOUT is the voltage value after the first resistor R1 and the second resistor R2 are divided. That is to say, at this time, the VOUT of the parameter configuration module is detected as a lower voltage. However, it should be noted that the values of the first resistor R1 and the second resistor R2 need to ensure that the photoelectric sensor can operate normally even when a lower voltage is transmitted to the parameter configuration module.
[0079] In this way, the photoelectric sensor further controls the off and on states of the semiconductor switch element Q1 by controlling the CTRL pin. The parameter configuration module can receive the first and second levels transmitted by the photoelectric sensor by detecting the voltage amplitude of the VOUT signal. That is to say, when the semiconductor switch element Q1 is off, the parameter configuration module detects the first level, and when the semiconductor switch element Q1 is on, the parameter configuration module detects the second level. As a result, the "high" and "low" levels are transmitted to the parameter configuration module through the photoelectric sensor, further realizing data transmission from the photoelectric sensor to the parameter configuration device, thereby realizing a two-way communication connection between the photoelectric sensor and the parameter configuration device through the power lead.
[0080] In an optional embodiment, the semiconductor switching element Q1 can be set to a triode or a field effect tube. Taking the field effect tube as an example, the present application sets the source of the field effect tube Q1 to be grounded, the gate of the field effect tube Q1 is connected to the CTRL pin, and the drain of the field effect tube Q1 is connected to the first resistor R1. Of course, it is also feasible to set the semiconductor switching element Q1 to a triode, and the present application does not impose too many restrictions on this.
[0081] Based on the above parameter configuration system, the present application also provides a parameter configuration method, which is applied to a parameter configuration device and a photoelectric sensor provided with a power lead. The parameter configuration device is connected to the photoelectric sensor through the power lead. Please refer to Figure 6 , is a flow chart of a photoelectric sensor control method provided in an embodiment of the present application, the method comprising the following steps:
[0082] S1: receiving a power supply voltage transmitted by the parameter configuration device through the power lead;
[0083] S2: parsing the power supply voltage transmitted by the parameter configuration device into a high and low level sequence according to the amplitude change of the power supply voltage;
[0084] S3: Compare the high and low level sequence with a preset instruction sequence. When the high and low level sequence matches the preset instruction sequence, execute the instruction corresponding to the high and low level sequence; when the high and low level sequence does not match the preset instruction sequence, do not respond to the high and low level sequence.
[0085] For other details about how the above technical solutions are implemented in each step of the above parameter configuration method, please refer to the description of the parameter configuration system provided in the above application embodiment, which will not be repeated here.
[0086] In the several embodiments provided in this application, it should be understood that the disclosed devices, apparatuses and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interface, device or unit, which can be electrical, mechanical or other forms.
[0087] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.
[0088] The parameter configuration system and configuration method provided by the present application do not require additional configuration of special communication pins. By reusing the power lead of the photoelectric sensor, a two-way communication connection between the photoelectric sensor and the parameter configuration device can be achieved. This allows the parameter configuration device to send high and low level sequences to the photoelectric sensor while ensuring the normal operation of the photoelectric sensor, and also supports the photoelectric sensor to feedback configuration results or working status and other information. Without adding a dedicated communication interface, two-way interaction between the photoelectric sensor and the parameter configuration device is achieved, reducing the overall volume of the sensor; the amplitude change of the power supply voltage is used as the basis for judging the high and low levels, and it has a stronger noise tolerance, which is suitable for parameter configuration in strong electromagnetic interference environments in industrial sites; it is compatible with the power supply system of existing photoelectric sensors, and the dual needs of photoelectric sensor power supply and parameter configuration can be achieved through the same power lead, reducing the operational complexity of multi-lead connection and effectively improving the efficiency of on-site rapid debugging.
[0089] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent replacements and improvements made within the spirit and principles of the present application should be included in the scope of protection of the present application.
Claims
1. A parameter configuration system, characterized in that: It includes a sensor module provided with a power lead, and a parameter configuration module communicatively connected to the sensor module via the power lead; The sensor module is used to receive the power supply voltage transmitted by the parameter configuration module through the power supply lead, and analyze the power supply voltage into a high and low level sequence according to the amplitude change of the power supply voltage; The sensor module is also used to compare the high and low level sequence with a preset instruction sequence. When the high and low level sequence matches the preset instruction sequence, the instruction corresponding to the high and low level sequence is executed; when the high and low level sequence does not match the preset instruction sequence, no response is given to the high and low level sequence.
2. The parameter configuration system according to claim 1, wherein: The parameter configuration module includes a transmission unit connected to the power lead for providing a power supply voltage to the sensor module; The transmission unit includes a first transmission circuit for transmitting a first voltage to the sensor module, and a second transmission circuit for transmitting a second voltage to the sensor module.
3. The parameter configuration system according to claim 2, wherein: The first transmission circuit includes a first unidirectional conductive element connected to the power lead, and a first load switch connected to the first unidirectional conductive element; The second transmission circuit includes a second unidirectional conductive element connected between the power lead and the first unidirectional conductive element, and a second load switch connected to the second unidirectional conductive element; The enable pin of the second load switch is in a continuously enabled state. When the enable pin of the first load switch is enabled, the transmission unit transmits a first voltage to the sensor module. When the enable pin of the first load switch is not enabled, the transmission unit transmits a second voltage to the sensor module.
4. The parameter configuration system according to claim 2, wherein: A voltage dividing resistor element and a semiconductor switch element are further provided between the transmission unit and the power lead; The voltage dividing resistor element includes a first resistor connected to the semiconductor switch element, and a second resistor connected to the first resistor and the transmission unit, a first end of the semiconductor switch element is connected to the power lead, a second end of the semiconductor switch element is grounded, and a third end of the semiconductor switch element is connected to the first resistor; The parameter configuration module is further configured to detect voltage information transmitted by the transmission unit through the power lead. When the semiconductor switch element is turned off, the parameter configuration module detects a first level. When the semiconductor switch element is turned on, the parameter configuration module detects a second level.
5. The parameter configuration system according to claim 1, wherein: The sensor module includes a power supply unit for receiving the power supply voltage, and a controller unit for parsing the varying power supply voltage into a sequence of high and low levels; The controller unit includes at least a controller and a comparator. The comparator is used to receive the power supply voltage divider value at the current moment, compare the power supply voltage divider value with a preset voltage threshold, and output a first level to the controller if the power supply voltage divider value at the current moment is higher than the voltage threshold; if the power supply voltage divider value at the current moment is lower than the voltage threshold, output a second level to the controller, so that the controller generates the required high and low level sequence according to the output result of the comparator.
6. The parameter configuration system according to claim 5, wherein: The controller unit further includes a third resistor connected to the power supply unit, and a fourth resistor connected to the third resistor, wherein the other end of the fourth resistor is grounded; The non-inverting input terminal of the comparator is connected between the third resistor and the fourth resistor, and a first capacitor is further arranged between the third resistor and the non-inverting input terminal of the comparator. The other end of the first capacitor is grounded, the inverting input terminal of the comparator is connected to the reference voltage, and the output terminal of the comparator is connected to the controller.
7. The parameter configuration system according to any one of claims 2 to 6, wherein: The first level is a high level, and the second level is a low level.
8. The parameter configuration system according to claim 1, wherein: The sensor module further includes an indication unit, which is used to indicate whether the sensor module responds to the high and low level sequence.
9. The parameter configuration system according to claim 1, wherein: The parameter configuration module also includes an LED indication unit and a photoelectric receiving unit; The sensor module is further configured to transmit a light signal to the photoelectric receiving unit in response to the high and low level sequence, and the LED indicator unit is configured to indicate whether the photoelectric receiving unit has received the light signal transmitted by the sensor module.
10. A parameter configuration method, applied to a parameter configuration device and a photoelectric sensor provided with a power lead, wherein the parameter configuration device is communicatively connected to the photoelectric sensor via the power lead, characterized in that: The configuration method comprises the following steps: receiving a power supply voltage transmitted by the parameter configuration device through the power lead; parsing the power supply voltage transmitted by the parameter configuration device into a high and low level sequence according to the amplitude change of the power supply voltage; The high and low level sequence is compared with a preset instruction sequence. When the high and low level sequence matches the preset instruction sequence, the instruction corresponding to the high and low level sequence is executed; when the high and low level sequence does not match the preset instruction sequence, no response is given to the high and low level sequence.