Photoelectric decoding circuit with self-checking function, detection method and detection system
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHENZHEN CHUANGREN TECH
- Filing Date
- 2026-03-26
- Publication Date
- 2026-06-23
Smart Images

Figure CN122268374A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of photoelectric watches, and more particularly to a photoelectric decoding circuit, detection method, and detection system with self-testing function. Background Technology
[0002] Photoelectric decoding technology uses photoelectric sensors (such as photodiodes and phototransistors) to detect water meter readings. It converts the numbers on the meter's dial or the movement of the pointer into electrical signals, thus achieving digital readings. This technology typically combines a light source (such as an LED) and a photoelectric sensor.
[0003] Specifically, it utilizes the photoelectric conversion principle. Slots of different lengths are cut into the character wheel to allow light to pass through. A light signal emitting tube is installed on one side of the character wheel, and a light signal receiving tube is installed on the other side. Each character wheel is equipped with multiple sets of such light signal devices. As the character wheel rotates, the position of the slots changes accordingly, and a number of light signal devices in different positions receive the signal emitted by the emitting tube. Multiple sets of such devices work together to generate a multi-bit binary code. Each code represents a character wheel position, thereby "decoding" the character wheel reading.
[0004] However, currently there is no device to detect and determine the specific operating status of the optical signal transmitting and receiving tubes. It's impossible to determine whether they are short-circuited or open-circuited. Even using two threshold values only distinguishes between the conducting and non-conducting states of the optical receiver, and this assumes the devices are not damaged. Therefore, even with a two-threshold solution, it's impossible to determine whether the photometer's displayed value error is due to a problem in the circuit containing the optical signal transmitting and receiving tubes, or due to damage to the tubes themselves, increasing the complexity of maintenance. Summary of the Invention
[0005] In view of the shortcomings of the prior art, the purpose of this invention is to provide a photoelectric decoding circuit, detection method and detection system with self-testing function to determine the status of each light emitting tube and light receiving tube, thereby determining the fault status of the photoelectric meter device.
[0006] The technical solution of the present invention is as follows: A photoelectric decoding circuit with self-testing function includes: Multiple optical emitters are used to transmit optical signals; Multiple optical receivers are used to receive optical signals emitted by multiple optical transmitters in a one-to-one manner. A current detection circuit is used to detect the current values of the plurality of optical emitting diodes and the plurality of optical receiving diodes, and output a current detection signal; The processing chip is used to determine whether the plurality of optical emitting diodes and the plurality of optical receiving diodes are in a normal state, a short-circuit state, or an open-circuit state based on the current detection signal, and outputs the corresponding state signal.
[0007] Optionally, the processing chip is provided with a first threshold and a second threshold. When the processing chip determines that the current value of any one of the light emitting tubes or the light receiving tubes is the first threshold based on the current detection signal, it outputs an open circuit state signal. When the processing chip determines that the current value of any of the light emitting diodes or light receiving diodes is the second threshold based on the current detection signal, it outputs a short-circuit state signal. When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the first threshold and less than the second threshold, it outputs a normal state signal.
[0008] Optionally, the number of optical transmitters is 5, the number of optical receivers is 5, and the processing chip uses Gray code decoding principle to perform five-bit binary decoding.
[0009] Optionally, the processing chip is further provided with a third threshold, a fourth threshold, a fifth threshold and a sixth threshold. When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting tubes or the light receiving tubes is greater than the third threshold and less than the fourth threshold, it outputs "0". When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the fourth threshold and less than the fifth threshold, it outputs "1". When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the fifth threshold and less than the sixth threshold, it outputs "X". Wherein, the first threshold is less than the third threshold, the third threshold is less than the fourth threshold, the fourth threshold is less than the fifth threshold, the fifth threshold is less than the sixth threshold, and the sixth threshold is less than the second threshold.
[0010] Optionally, the photoelectric decoding circuit with self-testing function also includes: A communication circuit is connected to the processing chip. The communication circuit is used to connect to a host computer and outputs the status signal output by the processing chip to the host computer.
[0011] Optionally, the photoelectric decoding circuit with self-testing function also includes: A power supply circuit is electrically connected to the processing chip, and the power supply circuit is used to provide operating voltage to the processing chip.
[0012] This invention also proposes a method for detecting photoelectric decoding circuits with self-testing functions, comprising the following steps: Acquire current detection signals corresponding to multiple optical emitters and multiple optical receivers; The current detection signal determines whether multiple optical transmitters and receivers are in normal, short-circuited, or open-circuited condition, and outputs the corresponding status signal.
[0013] Optionally, the step of determining whether the multiple optical emitting diodes and multiple optical receiving diodes are in a normal state, a short-circuit state, or an open-circuit state based on the current detection signal, and outputting the corresponding state signal, specifically includes: When the current value of any optical transmitter or receiver is determined to be the first threshold based on the current detection signal, an open-circuit state signal is output. When the current value of any optical transmitter or receiver is determined to be the second threshold based on the current detection signal, a short-circuit status signal is output. When the current value of any optical transmitter or receiver is greater than the first threshold and less than the second threshold as determined by the current detection signal, a normal state signal is output.
[0014] The present invention also proposes a photoelectric decoding circuit detection system, including a host computer and a photoelectric decoding circuit with self-testing function as described above, wherein the host computer is communicatively connected to the photoelectric decoding circuit with self-testing function.
[0015] Optionally, the number of photoelectric decoding circuits with self-testing function is multiple, and the host computer includes: Processing module; The display module is connected to the processing module; the processing module is used to control the display module to display device status information based on the status signal output by the photoelectric decoding circuit with self-testing function. A communication module is used to connect to a cloud server, and the communication module is also used to send the status signals received by the processing module to the cloud server.
[0016] This invention provides a self-testing optoelectronic decoding circuit comprised of multiple optical transmitters, multiple optical receivers, a current detection circuit, and a processing chip. The optical transmitters emit optical signals, while the optical receivers receive these signals one-to-one. The current detection circuit detects the current values of the transmitters and receivers and outputs a current detection signal to the processing chip. The processing chip determines whether the transmitters and receivers are in a normal, short-circuit, or open-circuit state based on the current detection signal and outputs a corresponding status signal. This self-testing optoelectronic decoding circuit allows users to pinpoint the specific optical transmitter or receiver that has malfunctioned, reducing the complexity of repair procedures. Attached Figure Description
[0017] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on the structures shown in these drawings without creative effort.
[0018] Figure 1 This is a functional module schematic diagram of an embodiment of the photoelectric decoding circuit with self-testing function of the present invention.
[0019] Figure 2 This is a functional module schematic diagram of another embodiment of the photoelectric decoding circuit with self-testing function of the present invention.
[0020] Figure 3 This is a functional module schematic diagram of another embodiment of the photoelectric decoding circuit with self-testing function of the present invention.
[0021] Figure 4 This is a schematic diagram of the circuit structure of an embodiment of the photoelectric decoding circuit with self-testing function of the present invention. Figure 5 This is a flowchart of the method steps of an embodiment of the photoelectric decoding circuit detection method of the present invention.
[0022] Figure 6 This is a flowchart of the method steps of another embodiment of the photoelectric decoding circuit detection method of the present invention.
[0023] Explanation of reference numerals in the attached drawings: 10, light emitting tube; 20, light receiving tube; 30, current detection circuit; 40, processing chip; 51, first mounting plate; 52, second mounting plate; 60, communication circuit; 70, power supply circuit. Detailed Implementation
[0024] To make the objectives, technical solutions, and effects of this invention clearer and more explicit, the invention will be further described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
[0025] In the implementation methods and claims, unless otherwise specified in the text, the terms "a," "an," "the," and "the" may also include plural forms. If the embodiments of the present invention involve descriptions of "first," "second," etc., such descriptions are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of indicated technical features. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of those features.
[0026] It should be further understood that the term "comprising" as used in this specification means the presence of the stated features, integers, steps, operations, elements, and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof. It should be understood that when an element is referred to as "connected" or "coupled" to another element, it can be directly connected or coupled to the other element, or there may be intermediate elements present. Furthermore, "connected" or "coupled" as used herein can include wireless connections or wireless coupling. The term "and / or" as used herein includes all or any unit and all combinations of one or more associated listed items.
[0027] It will be understood by those skilled in the art that, unless otherwise defined, all terms used herein (including technical and scientific terms) have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. It should also be understood that terms such as those defined in general dictionaries should be understood to have the same meaning as in the context of the prior art, and should not be interpreted in an idealized or overly formal sense unless specifically defined as herein.
[0028] Furthermore, the technical solutions of the various embodiments can be combined with each other, but only if they are feasible for those skilled in the art. If the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such combination of technical solutions does not exist and is not within the scope of protection claimed by this invention.
[0029] Photoelectric decoding technology uses photoelectric sensors (such as photodiodes and phototransistors) to detect water meter readings. It converts the numbers on the meter's dial or the movement of the pointer into electrical signals, thus achieving digital readings. This technology typically combines a light source (such as an LED) and a photoelectric sensor.
[0030] Specifically, it utilizes the photoelectric conversion principle. Slots of different lengths are cut into the character wheel to allow light to pass through. A light signal emitting tube is installed on one side of the character wheel, and a light signal receiving tube is installed on the other side. Each character wheel is equipped with multiple sets of such light signal devices. As the character wheel rotates, the position of the slots changes accordingly, and a number of light signal devices in different positions receive the signal emitted by the emitting tube. Multiple sets of such devices work together to generate a multi-bit binary code. Each code represents a character wheel position, thereby "decoding" the character wheel reading.
[0031] However, there is currently no device to detect and judge the specific working status of optical signal transmitting tubes and optical signal receiving tubes, making it impossible to determine the specific cause of failure in photoelectric meter devices, which increases the complexity of maintenance.
[0032] To address the aforementioned problems, this invention proposes an optoelectronic decoding circuit with self-testing functionality.
[0033] Reference Figure 1 In one embodiment, the photoelectric decoding circuit with self-testing function includes: Multiple optical transmitters 10 are used to transmit optical signals; Multiple optical receiver tubes 20 are used to receive optical signals emitted by multiple optical transmitter tubes 10 in a one-to-one manner; The current detection circuit 30 is used to detect the current values of the plurality of light emitting tubes 10 and the plurality of light receiving tubes 20, and output a current detection signal; The processing chip 40 is used to determine whether the plurality of optical emitting tubes 10 and the plurality of optical receiving tubes 20 are in a normal state, a short-circuit state or an open-circuit state based on the current detection signal, and outputs the corresponding state signal.
[0034] In this embodiment, a number wheel is arranged between multiple light emitting tubes 10 and multiple light receiving tubes 20. Slots of varying lengths are cut into the number wheel to allow light to pass through. A light emitting tube 10 is installed on one side of the number wheel, and a light receiving tube 20 is installed on the other side. Each number wheel has multiple sets of such optical signal devices. As the number wheel rotates, the position of the slots changes accordingly, resulting in different numbers and positions of light receiving tubes 20 receiving the signals emitted by the light emitting tubes 10. Multiple sets of such devices working together can generate a multi-bit binary code, with each code representing a number wheel position, thus allowing the number wheel reading to be "decoded". The photoelectric decoding uses the Gray code principle. Gray code is a reliable coding method that minimizes errors. When converting between adjacent numbers, only one bit of the code changes, reducing potential confusion when transitioning from one state to the next.
[0035] Understandably, current technology determines whether a photoelectric meter is malfunctioning by checking for the presence or absence of a signal from the optical signal receiver. For example, a signal is represented by a 1, and no signal by a 0. This makes it impossible to pinpoint which of the optical transmitter (10) or receiver (20) is damaged, or if the lack of signal is due to other factors. Therefore, it's unclear whether the malfunction is caused by the optical transmitter (10) or receiver (20), or by other faults within the photoelectric meter. Consequently, when abnormal data is detected and repair is needed, it's difficult to accurately locate the component requiring repair, increasing the complexity of the repair process. This solution addresses this by incorporating a current detection circuit (30) that detects the current value of each optical transmitter (10) and receiver (20) during operation. Based on the current value, the specific operating status of each optical transmitter (10) and receiver (20) can be determined. The current detection circuit (30) can use a resistor for current sampling, such as connecting a resistor of known value in series with each optical transmitter (10) and receiver (20), and calculating the current by measuring the voltage drop across the resistor. Alternatively, the current detection circuit (30) can utilize electromagnetic induction or the Hall effect, selecting appropriate components for current detection based on the specific situation and user requirements. The specific current ranges for the optical transmitter 10 and optical receiver 20 in normal, short-circuit, or open-circuit states can be calculated based on the specifications of the actual optical transmitter 10 and optical receiver 20, as well as the operating voltage of the circuit. The standard current values corresponding to the normal, short-circuit, or open-circuit states are then set in the processing chip 40. The processing chip 40 can then determine whether the multiple optical transmitters 10 and multiple optical receivers 20 are in normal, short-circuit, or open-circuit states based on the current detection signals and output the corresponding status signals. The processing chip 40 can be a digital signal processor (DSP), a programmable logic device (PLD), a field-programmable gate array (FPGA), a microprocessor, a microcontroller (MCU), or other electronic components.
[0036] This invention provides a self-testing photoelectric decoding circuit comprised of multiple optical transmitters 10, multiple optical receivers 20, a current detection circuit 30, and a processing chip 40. The optical transmitters 10 transmit optical signals, while the optical receivers 20 receive the signals emitted by each transmitter one-to-one. The current detection circuit 30 detects the current values of the transmitters 10 and receivers 20 and outputs a current detection signal to the processing chip 40. The processing chip 40 determines whether the transmitters 10 and receivers 20 are in a normal, short-circuit, or open-circuit state based on the current detection signal and outputs a corresponding status signal. This self-testing photoelectric decoding circuit allows users to identify which transmitter 10 or receiver 20 is faulty, reducing the complexity of maintenance.
[0037] In one embodiment, the processing chip 40 is provided with a first threshold and a second threshold. When the processing chip 40 determines that the current value of any of the light emitting tubes 10 or the light receiving tubes 20 is the first threshold based on the current detection signal, it outputs an open circuit state signal. When the processing chip 40 determines, based on the current detection signal, that the current value of any of the light emitting tubes 10 or the light receiving tubes 20 is the second threshold, it outputs a short-circuit state signal. When the processing chip 40 determines, based on the current detection signal, that the current value of any of the light emitting tubes 10 or light receiving tubes 20 is greater than the first threshold and less than the second threshold, it outputs a normal state signal.
[0038] In this embodiment, the processing chip 40 can be configured with a first threshold and a second threshold. For example, the first threshold is 0µA. When the detected current value of the light emitting diode 10 or the light receiving diode 20 is 0µA, it indicates that the circuit of the light emitting diode 10 or the light receiving diode 20 is in an open-circuit state. The second threshold is 400µA. When the detected current value of the light emitting diode 10 or the light receiving diode 20 is 400µA, it indicates that the circuit of the light emitting diode 10 or the light receiving diode 20 is in a short-circuit state. When the detected current value of the light emitting diode 10 or the light receiving diode 20 is between 0µA and 400µA, it indicates that the circuit of the light emitting diode 10 or the light receiving diode 20 is in a normal state. The first threshold and the second threshold can be set according to the specifications of the circuit devices, and this embodiment does not impose any restrictions.
[0039] Furthermore, in one embodiment, the processing chip is provided with an analog-to-digital conversion circuit, which can convert the electrical signal output by the current detection circuit, i.e., the current detection signal, into a corresponding digital signal for subsequent threshold comparison.
[0040] Reference Figure 2 In one embodiment, a plurality of light emitting tubes 10 are disposed on a first mounting plate 51, and a plurality of light receiving tubes 20 are disposed on a second mounting plate 52, wherein the distance between the first mounting plate 51 and the second mounting plate 52 ranges from 2 mm to 10 mm.
[0041] In this embodiment, the light emitting tube 10 and the light receiving tube 20 are respectively disposed on the first mounting plate 51 and the second mounting plate 52, and a digit wheel is disposed between the first mounting plate 51 and the second mounting plate. One digit wheel corresponds to one counting position. For example, if four digit wheels are disposed, they correspond to "ones", "tens", "hundreds", and "thousands". The specific number of digit wheels can be set according to the actual situation and user needs. It can be understood that when multiple digit wheels are disposed, the light emitting tube 10 and the light receiving tube 20 can be disposed on both sides of a mounting plate respectively. In this case, the first mounting plate 51 and the second mounting plate 52 can be regarded as the same mounting plate. Therefore, when multiple digit wheels are disposed, multiple mounting plates are required. In this case, the first mounting plate is disposed only with the light emitting tube 10, the last mounting plate is disposed only with the light receiving tube 20, and the middle mounting plate is disposed on one side with the light emitting tube 10 and the other side with the light receiving tube 20. The distance between the first mounting plate 51 and the second mounting plate 52 is set to a range of 2mm to 10mm, which allows the light receiving tube 20 to receive the light signal emitted by the light emitting tube 10, avoiding the light signal intensity being too high or too low.
[0042] Further, in one embodiment, the number of optical emitting diodes 10 is 5, the number of optical receiving diodes 20 is 5, the operating current of the optical emitting diodes and the optical receiving diodes is less than 1mA, the distance between a single optical emitting diode and an optical receiving diode ranges from 2mm to 10mm, and the processing chip uses Gray code decoding principle for five-bit binary decoding; the included angle between two of the five optical emitting diodes 10 is 36°, and the distance between two optical emitting diodes 10 ranges from 0.6mm to 6mm; the included angle between two of the five optical receiving diodes 20 is 36°, and the distance between two optical receiving diodes 20 ranges from 0.6mm to 6mm.
[0043] In this embodiment, the number of light emitting diodes 10 and light receiving diodes 20 is set to 5. This is for a 5-bit binary photoelectric meter, and the processing chip uses Gray code decoding principle for 5-bit binary decoding. It can be understood that in this embodiment, the number of light emitting diodes 10 and light receiving diodes 20 is set to 5. On a mounting plate, the 5 light emitting diodes 10 or light receiving diodes 20 are arranged sequentially. To ensure that the 5 light receiving diodes 20 can uniformly receive the light signals from the 5 light emitting diodes 10, the 5 light emitting diodes 10 and 5 light receiving diodes 20 can be aligned. The angle between any two light emitting diodes 10 is set to 36°, thus forming a uniform 180° light emission from the 5 light emitting diodes 10. Similarly, the angle between any two light receiving diodes 20 is set to 36° to ensure that the light receiving diodes 20 can normally receive the light signals emitted by the light emitting diodes 10. Furthermore, setting the same angle can prevent mutual interference between the light signals emitted by the light emitting diodes 10. In addition, setting the distance range between the two light emitting tubes 10 and the distance range between the two light receiving tubes 20 to 0.6mm to 6mm is also to prevent mutual interference between light signals and ensure the accuracy of test results.
[0044] It should be noted that this solution sets the operating current of the optical transmitter and receiver to less than 1mA, and the distance between them to be 2mm to 10mm. This is for micro-distance detection and current identification in low-power circuits, relying on the analog-to-digital conversion circuit of the processing chip to convert minute current changes into corresponding digital signals. For device self-testing, the principle is that the optical transmitter and receiver, under normal operating conditions, will always generate a micro-current signal in response to a small beam of light. Therefore, this solution sets the distance between the optical transmitter and receiver to 2mm to 10mm to avoid the micro-current being too small due to excessive distance, making it undetectable by the current detection circuit or unreadable by the processing chip. Damaged devices do not exist; therefore, the lower limit of the operating current of a normally operating device will not be 0mA. If the operating current of a device is 0mA, it means the device is damaged. Based on this principle, this solution includes a photoelectric decoding circuit with self-testing functionality. However, current photoelectric devices have sufficiently large operating currents; therefore, if the current is insufficient (or abnormal), it can be considered damaged, making the micro-current-based self-testing in this solution unnecessary.
[0045] In one embodiment, the processing chip is further provided with a third threshold, a fourth threshold, a fifth threshold and a sixth threshold. When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting tubes or the light receiving tubes is greater than the third threshold and less than the fourth threshold, it outputs "0". When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the fourth threshold and less than the fifth threshold, it outputs "1". When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the fifth threshold and less than the sixth threshold, it outputs "X". Wherein, the first threshold is less than the third threshold, the third threshold is less than the fourth threshold, the fourth threshold is less than the fifth threshold, the fifth threshold is less than the sixth threshold, and the sixth threshold is less than the second threshold.
[0046] In this embodiment, the current value output by the optical transmitter 10 or the optical receiver 20 under normal conditions can also represent different values for photoelectric decoding. For example, if the third, fourth, fifth, and sixth thresholds set within the processing chip are 1uA, 50uA, 250uA, and 399uA respectively, then a current value between 250uA and 399uA for the optical transmitter 10 or the optical receiver 20 represents the result "1"; a current value between 1uA and 50uA represents the result "0"; and a current value between 51uA and 249uA represents the result "X". A result "X" means that subsequent processing can be either as result "1" or result "0", without affecting the overall decoding result. It should be noted that one result "X" will not affect the overall decoding result, but multiple results "X" will affect the overall decoding result. The specific values of the third, fourth, fifth, and sixth thresholds can also be adjusted according to the actual situation and user needs.
[0047] Reference Figure 3 In one embodiment, the photoelectric decoding circuit with self-testing function further includes: The communication circuit 60 is connected to the processing chip 40. The communication circuit 60 is used to connect to the host computer and output the status signal output by the processing chip 40 to the host computer.
[0048] In this embodiment, the communication circuit 60 can be either wired or wireless. Wired communication allows the photoelectric decoder circuit with self-testing function to be directly connected to the host computer via a communication line. The wireless communication circuit 60 can be composed of a wireless communication chip. The wireless communication chip uses wireless communication technology, which is a communication method that utilizes the characteristic that electromagnetic waves can propagate in free space to exchange information. The wireless communication chip can use 4G / 5G or Bluetooth, etc., to enable the photoelectric decoder circuit with self-testing function to communicate with the host computer.
[0049] Reference Figure 3 In one embodiment, the photoelectric decoding circuit with self-testing function further includes: The power supply circuit 70 is electrically connected to the processing chip 40, and the power supply circuit 70 is used to provide the operating voltage to the processing chip 40.
[0050] In this embodiment, the power supply circuit 70 can be implemented using a DC-DC circuit or a power chip. The power supply circuit 70 can convert the external power supply voltage into a suitable operating voltage for the processing chip 40, so as to prevent the processing chip 40 from being damaged by receiving a high operating voltage or from being unable to work properly by receiving a low operating voltage. The power supply circuit 70 may also include a battery pack, which directly provides the operating voltage to the processing chip 40.
[0051] The specific circuit structure of the photoelectric decoding circuit with self-testing function of this invention can be referred to... Figure 4 .
[0052] The present invention also proposes a method for detecting photoelectric decoding circuits with self-testing functions, which is applied to the aforementioned photoelectric decoding circuits.
[0053] Reference Figure 5 In one embodiment, the photoelectric decoding circuit detection method includes the following steps: S100: Acquire current detection signals corresponding to the plurality of optical emitting tubes 10 and the plurality of optical receiving tubes 20; S200: Determine whether the multiple optical transmitters 10 and multiple optical receivers 20 are in normal, short-circuit, or open-circuit state based on the current detection signal, and output the corresponding status signal.
[0054] In this embodiment, the current detection circuit 30 can detect the current value of each optical transmitter 10 and optical receiver 20 during operation, and determine the specific operating state of the optical transmitter 10 and optical receiver 20 based on the magnitude of the current value. The specific current value range of the optical transmitter 10 and optical receiver 20 in the normal state, short-circuit state, or open-circuit state can be calculated based on the specifications of the actual optical transmitter 10 and optical receiver 20 and the operating voltage of the circuit. Then, the standard current values corresponding to the normal state, short-circuit state, or open-circuit state are set. In this way, the current detection signal can be used to determine whether multiple optical transmitters 10 and multiple optical receivers 20 are in the normal state, short-circuit state, or open-circuit state, and the corresponding status signal can be output.
[0055] Reference Figure 6 In one embodiment, the step of determining whether the plurality of optical emitting diodes 10 and the plurality of optical receiving diodes 20 are in a normal state, a short-circuit state, or an open-circuit state based on the current detection signal, and outputting the corresponding state signal, specifically includes: S210. When the current value of any optical emitting tube 10 or optical receiving tube 20 is determined to be the first threshold based on the current detection signal, an open circuit state signal is output. S220: When the current value of any optical transmitter tube 10 or optical receiver tube 20 is determined to be the second threshold based on the current detection signal, a short-circuit status signal is output. S230: When the current value of any optical emitting tube 10 or optical receiving tube 20 is greater than the first threshold and less than the second threshold according to the current detection signal, a normal state signal is output.
[0056] In this embodiment, a first threshold and a second threshold can be set. For example, the first threshold is 0uA. When the detected current value of the optical transmitter 10 or the optical receiver 20 is 0uA, it means that the circuit of the optical transmitter 10 or the optical receiver 20 is in an open circuit state. The second threshold is 400uA. When the detected current value of the optical transmitter 10 or the optical receiver 20 is 400uA, it means that the circuit of the optical transmitter 10 or the optical receiver 20 is in a short circuit state. When the detected current value of the optical transmitter 10 or the optical receiver 20 is between 0uA and 400uA, it means that the circuit of the optical transmitter 10 or the optical receiver 20 is in a normal state. The first threshold and the second threshold can be set according to the specifications of the circuit devices, and this embodiment does not impose any restrictions. In addition, under normal conditions, the output current value of optical transmitter 10 or optical receiver 20 can also represent different values for photoelectric decoding. For example, a current value between 250uA and 399uA represents the result "1"; a current value between 1uA and 50uA represents the result "0"; and a current value between 51uA and 249uA represents the result "X". A result "X" means that subsequent processing can be either as result "1" or result "0", without affecting the overall decoding result. It should be noted that one result "X" will not affect the overall decoding result, but multiple results "X" will affect the overall decoding result.
[0057] The present invention also proposes a photoelectric decoding circuit detection system.
[0058] In one embodiment, the photoelectric decoding circuit detection system includes a host computer and a photoelectric decoding circuit with self-testing function as described above, wherein the host computer is communicatively connected to the photoelectric decoding circuit with self-testing function.
[0059] In this embodiment, the host computer can be a computer or other similar device. It is understood that, since the photoelectric decoding circuit with self-testing function described above is used in the photoelectric decoding circuit detection system of the present invention, the embodiments of the photoelectric decoding circuit detection system of the present invention include all the technical solutions of all embodiments of the photoelectric decoding circuit with self-testing function described above, and the achieved technical effects are completely the same, and will not be repeated here.
[0060] In one embodiment, the number of photoelectric decoding circuits with self-testing function is multiple, and the host computer includes: Processing module; The display module is connected to the processing module; the processing module is used to control the display module to display device status information based on the status signal output by the photoelectric decoding circuit with self-testing function. A communication module is used to connect to a cloud server, and the communication module is also used to send the status signals received by the processing module to the cloud server.
[0061] In this embodiment, the photoelectric decoding circuit detection system can be applied to residential buildings. Therefore, multiple photoelectric decoding circuits with self-testing functions are set up to correspond to multiple households, detecting the water meters of each household. The processing module can consist of one or more processing devices, receiving and processing the status signals output by the multiple photoelectric decoding circuits with self-testing functions, and then controlling the display module to display the corresponding information. The display module can be an LED display or an OLED display, etc., displaying text information so that users know which photoelectric decoding circuit with self-testing functions has failed, or using different colored LEDs to represent the status of the photoelectric decoding circuits with self-testing functions. The specific configuration can be set according to actual conditions and user needs. The communication module can be a wireless communication circuit 60, communicating with a cloud server via 4G / 5G or other methods. In this way, the host computer can send the fault information of the multiple photoelectric decoding circuits with self-testing functions in the photoelectric decoding circuit detection system to the cloud server for storage through the communication module.
[0062] It should be understood that the application of the present invention is not limited to the examples above. Those skilled in the art can make improvements or modifications based on the above description, and all such improvements and modifications should fall within the protection scope of the appended claims.
Claims
1. An optical-electric decoding circuit with self-checking function, characterized in that, include: Multiple optical emitters are used to transmit optical signals; Multiple optical receivers are used to receive optical signals emitted by multiple optical transmitters in a one-to-one manner. A current detection circuit is used to detect the current values of the plurality of optical emitting diodes and the plurality of optical receiving diodes, and output a current detection signal; The processing chip is used to determine whether the plurality of optical emitting diodes and the plurality of optical receiving diodes are in a normal state, a short-circuit state, or an open-circuit state based on the current detection signal, and outputs the corresponding state signal.
2. The self-checking photoelectric decoding circuit according to claim 1, wherein The processing chip is provided with a first threshold and a second threshold. When the processing chip determines that the current value of any of the light emitting tubes or light receiving tubes is the first threshold based on the current detection signal, it outputs an open circuit state signal. When the processing chip determines that the current value of any of the light emitting diodes or light receiving diodes is the second threshold based on the current detection signal, it outputs a short-circuit state signal. When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the first threshold and less than the second threshold, it outputs a normal state signal.
3. The self-checking photoelectric decoding circuit according to claim 1, wherein The number of optical transmitters is 5, the number of optical receivers is 5, the operating current of the optical transmitters and optical receivers is less than 1mA, the distance between each pair of optical transmitters and optical receivers is between 2mm and 10mm, and the processing chip uses Gray code decoding principle to perform five-bit binary decoding.
4. The self-checking photoelectric decoding circuit according to claim 2, wherein The processing chip is also provided with a third threshold, a fourth threshold, a fifth threshold and a sixth threshold. When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting tubes or light receiving tubes is greater than the third threshold and less than the fourth threshold, it outputs "0". When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the fourth threshold and less than the fifth threshold, it outputs "1". When the processing chip determines, based on the current detection signal, that the current value of any of the light emitting diodes or light receiving diodes is greater than the fifth threshold and less than the sixth threshold, it outputs "X". Wherein, the first threshold is less than the third threshold, the third threshold is less than the fourth threshold, the fourth threshold is less than the fifth threshold, the fifth threshold is less than the sixth threshold, and the sixth threshold is less than the second threshold.
5. The self-checking photoelectric decoding circuit according to claim 1, wherein Also includes: A communication circuit is connected to the processing chip. The communication circuit is used to connect to a host computer and outputs the status signal output by the processing chip to the host computer.
6. The self-checking photoelectric decoding circuit according to claim 1, wherein Also includes: A power supply circuit is electrically connected to the processing chip, and the power supply circuit is used to provide operating voltage to the processing chip.
7. A method for detecting the photoelectric decoding circuit with self-checking function according to any one of claims 1-6, characterized in that, Includes the following steps: Acquire current detection signals corresponding to multiple optical emitters and multiple optical receivers; The current detection signal determines whether multiple optical transmitters and receivers are in normal, short-circuited, or open-circuited condition, and outputs the corresponding status signal.
8. The photoelectric decoding circuit detection method of claim 7, wherein, The step of determining whether multiple optical transmitters and receivers are in a normal, short-circuit, or open-circuit state based on the current detection signal and outputting the corresponding state signal specifically includes: When the current value of any optical transmitter or receiver is determined to be the first threshold based on the current detection signal, an open-circuit state signal is output. When the current value of any optical transmitter or receiver is determined to be the second threshold based on the current detection signal, a short-circuit status signal is output. When the current value of any optical transmitter or receiver is greater than the first threshold and less than the second threshold as determined by the current detection signal, a normal state signal is output.
9. An opto-electronic decoding circuit detection system, characterized by, It includes a host computer and a photoelectric decoding circuit with self-testing function as described in any one of claims 1-6, wherein the host computer is communicatively connected to the photoelectric decoding circuit with self-testing function.
10. The photonic decoding circuit detection system of claim 9, wherein, The number of photoelectric decoding circuits with self-testing function is multiple, and the host computer includes: Processing module; The display module is connected to the processing module; the processing module is used to control the display module to display device status information based on the status signal output by the photoelectric decoding circuit with self-test function. A communication module is used to connect to a cloud server, and the communication module is also used to send the status signals received by the processing module to the cloud server.