A calibration method, calibration device and system for an analog channel of an oscilloscope
By generating the square wave to be calibrated and performing spectrum analysis, the compensation judgment results are determined, and the rapid and accurate calibration of the oscilloscope analog channel is achieved, which solves the problem of the inefficient calibration accuracy of the simulated channel and the low detection efficiency in the prior art.
Patent Information
- Application Number
- CN202411686454.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-25
- Publication Date
- 2025-03-04
- Estimated Expiration
- 2044-11-25
AI Technical Summary
The calibration method of existing oscilloscope analog channels relies on visual subjective judgment, and the debugging accuracy is not quantified. The traditional equal-amplitude sine wave sweep method detects square wave flatness in a time-consuming and low-efficiency manner, which cannot meet the needs of high timeliness and high accuracy.
By controlling the oscilloscope simulation channel, the square wave to be calibrated is generated based on a set of channel parameters and standard square waves, spectrum analysis is performed to obtain the ratio of harmonics and fundamental waves, compare the relationship between the ratio and the preset ratio range, determine the compensation judgment result, and calibrate the calibrated square wave based on this result until the preset flatness is satisfied.
It realizes fast and accurate calibration of the oscilloscope analog channel, improves the accuracy and efficiency of square wave flatness detection, and meets the needs of high ageing and high accuracy.
Smart Images

Figure CN119179039B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of oscilloscopes, and in particular to a calibration method, calibration equipment and system for an analog channel of an oscilloscope. Background Art
[0002] An oscilloscope is a widely used electronic measuring instrument that can transform electrical signals into visible images. After the electrical signal is input into the oscilloscope, it first undergoes some pre-processing through the oscilloscope's analog channel, such as amplification, reduction, and offset of the electrical signal, and then, after analog-to-digital conversion, waveform data processing, waveform drawing, etc., the waveform corresponding to the electrical signal is displayed on the display screen.
[0003] In the process of preprocessing the electrical signal through the analog channel of the oscilloscope, due to the inappropriate parameter settings of some electronic devices in the analog channel, the displayed waveform will be distorted. Therefore, the analog channel of the oscilloscope needs to be calibrated. The square wave flatness of the analog channel of the oscilloscope is an important indicator to measure the performance of the analog channel of the oscilloscope, and it is also an important link in the production and debugging of the oscilloscope. At present, in the process of producing oscilloscopes, operators adjust the square wave flatness by visual subjective judgment, the debugging accuracy is not quantifiable, and lacks reliability; in addition, when testing the square wave flatness, the analog channel is usually regarded as an ideal bandpass filter, and the equal-amplitude sine wave sweep method is used to detect the square wave flatness. It inputs equal-amplitude multi-frequency sine wave signals, and judges the square wave flatness of the analog channel of the oscilloscope according to the amplitude-frequency response of the sine wave signal. The flatter the amplitude-frequency response, the better. However, if this method is to detect accurately, it is necessary to detect data with enough frequency points and wide bandwidth, which is time-consuming and inefficient, and does not meet the high timeliness and high accuracy requirements of the analog channel calibration of the oscilloscope. Summary of the invention
[0004] In view of the above problems, the present application provides a calibration method, calibration device and system for an analog channel of an oscilloscope, which are described in detail below.
[0005] According to a first aspect, an embodiment provides a method for calibrating an analog channel of an oscilloscope, comprising:
[0006] Controlling an analog channel of the oscilloscope to be calibrated, and generating a square wave to be calibrated based on a set of channel parameters of the analog channel and a standard square wave;
[0007] Performing spectrum analysis on the square wave to be calibrated to obtain the ratio of the harmonic to the fundamental wave;
[0008] Comparing the ratio of the harmonic to the fundamental wave with a preset ratio range to determine a compensation determination result of the square wave to be calibrated;
[0009] Based on the compensation determination result, the flatness of the square wave to be calibrated is determined, so as to calibrate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness.
[0010] In one embodiment, the set of channel parameters includes: channel number, vertical scale, channel impedance, model signal, communication mode and server path.
[0011] In one embodiment, performing spectrum analysis on the square wave to be calibrated to obtain the ratio of harmonics to fundamental waves includes:
[0012] The square wave to be calibrated is subjected to Fourier transformation for spectrum analysis to obtain the ratio of the power of the nth harmonic to the power of the fundamental wave, wherein the ratio is represented by k.
[0013] In one embodiment, comparing the ratio of the harmonic to the fundamental wave with a preset ratio range to determine the compensation determination result of the square wave to be calibrated includes:
[0014] Determine the magnitude relationship between k and the preset ratio range, wherein the preset ratio range is represented by 1 / n±△, where △ is an error range, n is an odd number and 1≤n≤5, and 1 / n is a Fourier series ratio of the nth harmonic to the fundamental wave of an ideal square wave constructed by the square wave to be calibrated;
[0015] If k is less than 1 / n±△, it is determined that the compensation determination result of the square wave to be calibrated is under-compensation;
[0016] If k is within 1 / n±△, it is determined that the compensation determination result of the square wave to be calibrated is appropriate compensation;
[0017] If k is greater than the range of 1 / n±△, it is determined that the compensation determination result of the square wave to be calibrated is over-compensation.
[0018] In one embodiment, the determining the flatness of the square wave to be calibrated based on the compensation determination result, so as to calibrate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness, comprises:
[0019] If the compensation determination result of the square wave to be calibrated is under-compensation or over-compensation, it is determined that the flatness of the square wave to be calibrated is uneven, and a compensation prompt is given and a compensation cycle is entered to compensate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness; or,
[0020] If it is determined that the compensation determination result of the square wave to be calibrated is that the compensation is appropriate, then it is determined that the flatness of the square wave to be calibrated satisfies a preset flatness.
[0021] In one embodiment, the analog channel includes a plurality of fixed aperture resistors;
[0022] The prompting compensation and entering a compensation loop to compensate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness includes:
[0023] A compensation prompt window pops up to prompt one or more fixed hole position resistors to be adjusted;
[0024] In response to an instruction input by a user indicating that the adjustment is completed, the square wave to be calibrated is compensated according to the adjusted fixed hole position resistance to obtain a compensated square wave to be calibrated;
[0025] Determining whether the flatness of the compensated square wave to be calibrated meets a preset flatness;
[0026] If satisfied, the compensation cycle ends;
[0027] If not, compensation continues until the square wave to be calibrated meets the preset flatness.
[0028] In one embodiment, the controlling an analog channel of the oscilloscope to be calibrated to generate a square wave to be calibrated based on a set of channel parameters of the analog channel and a standard square wave includes:
[0029] Controlling to obtain a standard square wave input into the oscilloscope to be calibrated;
[0030] Set the set of channel parameters, or get the saved values of the set of channel parameters.
[0031] In one embodiment, the calibration method further comprises:
[0032] The display interface shows a preset display area;
[0033] The preset display area includes at least a first area and a second area, the first area is used to display the standard square wave and the square wave to be calibrated, and the second area is used to synchronously amplify and display segments of the standard square wave and segments of the square wave to be calibrated, and the first area and the second area can be displayed alternately, stacked or side by side.
[0034] In one embodiment, it also includes:
[0035] Obtaining parameter information of the square wave to be calibrated;
[0036] Generate an ideal square wave based on parameter information of the square wave to be calibrated;
[0037] Performing spectrum analysis on the square wave to be calibrated and the ideal square wave to obtain a spectrum waveform of the square wave to be calibrated and a spectrum waveform of the ideal square wave;
[0038] The frequency spectrum waveform of the square wave to be calibrated and the frequency spectrum waveform of the ideal square wave are displayed.
[0039] According to a second aspect, an embodiment provides a calibration device, comprising:
[0040] A communication interface, used to establish a communication connection with the oscilloscope to be calibrated;
[0041] A memory, used to store at least signals and data acquired through the communication interface; the memory is also used to store programs;
[0042] A display for displaying data;
[0043] A processor is used to implement the calibration method as described in any of the above embodiments by executing the program stored in the memory.
[0044] According to a third aspect, an embodiment provides a calibration system, comprising: a calibration device, a waveform generator, and an oscilloscope to be calibrated;
[0045] The waveform generator is connected to the calibration device and the oscilloscope to be calibrated, and is used to provide a standard square wave for the oscilloscope to be calibrated in response to a calibration command from the calibration device;
[0046] The calibration device is connected to the oscilloscope to be calibrated, and is used to perform square wave calibration on the oscilloscope to be calibrated, so as to implement the calibration method as described in any one of the above embodiments.
[0047] According to a fourth aspect, an embodiment provides a computer-readable storage medium, on which a computer program is stored, and the computer program can be executed by a processor to implement the calibration method as described in any of the above embodiments.
[0048] According to the calibration method, calibration device and system for the analog channel of the oscilloscope of the above-mentioned embodiment, the analog channel of the oscilloscope to be calibrated is controlled, and the square wave to be calibrated is generated based on a set of channel parameters of the analog channel and a standard square wave, and the spectrum analysis is performed on the square wave to be calibrated to obtain the ratio of the harmonic to the fundamental wave, and the size relationship between the ratio of the harmonic to the fundamental wave and the preset ratio range is compared to determine the compensation judgment result of the square wave to be calibrated, and the flatness of the square wave to be calibrated is determined based on the compensation judgment result, so as to calibrate the square wave to be calibrated until the square wave to be calibrated meets the preset flatness; therefore, the embodiment of the present invention determines the flatness of the square wave to be calibrated based on the ratio of the harmonic to the fundamental wave obtained after the spectrum analysis of the square wave to be calibrated, so as to calibrate the square wave to be calibrated, so that the square wave flatness detection and the calibration of the analog channel can be completed quickly and accurately, meeting the requirements of high timeliness and high accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1 is a schematic diagram of an example of a calibration system for an analog channel of an oscilloscope;
[0050] Figure 2 is an example schematic diagram of a calibration device;
[0051] Figure 3 A flowchart of a method for calibrating an analog channel of an oscilloscope according to an embodiment;
[0052] Figure 4 This is a schematic diagram of the display screen of the oscilloscope to be calibrated after entering the zoom function;
[0053] Figure 5 A flow chart of a method for calibrating an analog channel of an oscilloscope according to another embodiment;
[0054] Figure 6 Schematic diagram of the spectrum waveform of the square wave to be calibrated and the ideal square wave;
[0055] Figure 7 A schematic diagram of the spectrum waveform of the square wave to be calibrated and the ideal square wave at a predetermined frequency;
[0056] Figure 8 A schematic diagram of the spectrum waveform of the square wave to be calibrated and the ideal square wave at a predetermined frequency;
[0057] Fig. 9 Schematic diagram of the display interface of the calibration device. DETAILED DESCRIPTION
[0058] The present application is further described in detail below by specific embodiments in conjunction with the accompanying drawings. Wherein similar elements in different embodiments adopt associated similar element numbers. In the following embodiments, many detailed descriptions are intended to enable the present application to be better understood. However, those skilled in the art can easily recognize that some of the features can be omitted in different situations, or can be replaced by other elements, materials, and methods. In some cases, some operations related to the present application are not shown or described in the specification, in order to avoid the core part of the present application being overwhelmed by too much description, and for those skilled in the art, it is not necessary to describe these related operations in detail, and they can fully understand the related operations based on the description in the specification and the general technical knowledge in the art.
[0059] In addition, the features, operations or characteristics described in the specification can be combined in any appropriate manner to form various implementations. At the same time, the steps or actions in the method description can also be interchanged or adjusted in a manner that is obvious to those skilled in the art. Therefore, the various sequences in the specification and the drawings are only for the purpose of clearly describing a certain embodiment and are not meant to be a required sequence, unless otherwise specified that a certain sequence must be followed.
[0060] The serial numbers assigned to the components herein, such as "first", "second", etc., are only used to distinguish the objects described and do not have any order or technical meaning. The "connection" and "coupling" mentioned in this application, unless otherwise specified, include direct and indirect connections (couplings).
[0061] In the embodiment of the present application, the calibration device automatically controls the oscilloscope to be calibrated to perform square wave flatness detection and performs calibration according to the detection result, so that the calibration of the analog channel of the oscilloscope is more efficient and accurate.
[0062] Please refer to Figure 1 An example of a calibration system for an analog channel of an oscilloscope is provided, including a calibration device 101, an oscilloscope to be calibrated 102, and a waveform generator 103, for calibrating the oscilloscope to be calibrated 102, wherein the calibration device 101 can be a device with processing functions such as a PC, a host computer, etc., and the calibration device 101 has a communication interface, and the calibration device 101 is connected to the communication interface of the oscilloscope to be calibrated 102 and the communication interface of the waveform generator 103 through the communication interface. In one embodiment, the communication interface can be a LAN or USB interface. The oscilloscope to be calibrated 102 and the waveform generator 103 are connected through a BNC signal line. Generally speaking, an oscilloscope has multiple analog channels, and each analog channel corresponds to an analog channel. During each calibration, one analog channel is calibrated, that is, the BNC signal line connects the channel to be calibrated of the oscilloscope to be calibrated 102 and the waveform generator 103.
[0063] Please refer to Figure 2 , an example of a calibration device 101 is provided, and the calibration device 101 includes: a communication interface 1011, a memory 1012, a display 1013 and a processor 1014.
[0064] In this embodiment, the communication interface 1011, the memory 1012, the display 1013 and the processor 1014 are the main components of the calibration device 101. Of course, the calibration device 101 may also include some other components, which will not be described in detail here.
[0065] The communication interface 1011 is used to establish a communication connection with the oscilloscope to be calibrated and the waveform generator, and it can be a USB interface or a LAN interface;
[0066] The memory 1012 can be used as a computer-readable storage medium, and is used here to store a program, which may be a program code corresponding to the calibration method for the analog channel of the oscilloscope provided in the present application.
[0067] The processor 1014 is connected to the memory 1012 and is used to execute the program stored in the memory 1012 to implement the calibration method disclosed in the embodiment of the present application.
[0068] The display 1013 is used to display data, and the display may be a display screen or a touch display screen.
[0069] The following is an explanation of the method flow in the calibration device 101.
[0070] Please refer to Figure 3 , Figure 3 A method for calibrating an analog channel of an oscilloscope is shown, comprising the following steps:
[0071] Step 201: the calibration device 101 controls an analog channel of an oscilloscope to be calibrated through a communication interface, and generates a square wave to be calibrated based on a set of channel parameters of the analog channel and a standard square wave.
[0072] In one embodiment, the calibration device 101 controls the waveform generator 103 to generate a standard square wave according to a preset configuration file through a communication interface, and inputs the standard square wave into a template channel of the oscilloscope to be calibrated.
[0073] The preset configuration file includes parameters such as the duty cycle and amplitude of the standard square wave. For example, the waveform generator 103 is controlled to generate a standard square wave with a duty cycle of 50% and an amplitude of six grids on the screen at the corresponding gear of the oscilloscope. In other embodiments, the standard square wave may also be output by other devices, which is not specifically limited in this embodiment.
[0074] It should be noted that, during the entire calibration process, the standard square wave is continuously input into the oscilloscope to be calibrated. After the entire calibration is completed, the calibration device 101 will control to stop generating the standard square wave.
[0075] In one embodiment, after the standard square wave is input to the oscilloscope to be calibrated, the oscilloscope to be calibrated displays the square wave to be calibrated corresponding to the standard square wave in the center of its display screen under its auto set (Auto set) function. In this process, different channel parameters can be set to change the parameters of the analog channel, thereby generating different square waves to be calibrated. In this embodiment, the channel parameters can at least include: channel number, vertical scale, channel impedance, model signal, communication mode and server path. This embodiment is explained by taking the vertical scale and channel impedance as an example. Setting different vertical scales and channel impedances can change the attenuation value and channel impedance value of the analog channel of the oscilloscope to be calibrated. It should be noted that when different vertical scales and channel impedances are set, the same standard square wave will be processed with different parameters in the analog channel under different vertical scales and channel impedances, so that the generated calibration square waves are different, that is, the displayed waveforms will also be different.
[0076] The values of the channel parameters have a fixed number of groups, which can be obtained through a preset configuration file. For example, the vertical scale can be three levels, and the channel impedance can be two values, then the number of groups after combination can be 6 groups. Therefore, in one embodiment, when setting the channel parameters, the calibration device 101 can control the oscilloscope to be calibrated to set these 6 groups of channel parameters one by one.
[0077] It should be noted that the channel parameters may be pre-saved values or may be set by the user.
[0078] Step 202: The calibration device 101 performs spectrum analysis on the square wave to be calibrated to obtain the ratio of the power of the nth harmonic to the power of the fundamental wave, where the ratio is denoted by k.
[0079] In one embodiment, the ratio of the power of the nth harmonic to the power of the fundamental wave may be the ratio of the voltage amplitude of the nth harmonic to the voltage amplitude of the fundamental wave, or may be other forms of the ratio of the nth harmonic to the fundamental wave, which will not be described one by one in this embodiment.
[0080] It should be noted that for the ideal square wave constructed by the square wave to be calibrated, the Fourier series ratio of each harmonic to the fundamental wave is determined. For example, the Fourier series ratio of the nth harmonic to the fundamental wave of the ideal square wave is 1 / n. It can be seen that the energy relationship between the fundamental wave and the nth harmonic of the ideal square wave is determined, so the amount by which the harmonic deviates from the ideal value is the deviation value of the analog channel at the frequency point of the harmonic. The ideal square wave of this embodiment is a square wave generated when the frequency is relatively low and the square wave source has been verified to be problem-free. In addition, the ideal square wave constructed by the square wave to be calibrated refers to the ideal square wave generated according to the parameters (frequency, number of sampling points and amplitude) of the square wave to be calibrated.
[0081] In addition, since harmonic energy decays quickly, the measurement accuracy will not be satisfactory when the harmonic energy is too small, so generally only harmonics within the 5th harmonic are analyzed. If the value of n is too large, the error will be relatively large.
[0082] In one embodiment, the Fourier series expression of the ideal square wave constructed by the square wave to be calibrated is as follows:
[0083] ;
[0084] in, t is the sampling time, f is the frequency of an ideal square wave, A is the amplitude. In the above expression, is the Fourier series of the fundamental wave, is the Fourier series of the third harmonic, is the Fourier series of the 5th harmonic.
[0085] Step 203: the calibration device 101 compares the ratio of the harmonic to the fundamental wave with a preset ratio range to determine a compensation determination result of the square wave to be calibrated.
[0086] As mentioned above, for the ideal square wave constructed by the square wave to be calibrated, the Fourier series ratio of its nth harmonic to the fundamental wave is 1 / n. Then, for the square wave to be calibrated, if the power ratio of its nth harmonic to the fundamental wave is also 1 / n, the square wave to be calibrated is flat. However, in actual circumstances, the power ratio of the nth harmonic to the fundamental wave of the square wave to be calibrated cannot be the same as that of the ideal square wave. Therefore, the embodiment of the present application sets a preset ratio range, which can be 1 / n±△, △ is the error range, and the error range can be set according to the calibration accuracy of the oscilloscope to be calibrated, for example, it can be 5 thousandths.
[0087] In one embodiment, comparing the magnitude relationship between the power ratio k of the harmonic to the fundamental wave and the preset ratio range to determine the compensation determination result of the square wave to be calibrated includes: determining the magnitude relationship between the power ratio k and the preset ratio range; and determining the compensation determination result according to the following three magnitude relationships between the power ratio k and the preset ratio range:
[0088] (1) If k is less than 1 / n±△, it is determined that the compensation judgment result of the square wave to be calibrated is under-compensation.
[0089] (2) If k is within 1 / n±△, then the compensation judgment result of the square wave to be calibrated is determined to be appropriate compensation.
[0090] (3) If k is greater than 1 / n±△, it is determined that the compensation judgment result of the square wave to be calibrated is overcompensation.
[0091] Step 204: the calibration device 101 determines the flatness of the square wave to be calibrated based on the compensation determination result, so as to calibrate the square wave to be calibrated until the square wave to be calibrated meets the preset flatness.
[0092] According to the above three compensation judgment results, if the compensation judgment result of the square wave to be calibrated is under-compensation or over-compensation, it can be determined that the flatness of the square wave to be calibrated is uneven, and a compensation prompt is given and a compensation cycle is entered to compensate the square wave to be calibrated until the square wave to be calibrated meets the preset flatness; if it is determined that the compensation judgment result of the square wave to be calibrated is that the compensation is appropriate, it is determined that the flatness of the square wave to be calibrated meets the preset flatness, that is, the calibration is completed.
[0093] In some embodiments, the analog channel of the oscilloscope to be calibrated includes multiple electronic devices. When it is determined that the flatness of the square wave to be calibrated is not flat, the operator needs to adjust the parameters of the electronic devices of the analog channel. In one embodiment, taking the electronic device as a fixed hole resistor as an example, after determining that the flatness of the square wave to be calibrated is not flat, prompting compensation and entering a compensation cycle includes:
[0094] Step 2041: A compensation prompt window pops up to prompt one or more fixed hole position resistors to be adjusted. In one embodiment, a compensation prompt window may pop up in the display interface of the calibration device, and the compensation prompt window displays the identification of the fixed hole position resistor to be adjusted, such as the identification of the hole position resistor No. 1. In addition, the serial number of each hole position resistor in the analog channel may be described in the operation manual for the user to refer to when adjusting.
[0095] Step 2042: In response to the instruction of adjustment completion input by the user, the square wave to be calibrated is compensated according to the adjusted fixed hole position resistors to obtain the compensated square wave to be calibrated. The user adjusts the resistance values of one or more fixed hole position resistors to be adjusted prompted in the compensation prompt window, and after the user believes that the adjustment is completed, inputs the instruction of adjustment completion (such as clicking the virtual button of adjustment completion in the display interface), so that the oscilloscope to be calibrated compensates the square wave to be calibrated according to the adjusted fixed hole position resistors to obtain the compensated square wave to be calibrated.
[0096] Step 2043: Determine whether the flatness of the compensated square wave to be calibrated meets the preset flatness. According to the method flow of steps 202 to 204, it is determined again whether the flatness of the compensated square wave to be calibrated meets the preset flatness.
[0097] Step 2044: If the flatness of the compensated square wave to be calibrated meets the preset flatness, the compensation cycle ends.
[0098] Step 2045: If the flatness of the square wave to be calibrated after compensation does not meet the preset flatness, then continue to return to step 2041 to perform compensation until the square wave to be calibrated meets the preset flatness.
[0099] When a compensation prompt window pops up in step 2041 to prompt one or more fixed hole position resistors to be adjusted, although the user can confirm the fixed hole position resistors to be adjusted according to the content displayed in the compensation prompt window, it is not clear how to adjust (to increase or decrease) and when the adjustment is completed. Therefore, in some embodiments, after the compensation prompt window pops up in step 2041, the zoom display function can be controlled to enter, that is, the preset display area of the display interface of the calibration device can include at least a first area and a second area, the first area is used to normally display the standard square wave and the square wave to be calibrated, and the second area is used to synchronously zoom in and display the segments of the standard square wave and the segments of the square wave to be calibrated, such as Figure 4 As shown, Figure 4The preset display area shown only displays the square wave to be calibrated. The upper part of the display interface is the second area, and the lower part is the first area. The segment in the rectangular frame A in the first area is the segment enlarged and displayed in the second area. In this way, when the user adjusts the fixed hole position resistance, the square wave to be calibrated will change accordingly. It can be judged whether the current adjustment direction is correct based on whether the flatness of the enlarged segment displayed in the second area is getting better or worse. It can also be judged whether the current adjustment is completed based on whether the enlarged segment displayed in the second area looks flat, so as to improve the efficiency of user adjustment. In one embodiment, the first area and the second area can be displayed alternately, stacked or side by side, so that the standard square wave can be used as a reference, so that the user can adjust the square wave to be calibrated by referring to the standard square wave through the displayed waveform.
[0100] In some other embodiments, in step 202, the spectral analysis is performed on the square wave to be calibrated to obtain the ratio of the harmonic to the fundamental wave. Figure 5 , and may also include the following steps:
[0101] Step 501: Obtain parameter information of the square wave to be calibrated, wherein the parameter information may be the sampling rate, number of sampling points and amplitude of the square wave to be calibrated.
[0102] Step 502: Generate an ideal square wave based on the parameter information of the square wave to be calibrated. It should be noted that the ideal square wave is not equivalent to the standard method. The standard square wave is a waveform output by a third-party medium such as a waveform generator that can meet the user's accuracy requirements or is infinitely close to the ideal square wave, while the ideal square wave is a waveform constructed by a formula based on the parameter information in the above step 501. x ( t ) is expressed as follows:
[0103] ;
[0104] ;
[0105] in, t is the sampling time, t The value range is [0, △ T *1, △ T *2,…△ T *N],△ T is the sampling interval, △ T = N / fs , t%T For the modulo operation, T is the period of the ideal square wave signal, T =1 / f , f is the frequency of the ideal square wave signal, A For the amplitude.
[0106] Step 503: Perform spectrum analysis on the square wave to be calibrated and the ideal square wave to obtain the spectrum waveform of the square wave to be calibrated and the spectrum waveform of the ideal square wave.
[0107] Step 504: Display the spectrum waveform of the square wave to be calibrated and the spectrum waveform of the ideal square wave. Figure 6 , Figure 6 The spectrum waveform of the square wave to be calibrated and the spectrum waveform of the ideal square wave are shown, wherein the spectrum waveform of the square wave to be calibrated is a line composed of symbols “+”, and the spectrum waveform of the ideal square wave is a solid line.
[0108] From the above steps 501 to 504, the user can intuitively see the difference between the spectrum waveform of the square wave to be calibrated and the spectrum waveform of the ideal square wave at a certain frequency through the displayed spectrum waveform of the square wave to be calibrated and the spectrum waveform of the ideal square wave. Please refer to Figure 7 and Figure 8 , Figure 7 The schematic diagram shows the spectrum waveform ("+") of the square wave to be calibrated and the spectrum waveform (solid line) of the ideal square wave at 1000 Hz. It can be seen that the amplitude of the ideal square wave at 1000 Hz is greater than the amplitude of the square wave to be calibrated. Figure 8 A schematic diagram showing the spectrum waveform (“+”) of the square wave to be calibrated at 1000 Hz and the spectrum waveform (solid line) of the ideal square wave is shown. It can be seen that the amplitude of the square wave to be calibrated at 1000 Hz is greater than that of the ideal square wave.
[0109] Please refer to Fig. 9 , Fig. 9 An example of a display interface for square wave flatness calibration of an analog channel of an oscilloscope to be calibrated in the calibration device 101 is shown, and the display interface displays a square wave signal setting area 901, an oscilloscope setting area 902, a test display area 903, a waveform display area 904 and a test log area 905.
[0110] The square wave signal setting area 901 is used to set the parameters of the waveform generator 103 so that it can output a standard square wave that meets the requirements. The set parameters at least include the model, communication mode, output channel and output frequency of the waveform generator 103.
[0111] The oscilloscope setting area 902 is used to set the channel parameters of the oscilloscope to be calibrated, which may include the channel number (for selecting an analog channel), vertical scale, channel impedance, model signal, communication mode and server path, etc.
[0112] The test display area 903 is used to display information such as the value of the harmonic n, the error range Δ (eg, 0.5%) and the actual error.
[0113] The waveform display area 904 is used to display the spectrum waveform of the square wave to be calibrated, the ideal square wave, and the waveforms of the square wave to be calibrated and the standard square wave. The waveform display area 904 can switch the display content through user input, which is used for the spectrum waveform (FFT) display area and the square wave waveform display area respectively.
[0114] The test log area 905 is used to record relevant data of each calibration, which may include but is not limited to calibration time, calibration times, etc.
[0115] In some embodiments, after step 204 , the method may further include: storing the square wave to be calibrated and the spectrum waveform of the square wave to be calibrated in the memory 1012 for subsequent viewing by the user.
[0116] Those skilled in the art will appreciate that all or part of the functions of the various methods in the above-mentioned embodiments can be implemented by hardware or by computer programs. When all or part of the functions in the above-mentioned embodiments are implemented by computer programs, the program can be stored in a computer-readable storage medium, and the storage medium can include: read-only memory, random access memory, disk, optical disk, hard disk, etc., and the program is executed by a computer to implement the above-mentioned functions. For example, the program is stored in the memory of the device, and when the program in the memory is executed by the processor, all or part of the above-mentioned functions can be implemented. In addition, when all or part of the functions in the above-mentioned embodiments are implemented by computer programs, the program can also be stored in a storage medium such as a server, another computer, disk, optical disk, flash disk or mobile hard disk, and can be downloaded or copied and saved in the memory of the local device, or the system of the local device is updated, and when the program in the memory is executed by the processor, all or part of the functions in the above-mentioned embodiments can be implemented.
[0117] The above specific examples are used to illustrate the present application, which is only used to help understand the present application and is not intended to limit the present application. For technicians in the technical field to which the present application belongs, they can also make some simple deductions, deformations or substitutions based on the ideas of the present application.
Claims
1. A method for calibrating an analog channel of an oscilloscope, characterized in that: include: Controlling an analog channel of the oscilloscope to be calibrated, and generating a square wave to be calibrated based on a set of channel parameters of the analog channel and a standard square wave; Performing spectrum analysis on the square wave to be calibrated to obtain the ratio of the harmonic to the fundamental wave; Comparing the ratio of the harmonic to the fundamental wave with a preset ratio range to determine a compensation determination result of the square wave to be calibrated; Based on the compensation determination result, the flatness of the square wave to be calibrated is determined, so as to calibrate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness.
2. The calibration method according to claim 1, characterized in that: The set of channel parameters includes: channel number, vertical gear, channel impedance, model signal, communication mode and server path.
3. The calibration method according to claim 1, characterized in that: The performing spectrum analysis on the square wave to be calibrated to obtain the ratio of the harmonic to the fundamental wave includes: The square wave to be calibrated is subjected to Fourier transformation for spectrum analysis to obtain the ratio of the power of the nth harmonic to the power of the fundamental wave, wherein the ratio is represented by k.
4. The calibration method according to claim 3, characterized in that: The comparing the ratio of the harmonic to the fundamental wave with the preset ratio range to determine the compensation determination result of the square wave to be calibrated includes: Determine the magnitude relationship between k and the preset ratio range, wherein the preset ratio range is represented by 1 / n±△, where △ is an error range, n is an odd number and 1≤n≤5, and 1 / n is a Fourier series ratio of the nth harmonic to the fundamental wave of an ideal square wave constructed by the square wave to be calibrated; If k is less than 1 / n±△, it is determined that the compensation determination result of the square wave to be calibrated is under-compensation; If k is within 1 / n±△, it is determined that the compensation determination result of the square wave to be calibrated is appropriate compensation; If k is greater than the range of 1 / n±△, it is determined that the compensation determination result of the square wave to be calibrated is over-compensation.
5. The calibration method according to claim 4, characterized in that: The step of determining the flatness of the square wave to be calibrated based on the compensation determination result, so as to calibrate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness, comprises: If the compensation determination result of the square wave to be calibrated is under-compensation or over-compensation, it is determined that the flatness of the square wave to be calibrated is uneven, and a compensation prompt is given and a compensation cycle is entered to compensate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness; or, If it is determined that the compensation determination result of the square wave to be calibrated is that the compensation is appropriate, then it is determined that the flatness of the square wave to be calibrated satisfies a preset flatness.
6. The calibration method according to claim 5, characterized in that: The analog channel includes a plurality of fixed hole position resistors; The prompting compensation and entering a compensation loop to compensate the square wave to be calibrated until the square wave to be calibrated meets a preset flatness includes: A compensation prompt window pops up to prompt one or more fixed hole position resistors to be adjusted; In response to an instruction input by a user indicating that the adjustment is completed, the square wave to be calibrated is compensated according to the adjusted fixed hole position resistance to obtain a compensated square wave to be calibrated; Determining whether the flatness of the compensated square wave to be calibrated meets a preset flatness; If satisfied, the compensation cycle ends; If not, compensation continues until the square wave to be calibrated meets the preset flatness.
7. The calibration method according to claim 1, characterized in that: The controlling the analog channel of the oscilloscope to be calibrated, and generating the square wave to be calibrated based on a set of channel parameters of the analog channel and a standard square wave, comprises: Controlling to obtain a standard square wave input into the oscilloscope to be calibrated; Set the set of channel parameters, or get the saved values of the set of channel parameters.
8. The calibration method according to any one of claims 1 to 7, characterized in that: The calibration method further comprises: The display interface shows a preset display area; The preset display area includes at least a first area and a second area, the first area is used to display the standard square wave and the square wave to be calibrated, and the second area is used to synchronously amplify and display segments of the standard square wave and segments of the square wave to be calibrated, and the first area and the second area can be displayed alternately, stacked or side by side.
9. The calibration method according to any one of claims 1 to 7, characterized in that: Also includes: Obtaining parameter information of the square wave to be calibrated; Generate an ideal square wave based on parameter information of the square wave to be calibrated; Performing spectrum analysis on the square wave to be calibrated and the ideal square wave to obtain a spectrum waveform of the square wave to be calibrated and a spectrum waveform of the ideal square wave; The frequency spectrum waveform of the square wave to be calibrated and the frequency spectrum waveform of the ideal square wave are displayed.
10. A calibration device, characterized in that: include: A communication interface, used to establish a communication connection with the oscilloscope to be calibrated; A memory, for storing at least signals and data acquired through the communication interface; The memory is also used to store programs; A display for displaying data; A processor, configured to implement the calibration method according to any one of claims 1 to 9 by executing the program stored in the memory.
11. A calibration system, characterized in that: include: Calibration equipment, waveform generators, and oscilloscopes to be calibrated; The waveform generator is connected to the calibration device and the oscilloscope to be calibrated, and is used to provide a standard square wave for the oscilloscope to be calibrated in response to a calibration command from the calibration device; The calibration device is connected to the oscilloscope to be calibrated, and is used to perform square wave calibration on the oscilloscope to be calibrated, so as to implement the calibration method according to any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that: A computer program is stored on the medium, and the computer program can be executed by a processor to implement the calibration method according to any one of claims 1 to 9.
Citation Information
Patent Citations
Digital oscilloscope and automatic calibration device and method for channel attenuation compensation of digital oscilloscope
CN111289787A
System and method for timing calibration of time-interleaved data converters
CN1859009A