Photocell detection system, coding control method, processing chip, device and medium
By using pulse light sources and signal conditioning circuits in photovoltaic arrays combined with FPGA technology, the problem of difficult control and high cost of photovoltaic array AD acquisition circuits is solved, high-precision signal quantization and encoding is achieved, and costs are reduced.
Patent Information
- Application Number
- CN202111644202.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-29
- Publication Date
- 2024-10-11
- Estimated Expiration
- 2041-12-29
AI Technical Summary
Photovoltaic cell arrays are difficult to control and costly in AD acquisition circuits.
The pulse light source and signal conditioning circuit combined with FPGA are used to collect signal edges, and the signal is encoded through time width, which reduces the detection requirements for each battery unit and achieves signal quantization and encoding.
It improves the accuracy of photoelectric detection, expands the breadth of information, and reduces equipment costs.
Smart Images

Figure CN114413941B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of optoelectronic technology, and in particular to a photocell detection system, a coding control method, a processing chip, a processing device and a computer-readable storage medium. Background Art
[0002] In photoelectric detection applications, each cell of a photocell is equivalent to a photoelectric signal detection pixel. Each pixel can sense laser irradiation to generate parallel electrical signals. Multiple array-type photocells can form a two-dimensional coordinate system for measuring the trajectory and speed of two-dimensional moving objects.
[0003] In the related art, when performing photoelectric detection, the electrical signal after photoelectric conversion is collected by AD (analogue-digital) and quantized into a digital signal for encoding calculation. However, in the application of photoelectric arrays, each battery cell exists in parallel, and the photoelectric array needs to detect each battery cell, which makes the AD acquisition circuit difficult to control and has a high cost.
[0004] The above contents are only used to assist in understanding the technical solution of the present invention and do not constitute an admission that the above contents are prior art. Summary of the invention
[0005] The main purpose of the present invention is to provide a photocell detection system, a coding control method, a processing chip, a processing device and a computer-readable storage medium, aiming to solve the technical problems that the AD acquisition circuit of the relevant photocell detection system is difficult to control and has a high cost.
[0006] To achieve the above object, the present invention provides a photocell detection system, comprising:
[0007] Photovoltaic cell arrays;
[0008] A light source, used to send a pulse light signal to the photocell array;
[0009] A signal conditioning circuit, wherein the input end of the signal conditioning circuit is connected to the photocell pixel of the photocell array, and the signal conditioning circuit corresponds to the photocell pixel one by one;
[0010] The acquisition FPGA is connected to the output end of the signal conditioning circuit and is used to acquire the time width of the output signal of the signal conditioning circuit and encode the output signal when the time width meets a condition.
[0011] Optionally, the signal conditioning circuit includes:
[0012] An amplification module, used for converting the current signal output by the photocell pixel into a voltage signal and amplifying the voltage signal;
[0013] A triangle wave conversion module, used for converting the voltage signal output by the amplification module into a triangle wave signal of equal amplitude;
[0014] The comparison module is used to convert the triangle wave signal output by the triangle wave conversion module into a square wave signal, and use the square wave signal as the output signal.
[0015] Optionally, the acquisition FPGA, a logic IO port of the acquisition FPGA is connected to the output end of the signal conditioning circuit.
[0016] Optionally, the photocell detection system further comprises:
[0017] A master control FPGA, the master control FPGA is in communication connection with the acquisition FPGA and is used to summarize the encoding results of the acquisition FPGA;
[0018] The acquisition FPGA and the main control FPGA communicate with each other based on the RS485 protocol.
[0019] Optionally, the master control FPGA further includes a USB interface, a wifi interface, a Bluetooth interface and / or a wireless radio frequency interface, and the master control FPGA is communicatively connected with other terminals via the USB interface, the wifi interface, the Bluetooth interface and / or the wireless radio frequency interface.
[0020] The present invention also provides a coding control method, which is applied to the above-mentioned photocell detection system, and the coding control method comprises:
[0021] When the acquisition FPGA detects the rising edge of the square wave signal, the counter is started;
[0022] When the falling edge of the square wave signal is detected, the counter is controlled to stop counting, and the current count value of the counter is obtained;
[0023] When the count value is greater than a preset threshold, the square wave signal is encoded.
[0024] Optionally, after the step of encoding the square wave signal, the method further comprises:
[0025] The encoding result is sent to the main control FPGA, wherein the main control FPGA, when receiving the encoding result sent by the acquisition FPGA, determines the position information and time information corresponding to the encoding result, generates a data frame according to the time information and the position information, and sends the data frame to other terminals.
[0026] The present invention also provides a processing chip, which includes: a storage unit, a processing unit, and a coding program stored in the storage unit and executable on the processing unit. When the coding program is executed by the processing unit, the various steps of the coding control method described above are implemented.
[0027] The present invention also provides a processing device, the processing device comprising:
[0028] The acquisition module is used to start the counter when the FPGA detects the rising edge of the square wave signal;
[0029] An acquisition module, used for controlling the counter to stop counting and acquiring a current count value of the counter when a falling edge of the square wave signal is detected;
[0030] The encoding module is used to encode the square wave signal when the count value is greater than a preset threshold.
[0031] The embodiment of the present invention proposes a photocell detection system, coding control method, processing chip, processing device and computer-readable storage medium. In the photocell detection system, the light source is set to a pulsed light beam, the conditioned signal is quantized by a comparator, and the signal edge is collected in conjunction with an FPGA. The signal light intensity is calculated based on the signal time information to determine the useful signal. The collected signal can be encoded and superimposed with other information as needed. This method improves the detection accuracy, expands the breadth of information, and saves costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] Figure 1 is an architecture diagram of a photocell detection system involved in an embodiment of the present invention;
[0033] Figure 2 is a module schematic diagram of a signal conditioning circuit involved in an embodiment of the present invention;
[0034] Figure 3 is a schematic diagram of the relationship between a signal and a clock cycle involved in an embodiment of the present invention;
[0035] Figure 4 is a schematic diagram of the relationship between signal light intensity and time in an embodiment of the present invention;
[0036] Figure 5 It is a schematic diagram of the terminal structure of the hardware operating environment involved in the embodiment of the present invention;
[0037] Figure 6 It is a flow chart of an embodiment of a coding control method of the present invention;
[0038] Figure 7 The analog-to-digital sampling circuit involved in the related technology;
[0039] Figure 8 It is a modular schematic diagram of a processing device involved in an embodiment of the present invention.
[0040] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0041] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.
[0042] Photocells are semiconductor components that convert light energy into electrical energy. Currently, the application of photocells involves mechanical instruments, automated telemetry, remote control, photoelectric detection and other fields. Photocell arrays integrate multiple battery cells on a panel. In photoelectric detection applications, each battery cell of the integrated panel is equivalent to a photoelectric signal detection pixel. Each pixel can sense laser irradiation to generate parallel electrical signals. Multiple array-type photocells can form two-dimensional coordinates for measuring the trajectory and speed of two-dimensional moving objects. The traditional photoelectric detection method is to perform AD acquisition and quantify the electrical signal after photoelectric conversion into a digital signal for encoding and calculation. However, in the application of photocell arrays, each battery cell exists in parallel. Therefore, the traditional AD acquisition and quantification method requires detection of each battery cell. The AD acquisition circuit is difficult to control and has a high cost.
[0043] For example, please refer to Figure 7 When sampling optical signals based on ADC (analog to digital converter), it is necessary to set up ADC sampling modules corresponding to each pixel. In addition, the digital signal output by the ADC sampling module needs to be programmed according to the control command, and the I2C communication interface resources are limited, which makes it difficult to control the sampling method. In addition, in order to meet the sampling requirements, multiple ADCs need to be used, resulting in high costs.
[0044] Therefore, in order to solve the above-mentioned defects of the related art and achieve the effect of reducing equipment costs, the present invention proposes a waveform signal quantization method. By setting the light source to a pulsed light beam, and using a comparator to quantize the conditioned signal, and cooperating with FPGA (Field Programmable Gate Array, Field Programmable Logic Gate Array) to realize signal edge acquisition, and then calculating the signal light intensity according to the signal time information, the useful signal is determined.
[0045] Furthermore, in the present invention, the collected signals can be encoded and superimposed with other information as needed. This method improves detection accuracy, expands information breadth, and saves costs.
[0046] In order to enable those skilled in the art to better understand the protection scope of the claims of the present invention, the photocell detection system proposed by the present invention is further explained below in conjunction with the accompanying drawings. It should be understood that the following content is not intended to limit the present invention.
[0047] Please refer to Figure 1 The photocell detection system includes a light source 100, a photocell array 210, a signal conditioning circuit 220, a collection FPGA 230 and a main control FPGA 240.
[0048] The photovoltaic array 210 includes a plurality of photovoltaic pixels 211. The output end of each photovoltaic pixel 211 is connected to the input end of the corresponding signal conditioning circuit 220. The output end of each signal conditioning circuit 220 is connected to the input end of the acquisition FPGA 230. The output end of the acquisition FPGA 230 is connected to the input end of the main control FPGA 240.
[0049] The light source 100 is configured as a laser light source 100. For example, the light source 100 can be designed as a pulsed laser beam emitter that alternately turns on and off. The laser beam emitted by the pulsed laser beam emitter irradiates the surface of the photocell pixel 211, generating a pulsed current signal.
[0050] Optionally, see Figure 2 As an optional implementation, the signal conditioning circuit 220 includes: an amplifying module 221, a triangular wave conversion module 222, and a comparing module 223. The amplifying module 221 is used to convert the current signal output by the photovoltaic cell pixel 211 into a voltage signal and amplify the voltage signal. The triangular wave conversion module 222 is used to convert the voltage signal output by the amplifying module 221 into a triangular wave signal of equal amplitude. The comparing module 223 is used to convert the triangular wave signal output by the triangular wave conversion module 222 into a square wave signal and use the square wave signal as the output signal.
[0051] Exemplarily, the photovoltaic cell pixel 211 converts light into a current signal, and uses the current signal as the input of the amplifier module 221. The amplifier module 221 converts the input current signal into a current-voltage conversion signal, and amplifies it into a square wave electrical signal with a duty cycle of 50%. The converted square wave voltage signal is then input into the triangle wave conversion module 222. After passing through the triangle wave conversion module 222, the square wave signal is converted into an equal-amplitude triangle wave signal. The triangle wave signal is then input into the comparison module 223 and converted into a square wave signal with a different duty cycle.
[0052] It should be noted that, in this embodiment, the threshold voltage of the comparison module 223 can be adjusted, and the threshold can be set according to specific needs. In this way, when a laser spot hits the surface of the detector, the amplitude of the different brightness electrical signals sensed by the detector will change, and then after quantization by the comparator, a square wave signal with different duty cycles is obtained.
[0053] It can be understood that the photocell array 210 includes a plurality of photocell pixels 211 , and the photocell detection system is provided with the signal conditioning circuit 220 respectively connected to each of the photocell pixels 211 .
[0054] Furthermore, the output end of the signal conditioning circuit 220 is connected to the logic IO port of the acquisition FPGA 230. The acquisition FPGA 230 is connected to the output end of the signal conditioning circuit 220 to collect the time width of the output signal of the signal conditioning circuit 220, and encode the output signal when the time width meets the condition. It can be understood that each photocell pixel 211 can correspond to a different pin of the acquisition FPGA 230, so that when the acquisition FPGA 230 receives an output signal of the signal conditioning circuit 220, it can determine which photocell pixel 211 the signal comes from according to the pin.
[0055] For example, each photovoltaic cell pixel 211 corresponds to a separate signal conditioning circuit 220, and the signal is connected to the logic IO port of the acquisition FPGA 230 via the conditioning circuit. The internal logic of the FPGA detects the rising edge of the square wave signal and starts counting, and detects the falling edge of the square wave signal and stops counting. In this way, the time width of the signal (such as Figure 3 As shown), when the clock count value reaches the designed count threshold, it is judged as a valid signal, and then the signal is encoded. Among them, each photocell pixel 211 can be used as a coordinate in the array, or time information or other useful information can be superimposed. The encoded signal is summarized by the main control FPGA 240, and then sent to the interactive interface or other terminal 260 (for example, it can be a host computer or a display) through a transmission medium for processing. Since each acquisition FPGA 230 requires an external clock, if there is enough space, all acquisition FPGAs 230 can use the same external crystal oscillator. If the space is limited and a backplane is required, each acquisition FPGA 230 system can be connected to the main control FPGA 240 to receive the second pulse signal of the main control FPGA 240 for time counting synchronization. Optionally, in some embodiments, the Beidou chip 250 can also be used to calculate the time width. Among them, when the Beidou chip 250 is provided, the Beidou chip 250 can also include a mushroom antenna 251.
[0056] As an exemplary embodiment, the light source 100 can be set to a 2kHz pulse laser, and the time period of the pulse laser emitting a pulse is 500mS. Figure 4 , that is, T0 at this time is 500ms. Vref is the set comparator threshold voltage, t0 is the time interval of the conditioned pulse signal collected by FPGA230. V is the voltage after the light intensity to be measured is converted, based on the following formula:
[0057]
[0058] Convert light intensity into a time measurement of a pulse signal.
[0059] The solution provided in this embodiment is suitable for the signal quantization acquisition of the photocell array 210 and other independent pixel photoelectric detection array devices. Compared with the use of AD to acquire quantized photoelectric signals, this method is easy to control and saves costs. The quantization accuracy of this method mainly depends on the sampling capability of the acquisition FPGA 230. When the clock of the acquisition FPGA 230 is 50MHz, the sampling accuracy is 20ns. If higher accuracy is required, the internal PLL of the acquisition FPGA 230 can divide the clock to obtain finer sampling accuracy. In addition, with the help of the parallel operation of the acquisition FPGA 230 and the convenience of various communication logic programming, each communication interface is easy to operate.
[0060] Optionally, in an exemplary embodiment, the signaling protocol for communication between the acquisition FPGA 230 and the main control FPGA 240 can be customized, and the protocol includes handshake information, position information, time information, or other useful information. For example, serial communication can be used to use RS485 transceiver to change to differential signal transmission, so that the anti-interference ability during signal transmission is stronger. When the light source 100 irradiates a photocell pixel 211 of a photocell array 210, if the main control FPGA 240 receives the signal of the acquisition FPGA 230 to determine that the photocell pixel 211 is a useful signal, the position information of the photocell pixel 211 can be recorded, and then the time information is superimposed. The time can be generated by the internal logic count of the main control FPGA 240, or it can be generated by an external Beidou chip. Then the signal with superimposed time information is encoded, so that a frame of encoded data can be transmitted to other terminals 260 (for example, it can be a host computer or a display) through USB, network port, wifi&BT (Bluetooth) or RF (radio frequency) transceiver for processing by other terminals.
[0061] Reference Figure 5The present invention also provides a chip, which may be an FPGA. The chip may include a processing unit 1001, an interface 1003, a storage unit 1004, and a communication bus 1002. The communication bus 1002 is used to realize the connection and communication between these components. The interface 1003 is configured to communicate with other devices or other components. The storage unit 1004 may also be a storage device independent of the aforementioned processing unit 1001.
[0062] Those skilled in the art will understand that Figure 5 The terminal structure shown in the figure does not constitute a limitation on the chip, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.
[0063] like Figure 5 As shown, the storage unit 1004 may include a control system, an interface module, and a coding program. Figure 5 In the chip shown, the processing unit 1001 can be used to call the encoding program stored in the storage unit 1004 and perform the following operations:
[0064] When the acquisition FPGA detects the rising edge of the square wave signal, the counter is started;
[0065] When the falling edge of the square wave signal is detected, the counter is controlled to stop counting, and the current count value of the counter is obtained;
[0066] When the count value is greater than a preset threshold, the square wave signal is encoded.
[0067] Optionally, in some embodiments, the processing unit 1001 may also be used to call the encoding program stored in the storage unit 1004 and perform the following operations:
[0068] The encoding result is sent to the main control FPGA, wherein the main control FPGA, when receiving the encoding result sent by the acquisition FPGA, determines the position information and time information corresponding to the encoding result, generates a data frame according to the time information and the position information, and sends the data frame to other terminals.
[0069] Optionally, see Figure 6 The embodiment of the present invention further provides a coding control method, the coding control method comprising the following steps:
[0070] Step S10: When the acquisition FPGA detects the rising edge of the square wave signal, the counter is started;
[0071] Step S20: When the falling edge of the square wave signal is detected, the counter is controlled to stop counting, and the current count value of the counter is obtained;
[0072] Step S30: When the count value is greater than a preset threshold, the square wave signal is encoded.
[0073] In this embodiment, the encoding control method may be executed by the acquisition FPGA of the photocell detection system described in the above embodiment.
[0074] In the photocell detection system, when the laser emitted by the light source irradiates the photocell pixel, the photocell pixel will generate current, and after the current signal is input into the signal conditioning circuit, the signal conditioning circuit converts the current signal into a square wave voltage signal with different duty cycles.
[0075] After the acquisition FPGA receives the square wave voltage signal, it can detect the rising edge of the square wave voltage. When the rising edge is detected, the counter is started to start counting. When the falling edge is detected, the counter is controlled to stop counting.
[0076] It should be noted that the counter is driven by a clock signal, so the count value of the counter represents the number of cycles of the clock signal during the counting phase. Since the cycle length of the clock signal is a known constant, the count value represents a time information.
[0077] Furthermore, after the counter stops counting, the current count value of the counter can be obtained. When the count value is greater than the preset threshold, it means that the time width corresponding to the square wave voltage signal (hereinafter described as the input signal) is greater than the preset width. Therefore, it can be determined that the input signal is a useful signal. Then the input signal is encoded.
[0078] Optionally, after the encoding is completed, the acquisition FPGA can send the encoding result to the main control FPGA. When the main control FPGA receives the encoding result, it can be determined that the corresponding photocell signal detects a useful signal. Therefore, the position information and time information corresponding to the encoding result can be determined, and a data frame can be generated according to the time information and the position information, and the data frame can be sent to other terminals.
[0079] In the technical solution disclosed in this embodiment, when the acquisition FPGA detects the rising edge of the square wave signal, the counter is started, and when the falling edge of the square wave signal is detected, the counter is controlled to stop counting and the current count value of the counter is obtained. When the count value is greater than a preset threshold, the square wave signal is encoded. Since the light intensity signal detection can be converted into the quantization of the pulse time information, it is convenient for the FPGA to directly collect and extract effective information from the signal, and the signal quantization has strong real-time performance.
[0080] The present invention also provides a processing chip, which includes: a storage unit, a processing unit, and a coding program stored in the storage unit and executable on the processing unit. When the coding program is executed by the processing unit, the various steps of the coding control method described above are implemented.
[0081] Please refer to Figure 8 The present invention further provides a processing device 10, the processing device 10 comprising:
[0082] The acquisition module 11 is used to start the counter when the FPGA detects the rising edge of the square wave signal;
[0083] An acquisition module 12, configured to control the counter to stop counting and acquire a current count value of the counter when a falling edge of the square wave signal is detected;
[0084] The encoding module 13 is used to encode the square wave signal when the count value is greater than a preset threshold.
[0085] Optionally, after encoding the square wave signal, the method further includes:
[0086] The encoding result is sent to the main control FPGA, wherein the main control FPGA, when receiving the encoding result sent by the acquisition FPGA, determines the position information and time information corresponding to the encoding result, generates a data frame according to the time information and the position information, and sends the data frame to other terminals.
[0087] The present invention also provides a computer-readable storage medium, on which a coding program is stored. When the coding program is executed by a processing unit, the various steps of the coding control method described above are implemented.
[0088] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.
[0089] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.
[0090] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes a number of instructions for a device to execute the methods described in each embodiment of the present invention.
[0091] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.
Claims
1. A photocell detection system, characterized in that: include: Main control FPGA; Photovoltaic cell arrays; A light source, used to send a pulse light signal to the photocell array; A signal conditioning circuit, wherein the input end of the signal conditioning circuit is connected to the photovoltaic cell pixel of the photovoltaic cell array, and the signal conditioning circuit corresponds to the photovoltaic cell pixel one by one, wherein the signal conditioning circuit includes an amplification module, which is used to convert the current signal output by the photovoltaic cell pixel into a voltage signal and amplify the voltage signal; a triangular wave conversion module, which is used to convert the voltage signal output by the amplification module into a triangular wave signal of equal amplitude; and a comparison module, which is used to convert the triangular wave signal output by the triangular wave conversion module into a square wave signal and use the square wave signal as the output signal; The acquisition FPGA is connected to the output end of the signal conditioning circuit and is used to acquire the time width of the output signal of the signal conditioning circuit and encode the output signal when the time width is greater than a preset width.
2. The photocell detection system according to claim 1, characterized in that: The acquisition FPGA, the logic IO port of the acquisition FPGA is connected to the output end of the signal conditioning circuit.
3. The photocell detection system according to claim 1, characterized in that: The main control FPGA is connected to the acquisition FPGA for communication and is used to summarize the encoding results of the acquisition FPGA; the acquisition FPGA and the main control FPGA communicate based on the RS485 protocol.
4. The photocell detection system according to claim 1, characterized in that: The master control FPGA also includes a USB interface, a wifi interface, a Bluetooth interface and / or a wireless radio frequency interface. The master control FPGA is connected to other terminals through the USB interface, the wifi interface, the Bluetooth interface and / or the wireless radio frequency interface.
5. A coding control method, characterized in that: Applied to the photocell detection system according to any one of claims 1 to 4, the coding control method comprises: When the acquisition FPGA detects the rising edge of the square wave signal, the counter is started; When the falling edge of the square wave signal is detected, the counter is controlled to stop counting, and the current count value of the counter is obtained; When the count value is greater than a preset threshold, the square wave signal is encoded.
6. The coding control method according to claim 5, characterized in that: After the step of encoding the square wave signal, the method further comprises: The encoding result is sent to the main control FPGA, wherein the main control FPGA, when receiving the encoding result sent by the acquisition FPGA, determines the position information and time information corresponding to the encoding result, generates a data frame according to the time information and the position information, and sends the data frame to other terminals.
7. A processing chip, characterized in that: The processing chip includes: a storage unit, a processing unit, and a coding program stored in the storage unit and executable on the processing unit. When the coding program is executed by the processing unit, the steps of the coding control method according to claim 5 or 6 are implemented.
8. A processing device, characterized in that: Applied to the photocell detection system according to any one of claims 1 to 4, the processing device comprises: The acquisition module is used to start the counter when the FPGA detects the rising edge of the square wave signal; An acquisition module, used for controlling the counter to stop counting and acquiring a current count value of the counter when a falling edge of the square wave signal is detected; The encoding module is used to encode the square wave signal when the count value is greater than a preset threshold.
9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a coding program, and when the coding program is executed by the processing unit, the steps of the coding control method according to claim 5 or 6 are implemented.
