Automatic testing method and system of ice sensor based on LabVIEW
By integrating various hardware devices through a LabVIEW-based automated testing system, the icing sensor can be automated, solving the problem of cumbersome testing procedures and improving production efficiency and product quality.
Patent Information
- Application Number
- CN202411779939.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-05
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2044-12-05
AI Technical Summary
The existing icing sensor production process involves cumbersome testing procedures and lacks automated testing, which affects production efficiency and product quality.
An automated testing method and system based on LabVIEW is adopted. By integrating a programmable DC power supply, a signal generator, an oscilloscope card, a data acquisition card, a switching module, an AC current transmitter, and a computer, the automated testing process is realized by using LabVIEW programming language, which simplifies the programming process and improves testing efficiency.
It has enabled automated testing of icing sensors, improved production efficiency, reduced manual operation processes, improved product quality, and reserved communication interfaces for hardware devices to adapt to the testing of different sensor models.
Smart Images

Figure CN119773988B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of aviation testing technology, specifically relating to an automatic testing method and system for icing sensors based on LabVIEW. Background Technology
[0002] An icing sensor is a specialized sensor used to detect the presence of ice on the aircraft's surface when flying in icy weather conditions. When the thickness of the ice significantly affects flight safety, the icing sensor can detect the ice thickness and send the corresponding signal to the flight control system.
[0003] The production volume of a certain type of icing sensor is large and the testing items are complex. During the testing process, each peripheral testing instrument (such as signal generator, digital multimeter, etc.) is operated independently, which is cumbersome and does not achieve automatic testing, seriously affecting the production and delivery efficiency of the product. Summary of the Invention
[0004] Purpose of the invention: To address the tedious manual testing methods of existing systems, this invention provides an automated testing method and system for a certain type of icing sensor based on LabVIEW.
[0005] Firstly, this application provides an automatic testing method for icing sensors based on LabVIEW, the method comprising:
[0006] Step 1: Write the initialization parameters of the icing sensor test software and the communication addresses of each hardware port into the configuration file;
[0007] Step 2: Obtain the initialization parameters and communication addresses of each hardware port from the configuration file;
[0008] Step 3: Set the switch status, and the corresponding relay in the switch module will be turned on;
[0009] Step 4: Set the frequency sweep parameters of the signal generator, the acquisition parameters of the oscilloscope card, and the acquisition parameters of the data acquisition instrument;
[0010] The signal generator starts frequency sweeping and sends an excitation signal to the icing sensor. The icing sensor then feeds back a sinusoidal signal based on the excitation signal.
[0011] The oscilloscope card acquires the sinusoidal signal, plots a spectrum based on the sinusoidal signal, analyzes the spectrum to obtain the point of maximum amplitude, determines the resonant frequency based on the point of maximum amplitude, and sets the signal amplitude corresponding to 1 kHz before and after the resonant frequency point as the zero signal value of the icing sensor; wherein, the point of maximum amplitude is the output signal amplitude of the icing sensor, and the resonant frequency is the frequency point corresponding to the point of maximum amplitude; the curve before the resonant frequency point is monotonically increasing, and the curve after the resonant frequency point is monotonically decreasing;
[0012] The data acquisition instrument monitors the loop current of the signal generator in real time and adjusts the output amplitude of the signal generator according to the loop current.
[0013] Step 5: Stop the test and output the report;
[0014] Step 6: The test is over, and the system returns to its initial state.
[0015] Preferably, step 1 includes:
[0016] Step 1.1: Power on the test system, and each test module will automatically start and perform hardware initialization;
[0017] Step 1.2: The user starts the test software interface on the computer. The software reads the information preset in the configuration file, which includes the serial port number and communication address of each hardware device.
[0018] Step 1.3: The test software reads the serial port number and communication address from the previous step, communicates with the data acquisition instrument, signal generator, and programmable DC power supply via the VISA protocol, and communicates with the data acquisition card and oscilloscope card via the PCIe protocol.
[0019] Preferably, step 2 includes:
[0020] Step 2.1: Clear the test status description box on the test software test interface;
[0021] Step 2.2: Set the output display control on the test interface of the test software to zero;
[0022] Step 2.3: After clicking the "Start Test" control, the "Exit" control is disabled;
[0023] Step 2.4: After clicking the "Start Test" control, the signal generator output parameters are reset and the output is stopped, the programmable DC power supply output parameters are reset and the output is stopped, and the data acquisition card DO status is reset to low level output.
[0024] Step 2.5: Write the different execution states of steps 2, 3, 4, 5, and 6 into an array to form a state set, set the execution state order, and the program will automatically execute according to the set state set order when the test starts.
[0025] Preferably, step 3 includes:
[0026] Step 3.1: Set the data acquisition card slot number, set the DO port number that the data acquisition card needs to output high level, convert the number cluster into an array, and input it to the data acquisition card subroutine port number;
[0027] Step 3.2: Set the DO port of the above number to output a high level;
[0028] Step 3.3: Set the output status of the DO port in the test status process description box, corresponding to the relay on status description;
[0029] Step 3.4: Set a delay time to ensure that all relays are in the correct state before the next frequency sweep begins.
[0030] Preferably, step 4 includes:
[0031] Step 4.1: Set the oscilloscope card acquisition parameters, including the oscilloscope card slot number, number of sampling channels, sampling range, sampling rate, number of sampling points, impedance matching method, and coupling method;
[0032] Step 4.2: Set the frequency sweep parameters of the signal generator, including the signal generator output channel number, sweep start frequency, sweep end frequency, sweep duration, output signal phase, and sweep hold time; in particular, the sweep duration affects the final frequency point acquisition; set the parameters according to the test sweep range required by the icing sensor under test;
[0033] Step 4.3: Set the amplitude adjustment control to detect the current in real time during the frequency sweep and adjust the output voltage. Specifically, set the data acquisition card acquisition parameters, including the AI acquisition channel number, sampling rate, number of sampling points, and sampling method. Take the data of the corresponding channel number of the AC current transmitter, multiply it by the conversion factor to obtain the actual current value, write this current value into the comparison function for range determination and forced switching, and use the output Boolean value as the branch selection of the next conditional structure. When the current is less than the current setting range, increase the output amplitude of the signal generator; when the current is greater than the current setting range, decrease the output amplitude of the signal generator.
[0034] Step 4.4: Set the state description box in the test status process description box to start frequency sweeping, start data acquisition and result analysis;
[0035] Step 4.5: Set up a subroutine for capturing the acquisition results of the oscilloscope card. Use the maximum and minimum value functions of the array to capture the set of data with the largest amplitude in the array acquired by the oscilloscope. Set this set of data as the output control and display it as the resonant frequency and the amplitude of the output signal. At the same time, take the points 1KHz before and after the resonant frequency as indices in this subroutine to obtain the signal value with zero amplitude in the array.
[0036] Step 4.6: Compare the resonant frequency, output signal amplitude, and zero signal value with the preset values respectively, and determine whether the test results are qualified.
[0037] Step 4.7: Set up a spectrum monotonicity check control to perform monotonicity analysis on the spectrum of the icing sensor output signal. Specifically, capture the array of acquisition results from the oscilloscope card, set up a For loop, and use the method of dividing by the quotient and taking the remainder to take an amplitude value every 50 sets of data. Then set up another For loop, and set up a shift register to shift the data from the previous step as the minuend value. In the loop, subtract the data obtained in the previous step in sequence. If the difference is negative, it is judged as monotonically decreasing; if the difference is positive, it is judged as monotonically increasing.
[0038] Preferably, step 5 includes:
[0039] Step 5.1: Capture the test item output data from the above steps and add it to the specified style table;
[0040] Step 5.2: Configure the table save control to output the table to the local disk for saving;
[0041] Step 5.3: Set the description of test stop in the test status process description box.
[0042] Preferably, step 6 includes:
[0043] Step 6.1: Reset the output parameters of the signal generator and stop the output; reset the output parameters of the programmable DC power supply and stop the output; reset the DO state of the data acquisition card to a low level.
[0044] Step 6.2: Merge error clusters and set the error type description in the test status process description box;
[0045] Step 6.3: Close the configuration file information reference, close the loop, and the test ends.
[0046] Secondly, this application also provides an automatic testing system for icing sensors based on LabVIEW. The testing system includes: a programmable DC power supply, a signal generator, an oscilloscope card, a data acquisition card, a switch module, an AC current transmitter, a computer, and a display module.
[0047] Among them, the programmable DC power supply is used to power the product under test;
[0048] The signal generator is used to generate the excitation signal required for the test process. After the excitation signal enters the icing sensor under test, the matching electronic converter provides an AC voltage to a pressure element of the pressure assembly, thereby generating mechanical vibration in the vibration converter. When the frequency of the AC voltage is equal to the longitudinal resonant frequency of the vibration converter, the vibration converter resonates.
[0049] The oscilloscope card is used to acquire the feedback signal of the icing sensor under test. When ice forms on the sensor's vibrating head, its mass changes, which causes the resonant frequency of the vibration transducer to change, and the output voltage signal also changes accordingly.
[0050] The data acquisition card is used to acquire the output of the AC current transmitter and control the opening and closing of the switch module. It uses the analog input terminal (AI) of the data acquisition card to acquire the real-time output voltage of the AC current transmitter and convert it into AC current value; it uses the high-level signal output from the digital output terminal (DO) of the data acquisition card to control the opening and closing of the switch module.
[0051] The switching module is used to control the on / off state of the power supply circuit, signal input circuit, and signal output circuit. It consists of a transistor, a current-limiting resistor, a relay, a terminal block, and a circuit board. When the software controls the data acquisition card to output a high level at the DO terminal, the high-level signal drives the transistor to conduct, the corresponding relay's drive circuit is activated, the relay is turned on, and the corresponding main circuit is connected.
[0052] An AC current transmitter is used to measure the feedback loop current of the icing detector and convert it into a DC voltage signal, which is then acquired by the AI port of the data acquisition card.
[0053] The computer provides a communication interface for the above-mentioned devices and integrates test software. When the test devices are running, the computer controls the hardware operation according to a preset process, and at the same time receives instructions from the operator and transmits key test information to the display module.
[0054] The display module is used to visually display the test results on a computer user interface developed using LabVIEW.
[0055] The programmable DC power supply and signal generator communicate with the computer via VISA serial communication, while the oscilloscope card and data acquisition card communicate with the computer via PCIe communication.
[0056] This application has the following technical advantages:
[0057] 1. It uses LabVIEW language for programming, which is simple, intuitive and easy to use. It can simplify the tedious and complex programming into a menu-driven function selection method, replacing the traditional text program code. It is more direct to run, easier to debug, and easier to understand the programming test results.
[0058] 2. The testing method of this invention solves the problem of synchronous interaction between programmable DC power supply, signal generator, oscilloscope card, data acquisition card, switching module, AC current transmitter and computer, automating the testing process and greatly improving production efficiency.
[0059] 3. The testing method of this invention enables one-click automated testing, which solidifies the testing process and parameters, reduces the number of manual testing operations, avoids errors that may occur during manual testing, and greatly improves the quality level of products.
[0060] 4. The testing system of this invention has reserved communication interfaces for other hardware devices, and the software has reserved a hardware parameter modification window. When testing other models of icing sensors, the universality of the testing system can be achieved by modifying the hardware parameters. Attached Figure Description
[0061] Figure 1 This is a schematic diagram of the system framework of the present invention;
[0062] Figure 2 This is a schematic diagram of the software testing process of the present invention. Detailed Implementation
[0063] Please see Figure 1 and Figure 2 This invention provides an automatic testing method for a certain type of icing sensor based on LabVIEW, referring to... Figure 2 As shown, the specific steps of this method are as follows:
[0064] Step 1: Start the software and write the initialization parameters of the icing sensor test software and the communication addresses of each hardware port into the configuration file;
[0065] Specifically, step 1 includes:
[0066] Step 1.1: Power on the test system, and each test module will automatically start and perform hardware initialization;
[0067] Step 1.2: The user launches the test software interface on the computer. The software reads information preset in the configuration file, which includes the serial port number and communication address of each hardware device. The configuration file has a unified save path, and different values in the configuration file are applied to different test steps. The configuration file contains two types: hardware device communication addresses and test item adjustment coefficients. In this method, the device communication addresses include the communication addresses of the programmable DC power supply and the signal generator, and the test item adjustment coefficients include AC current value conversion coefficients.
[0068] Step 1.3: The test software reads the serial port number and communication address from the previous step, communicates with the data acquisition instrument, signal generator, and programmable DC power supply via the VISA protocol, and communicates with the data acquisition card and oscilloscope card via the PCIe protocol.
[0069] Step 2: Start the test and obtain the initialization parameters and communication addresses of each hardware port from the configuration file.
[0070] Specifically, step 2 includes:
[0071] Step 2.1: Clear the test status process description box on the test software test interface; remove the description message in the test status process description box during the previous test, and display the description of the upcoming test process.
[0072] Step 2.2: Set the output display control on the test software interface to zero; remove the values from the output display control during the previous test.
[0073] Step 2.3: After clicking the "Start Test" control, the "Exit" control is disabled;
[0074] Step 2.4: After clicking the "Start Test" control, the signal generator output parameters are reset and output is stopped, the programmable DC power supply output parameters are reset and output is stopped, and the data acquisition card DO state is reset to low level. This step is forcibly executed after the test starts to prevent test failure due to hardware or switch state errors. This step is encapsulated as a separate sub-VI and runs once at the start and end of the test.
[0075] Step 2.5: Write the different execution states of steps 2, 3, 4, 5, and 6 into an array to form a state set, and set the execution state order. The program will automatically execute according to the set state set order when the test starts. The above state set is used as an event queue input test process sub-VI, and the execution of the state set order is triggered by the start test control.
[0076] Step 3: Set the switch status and turn on the corresponding relay.
[0077] Specifically, step 3 includes:
[0078] Step 3.1: Set the data acquisition card slot number, set the DO port number that the data acquisition card needs to output high level, convert the number cluster into an array, and input it to the data acquisition card subroutine port number; In this method, the DO port numbers that output high level are P0.2, P0.3 and P1.1, which correspond to the connection of relays S2, S3 and S9, and the connection of the excitation signal circuit, feedback signal circuit and power supply circuit of the product under test;
[0079] Step 3.2: Set the DO port of the above number to output a high level;
[0080] Step 3.3: Set the output status of the DO port in the test status process description box, corresponding to the relay on status description;
[0081] Step 3.4: Set a delay time to ensure that all relays are in the correct state before the next frequency sweep begins;
[0082] Step 4: Set the frequency sweep parameters of the signal generator and start the frequency sweep; set the acquisition parameters of the oscilloscope card and start acquisition, and draw a spectrum diagram based on the acquisition results; set the acquisition parameters of the data acquisition instrument, analyze the data and obtain the test results; according to the drawn spectrum diagram, the point with the maximum amplitude is the output signal amplitude of this type of icing sensor, and the corresponding frequency point is the resonant frequency; the signal amplitude corresponding to 1kHz before and after the resonant frequency point in the drawn spectrum diagram is the zero signal value of this type of sensor; according to the drawn spectrum diagram, the curve before the resonant frequency point should be monotonically increasing, and the curve after the resonant frequency point should be monotonically decreasing. In this method, the resonant frequency point should be in the range of 22-25.2kHz, the output signal amplitude should be greater than 200mVrms, the zero signal value should be less than 50mVrms, and the curve on the spectrum diagram should be monotonically increasing before the resonant point and monotonically decreasing after the resonant point.
[0083] Specifically, step 4 includes:
[0084] Step 4.1: Set the oscilloscope card acquisition parameters, including the oscilloscope card slot number, number of sampling channels, sampling range, sampling rate, number of sampling points, impedance matching mode, and coupling mode. In this method, the slot number is set to 1, the sampling channel is 1, the sampling range is 0-10V, the sampling rate is set to 100ksps, the number of sampling points is 10k, the impedance matching is set to 1MΩ, and the coupling mode is selected as AC coupling.
[0085] Step 4.2: Set the signal generator sweep parameters, including the signal generator output channel number, sweep start frequency, sweep end frequency, sweep duration, output signal phase, and sweep hold time. Specifically, the sweep duration affects the final frequency point acquisition. In this method, the signal generator output channel number is set to 1, the sweep start frequency is 21kHz, the sweep end frequency is 27.5kHz, the sweep duration is set to 650s, the output signal phase is set to 0°, and the sweep hold time is set to 0.1s. Notably, during equipment debugging, the initial sweep hold time was set to 1s, i.e., increasing by 10Hz per second. The resonant frequency point values in the test results were unstable, and repeated measurements showed significant deviations. Analysis revealed that the signal generator output is not linear; it maintains a constant value during the set hold time, then changes to the next constant frequency value in the next hold time cycle, causing deviations in the resonant point reading of the spectrum. The solution is to increase the linearity of the signal generator output, i.e., reduce the output hold time to 0.1s. In this way, the frequency increases by 1Hz every 0.1s. Although the sweep range and sweep time remain unchanged, the linearity of the signal generator output increases, and the deviation is smaller when approaching the resonance point.
[0086] Step 4.3: Set the amplitude adjustment control to detect the current in real time during the frequency sweep and adjust the output voltage. Specifically, set the data acquisition card acquisition parameters, including the acquisition card AI acquisition channel number, sampling rate, number of sampling points, and sampling method. Take the data corresponding to the channel number of the AC current transmitter, multiply it by the conversion factor to obtain the actual current value, write this current value into the range determination and forced conversion comparison function, and use the output Boolean value as the branch selection of the next conditional structure. When the current is less than the current setting range, increase the output amplitude of the signal generator; when the current is greater than the current setting range, decrease the output amplitude of the signal generator. In this method, the acquisition card AI acquisition channel number is set to AI3, the sampling rate is 20ksps, the number of sampling points is 2k, the sampling method is single-ended sampling, the input of the selected AC current transmitter is 0-100mA, the output is 0-1VDC, and the conversion factor for converting the output voltage to the current value is 10, which is also saved in the configuration file. During the actual frequency sweep process, the current range was set to 19-21mA, the initial amplitude of the signal generator was 100mVrms, and the initial frequency was 21KHz. As the frequency increased, the amplitude was also adjusted to keep the current at 19-21mA.
[0087] Step 4.4: Set the test status process description box to start frequency scanning, start data acquisition and result analysis; the description box displays the start of signal scanning and start of data acquisition and analysis.
[0088] Step 4.5: Set up a subroutine for capturing the acquisition results of the oscilloscope card. Use the maximum and minimum value functions of the array to capture the set of data with the largest amplitude in the array acquired by the oscilloscope. Set this set of data as the output control and display it as the resonant frequency and the amplitude of the output signal. At the same time, take the points 1KHz before and after the resonant frequency as indices in this subroutine to obtain the signal value with zero amplitude in the array.
[0089] Step 4.6: Compare the resonant frequency, output signal amplitude, and zero signal value with the preset values respectively, and determine whether the test results are qualified; if the format is qualified, the output control will show "pass" in green, and "fail" in red;
[0090] Step 4.7: Set up a spectrum monotonicity check control to perform monotonicity analysis on the spectrum of the icing sensor output signal. Specifically, capture the array of data acquired by the oscilloscope card, set up a For loop, and use the quotient and remainder method to take an amplitude value every 50 data sets. Then set up another For loop, and set up a shift register within the loop to shift the data from the previous step as the minuend value. Within the loop, subtract the data acquired in the previous step sequentially. If the differences are all negative, it is judged as monotonically decreasing; if the differences are all positive, it is judged as monotonically increasing. In this method, the spectrum curve from 21KHz to the resonance point should be monotonically increasing, and the spectrum curve from the resonance point to 27.5KHz should be monotonically decreasing.
[0091] Step 5: Stop the test and output the report.
[0092] Specifically, step 5 includes:
[0093] Step 5.1: Capture the test item output data from the above steps and add it to a table with a specified format. In the resulting table, you can manually fill in the tested product number, date, and operator information. The table includes four items: test item, test result, reference range, and pass / fail criteria.
[0094] Step 5.2: Configure the table save control so that the table output values are saved to the local disk;
[0095] Step 5.3: Set the description of test stop in the test status process description box.
[0096] Step 6: The test is over, and the system returns to its initial state.
[0097] Specifically, step 6 includes:
[0098] Step 6.1: Reset the output parameters of the signal generator and stop the output; reset the output parameters of the programmable DC power supply and stop the output; reset the DO state of the data acquisition card to a low level.
[0099] Step 6.2: Merge error clusters and set the error type description in the test status process description box;
[0100] Step 6.3: Close the configuration file information reference, close the loop, and the test ends.
[0101] In other embodiments of this application, the present invention provides an automatic testing system for a certain type of icing sensor based on LabVIEW. The specific hardware includes: a programmable DC power supply, a signal generator, an oscilloscope card, a data acquisition card, a switching module, an AC current transmitter, a computer, and a display module. All hardware is integrated in a standard test cabinet and installed separately on the cabinet shelves.
[0102] The programmable power supply is used to power the product under test; the product is powered by 28V.
[0103] The signal generator is used to generate the excitation signal required for the test process. After the excitation signal enters the icing sensor under test, the matching electronic converter provides an AC voltage to a pressure element of the pressure assembly, thereby generating mechanical vibration in the vibration converter. When the frequency of the AC voltage is equal to the longitudinal resonant frequency of the vibration converter, the vibration converter resonates.
[0104] The oscilloscope card is used to acquire the feedback signal of the icing sensor under test. When ice forms on the sensor's vibrating head, its mass changes, which causes the resonant frequency of the vibration transducer to change, and the output voltage signal also changes accordingly.
[0105] The data acquisition card is used to acquire the output of the AC current transmitter and control the opening and closing of the switch module. It uses the analog input (AI) terminal of the data acquisition card to acquire the real-time output voltage of the AC current transmitter and convert it into an AC current value. The selected AC current transmitter has an input of 0-100mA and an output of 0-1VDC, with a conversion factor of 10 between output voltage and current. The high-level signal output from the digital output (DO) terminal of the data acquisition card is used to control the opening and closing of the switch module. The DO terminal outputs a 5V high level, which continues until the control is closed.
[0106] The switching module is used to control the on / off state of the power supply circuit, signal input circuit, and signal output circuit. It consists of a transistor, a current-limiting resistor, a relay, a terminal block, and a circuit board. When the software controls the data acquisition card to output a high level at the DO terminal, the high-level signal drives the transistor to conduct, the corresponding relay's drive circuit is activated, the relay is turned on, and the corresponding main circuit is connected. The transistor, current-limiting resistor, relay, and terminal block are soldered and mounted on the circuit board, and the entire circuit board assembly is mounted on the chassis shelf.
[0107] The AC current transmitter is used to measure the feedback loop current of the icing detector and convert it into a DC voltage signal, which is then acquired by the AI port of the data acquisition card.
[0108] The computer is used to provide a communication interface for the above-mentioned devices and integrate test software. When the test devices are running, they control the hardware operation according to a preset process, and at the same time receive instructions from the operator and transmit key test information to the display module.
[0109] The display module is used to visually display the test results on a computer user interface developed using LabVIEW.
[0110] The programmable DC power supply and signal generator communicate with the computer via VISA serial communication, while the oscilloscope card and data acquisition card communicate with the computer via PCIe communication.
[0111] This invention provides an automatic testing method and system for a certain type of icing sensor based on LabVIEW, comprising: Step 1: Starting the software and writing the initialization parameters of the icing sensor testing software and the communication addresses of each hardware port into the configuration file; Step 2: Starting the test and obtaining the initialization parameters and the communication addresses of each hardware port from the configuration file; Step 3: Setting the switch state and connecting the corresponding relay; Step 4: Setting the frequency sweep parameters of the signal generator and starting the frequency sweep; setting the acquisition parameters of the oscilloscope card and starting the acquisition, and plotting the spectrum diagram based on the acquisition results; setting the acquisition parameters of the data acquisition instrument, analyzing the data and obtaining the test results; according to the plotted spectrum diagram, the point with the maximum amplitude is the output signal amplitude of this type of icing sensor, and the corresponding frequency point is the resonant frequency; the signal amplitude corresponding to 1KHz before and after the resonant frequency point in the plotted spectrum diagram is the zero signal value of this type of sensor; according to the plotted spectrum diagram, the curve before the resonant frequency point should be monotonically increasing, and the curve after the resonant frequency point should be monotonically decreasing; Step 5: Stopping the test and outputting a report; Step 6: Ending the test and restoring the initial state. This invention simplifies the testing process and improves production efficiency.
Claims
1. An automatic testing method for icing sensors based on LabVIEW, characterized in that, The method includes: Step 1: Write the initialization parameters of the icing sensor test software and the communication addresses of each hardware port into the configuration file; Step 2: Obtain the initialization parameters and communication addresses of each hardware port from the configuration file; Step 3: Set the switch status, and the corresponding relay in the switch module will be turned on; Step 4: Set the frequency sweep parameters of the signal generator, the acquisition parameters of the oscilloscope card, and the acquisition parameters of the data acquisition instrument; the signal generator starts frequency sweeping, sending an excitation signal to the icing sensor, and the icing sensor feeds back a sinusoidal signal according to the excitation signal; the oscilloscope card acquires the sinusoidal signal, plots a spectrum diagram based on the sinusoidal signal, analyzes the spectrum diagram to obtain the maximum amplitude point, determines the resonant frequency based on the maximum amplitude point, and sets the signal amplitude corresponding to 1KHz before and after the resonant frequency point as the zero signal value of the icing sensor; wherein, the maximum amplitude point is the output signal amplitude of the icing sensor, and the resonant frequency is the frequency point corresponding to the maximum amplitude point; the curve before the resonant frequency point is monotonically increasing, and the curve after the resonant frequency point is monotonically decreasing; the data acquisition instrument monitors the loop current of the signal generator in real time and adjusts the output amplitude of the signal generator in a timely manner according to the loop current; Step 5: Stop the test and output the report; Step 6: The test is over, and the system returns to its initial state.
2. The method according to claim 1, characterized in that, Step 1 includes: Step 1.1: Power on the test system, and each test module will automatically start and perform hardware initialization; Step 1.2: The user starts the test software interface on the computer. The software reads the information preset in the configuration file, which includes the serial port number and communication address of each hardware device. Step 1.3: The test software reads the serial port number and communication address from the previous step, communicates with the data acquisition instrument, signal generator, and programmable DC power supply via the VISA protocol, and communicates with the data acquisition card and oscilloscope card via the PCIe protocol.
3. The method according to claim 1, characterized in that, Step 2 includes: Step 2.1: Clear the test status description box on the test software test interface; Step 2.2: Set the output display control on the test interface of the test software to zero; Step 2.3: After clicking the "Start Test" control, the "Exit" control is disabled; Step 2.4: After clicking the "Start Test" control, the signal generator output parameters are reset and the output is stopped, the programmable DC power supply output parameters are reset and the output is stopped, and the data acquisition card DO status is reset to low level output. Step 2.5: Write the different execution states of steps 2, 3, 4, 5, and 6 into an array to form a state set, set the execution state order, and the program will automatically execute according to the set state set order when the test starts.
4. The method according to claim 1, characterized in that, Step 3 includes: Step 3.1: Set the data acquisition card slot number, set the DO port number that the data acquisition card needs to output high level, convert the number cluster into an array, and input it to the data acquisition card subroutine port number; Step 3.2: Set the DO port of the above number to output a high level; Step 3.3: Set the output status of the DO port in the test status process description box, corresponding to the relay on status description; Step 3.4: Set a delay time to ensure that all relays are in the correct state before the next frequency sweep begins.
5. The method according to claim 1, characterized in that, Step 4 includes: Step 4.1: Set the oscilloscope card acquisition parameters, including the oscilloscope card slot number, number of sampling channels, sampling range, sampling rate, number of sampling points, impedance matching method, and coupling method; Step 4.2: Set the frequency sweep parameters of the signal generator, including the signal generator output channel number, frequency sweep start frequency, frequency sweep end frequency, frequency sweep duration, output signal phase, and frequency sweep hold time; the frequency sweep duration affects the final frequency point acquisition; set the parameters according to the test frequency sweep range required by the icing sensor under test; Step 4.3: Set the amplitude adjustment control to detect the current in real time during the frequency sweep and adjust the output voltage. Specifically, set the data acquisition card acquisition parameters, including the AI acquisition channel number, sampling rate, number of sampling points, and sampling method. Take the data of the corresponding channel number of the AC current transmitter, multiply it by the conversion factor to obtain the actual current value, write this current value into the comparison function for range determination and forced switching, and use the output Boolean value as the branch selection of the next conditional structure. When the current is less than the current setting range, increase the output amplitude of the signal generator; when the current is greater than the current setting range, decrease the output amplitude of the signal generator. Step 4.4: Set the state description box in the test status process description box to start frequency sweeping, start data acquisition and result analysis; Step 4.5: Set up a subroutine for capturing the acquisition results of the oscilloscope card. Use the maximum and minimum value functions of the array to capture the set of data with the largest amplitude in the array acquired by the oscilloscope. Set this set of data as the output control and display it as the resonant frequency and the amplitude of the output signal. At the same time, take the points 1KHz before and after the resonant frequency as indices in this subroutine to obtain the signal value with zero amplitude in the array. Step 4.6: Compare the resonant frequency, output signal amplitude, and zero signal value with the preset values respectively, and determine whether the test results are qualified. Step 4.7: Set up a spectrum monotonicity check control to perform monotonicity analysis on the spectrum of the icing sensor output signal. Specifically, capture the array of acquisition results from the oscilloscope card, set up a For loop, and use the method of dividing by the quotient and taking the remainder to take an amplitude value every 50 sets of data. Then set up another For loop, and set up a shift register to shift the data from the previous step as the minuend value. In the loop, subtract the data obtained in the previous step in sequence. If the difference is negative, it is judged as monotonically decreasing; if the difference is positive, it is judged as monotonically increasing.
6. The method according to claim 1, characterized in that, Step 5 includes: Step 5.1: Capture the test item output data from the above steps and add it to the specified style table; Step 5.2: Configure the table save control to output the table to the local disk for saving; Step 5.3: Set the description of test stop in the test status process description box.
7. The method according to claim 1, characterized in that, Step 6 includes: Step 6.1: Reset the output parameters of the signal generator and stop the output; reset the output parameters of the programmable DC power supply and stop the output; reset the DO state of the data acquisition card to a low level. Step 6.2: Merge error clusters and set the error type description in the test status process description box; Step 6.3: Close the configuration file information reference, close the loop, and the test ends.
8. An automatic testing system for icing sensors based on LabVIEW, characterized in that, The testing system includes: a programmable DC power supply, a signal generator, an oscilloscope card, a data acquisition card, a switching module, an AC current transmitter, a computer, and a display module; Among them, the programmable DC power supply is used to power the product under test; The signal generator is used to generate the excitation signal required for the test process. After the excitation signal enters the icing sensor under test, the matching electronic converter provides an AC voltage to a pressure element of the pressure assembly, thereby generating mechanical vibration in the vibration converter. When the frequency of the AC voltage is equal to the longitudinal resonant frequency of the vibration converter, the vibration converter resonates. The oscilloscope card is used to acquire the feedback signal of the icing sensor under test. When ice forms on the sensor's vibrating head, its mass changes, which causes the resonant frequency of the vibration transducer to change, and the output voltage signal also changes accordingly. The data acquisition card is used to acquire the output of the AC current transmitter and control the opening and closing of the switch module. It uses the analog input terminal (AI) of the data acquisition card to acquire the real-time output voltage of the AC current transmitter and convert it into AC current value; it uses the high-level signal output from the digital output terminal (DO) of the data acquisition card to control the opening and closing of the switch module. The switching module is used to control the on / off state of the power supply circuit, signal input circuit, and signal output circuit. It consists of a transistor, a current-limiting resistor, a relay, a terminal block, and a circuit board. When the software controls the data acquisition card to output a high level at the DO terminal, the high-level signal drives the transistor to conduct, the corresponding relay's drive circuit is activated, the relay is turned on, and the corresponding main circuit is connected. An AC current transmitter is used to measure the feedback loop current of the icing detector and convert it into a DC voltage signal, which is then acquired by the AI port of the data acquisition card. The computer provides a communication interface for the above-mentioned devices and integrates test software. When the test devices are running, the computer controls the hardware operation according to a preset process, and at the same time receives instructions from the operator and transmits key test information to the display module. The display module is used to visually display the test results on a computer user interface developed using LabVIEW. The programmable DC power supply and signal generator communicate with the computer via VISA serial communication, while the oscilloscope card and data acquisition card communicate with the computer via PCIe communication.
Citation Information
Patent Citations
Ice heater function detection method
CN108008217A
Icing annunciator test equipment and test method
CN111122999A