Speed Integration Method and Circuit for Data Acquisition
Through the main control chip, the multi-speed signal is identified and dynamic torque calculation and forward and reverse rotation judgment is performed, the high sampling rate and synchronization problems in digital procurement technology are solved, and high-precision speed measurement and fault diagnosis are achieved.
Patent Information
- Application Number
- CN202510671210.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-23
- Publication Date
- 2025-07-29
- Estimated Expiration
- 2045-05-23
AI Technical Summary
The existing digital and procurement technology cannot meet the high sampling rate requirements for angle measurements such as torsional vibration and torque, and the synchronization of multiple speed signals is poor, resulting in low measurement accuracy and low cost-effectiveness.
Multi-speed signals are obtained through the main control chip, effective speed pulses are identified using five registers, and synchronous beats are provided in combination with the PLL frequency division module, dynamic torque calculation and forward and reverse rotation judgment are performed, and synchronously transmitted with AD data stream through the UDP protocol.
It realizes high-speed synchronous measurement of multiple speeds, meets the measurement needs of dynamic torque, rotation direction and fault positioning, improves measurement accuracy and system stability, and ensures real-time and synchronization of data flow.
Smart Images

Figure CN120195422B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of rotational speed acquisition, and in particular to a rotational speed integration method and circuit for data acquisition. Background Art
[0002] Data acquisition is widely used in the measurement and analysis of rotating machinery. By converting analog signals such as front-end noise, vibration, and rotational speed into digital signals and uploading them to a PC for software data analysis, the characteristics of rotating machinery can be analyzed.
[0003] The rotational speed reflects the number of rotations of a rotating body per unit time. The fluctuation of the rotational speed reflects the imbalance of the rotating object or the instability of the load. By calculating the continuous change in rotational speed, angular acceleration information can be obtained; through torsional vibration analysis, the frequency spectrum in the angular domain can be obtained. By measuring the phase difference change of the rotational speed signals at different positions on the rotating shaft, the torsional deformation amount of the rotating shaft can be obtained, and thus the torque can be calculated. Conventional noise and vibration signals can obtain order data related to product characteristics through synchronous analysis with the rotational speed. These analysis data are crucial for evaluating the operating state of the equipment, fault monitoring, and analysis.
[0004] For rotational speed measurement, optoelectronic sensors, Hall sensors, etc. are generally used. When the rotor rotates one circle, one or more rotation pulses are obtained, and the rotational speed is calculated by counting the number of pulses within a unit time or calculating the time interval between adjacent pulses. The rotational speed is directly displayed or sent to a third party through a communication interface.
[0005] The rotational speed signal is a pulse signal. Only the threshold voltage is used to judge the high and low levels, and the requirement for the amplitude linearity of the signal is relatively low; however, when performing torsional vibration and torque measurements, an ultra-high sampling rate is required, generally greater than 10 MHz, to collect the rapid fluctuations of the rotational speed. The conventional analog acquisition channels of data acquisition generally use expensive high-bit AD chips with a relatively high dynamic range, but their sampling rate is generally less than 200 kHz, and only the rotational speed refresh at the ms level can be achieved, which cannot meet the requirements for the sampling rate in angular domain measurements such as torsional vibration and torque.
[0006] Currently, data acquisition generally provides the function of collecting rotational speed signals through conventional front-end analog channels, which can meet the synchronous acquisition requirements of rotational speed and noise and vibration signals for order analysis; however, the sampling rate of this rotational speed signal is relatively low, which cannot meet the requirements for torsional vibration, torque, and forward and reverse measurements, and occupies the conventional analog acquisition channels, with extremely low cost performance.
[0007] When data acquisition is paired with a separate rotational speed measurement device and the two are collected separately, it is difficult to ensure synchronization. Generally, only constant rotational speed analysis can be performed, and during speed regulation measurement, such as order tracking, serious signal distortion will occur. Controlling the synchronization index of the two devices will greatly increase the analysis difficulty;
[0008] Separately measuring in the angular acceleration domain and the linear acceleration domain has low efficiency, is troublesome to use, and has a low cost performance, making it difficult to fully meet the performance evaluation requirements of rotating machinery. Summary of the Invention
[0009] Object of the Invention: The object of the present invention is to solve the technical problems in the prior art and provide a data acquisition rotational speed integration method and circuit.
[0010] Technical Solution:
[0011] In a first aspect, the present application proposes a data acquisition rotational speed integration method, including the steps of:
[0012] The main control chip obtains a rotational speed pulse signal, where the rotational speed pulse signal includes a first rotational speed signal and a second rotational speed signal at different positions of the rotating machinery, and a third rotational speed signal configured as a reference position at one end of the rotating machinery linkage component;
[0013] By configuring five registers through the main control chip, the effective rotational speed pulses of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal are respectively identified to obtain a rotational speed data signal, where the rotational speed data includes the number of pulse clocks between adjacent pulses of the first rotational speed signal and the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal;
[0014] Perform dynamic torque calculation and forward / reverse rotation judgment through the rotational speed data signal;
[0015] Output the rotational speed data signal through the main control chip.
[0016] Preferably, configuring five registers through the main control chip to respectively identify the effective rotational speed pulses of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal to obtain a rotational speed data signal includes:
[0017] Use the current input status register to store the current level status of the rotational speed signal in real time;
[0018] Use the input status buffer time register to record the holding time after the change of the rotational speed signal level to judge the stability of the signal change;
[0019] Use the current clock status register to store the stable signal status after interference filtering;
[0020] Use the previous clock status register to save the rotational speed signal status of the previous clock cycle for comparison with the current signal;
[0021] Use the pulse output valid register to indicate whether there is an effective rotational speed pulse signal, and set it to 1 when the signal change is effective.
[0022] Preferably, five registers are configured by the main control chip to respectively identify the valid speed pulses of the first speed signal, the second speed signal, and the third speed signal to obtain a speed data signal, including using the 25MHz clock output by the pll frequency division module as the synchronization beat to drive multiple registers in real time. The processing flow of each clock beat is as follows:
[0023] Read the logic level of the speed input interface, compare the level with the value in the current input status buffer register, and update the current input status buffer to the level value of the current input interface at the same time;
[0024] If the comparison result is different, indicating that the current speed input signal level has changed, clear the input status buffer time register. If the comparison result is the same, judge whether the value of the input status buffer time register is greater than the predetermined value;
[0025] If the input status buffer time register is less than the predetermined value, add 1 to the input status buffer time register. If the input status buffer time register reaches the predetermined value, confirm the level jump of the speed input signal, update the current clock status register to the value of the current input status buffer, and clear the input status buffer time register;
[0026] After the current clock status register is updated, judge whether the current clock status register is 1 and whether the previous clock status register is 0. If it is judged that there is a rising edge change, set the pulse output valid register to 1, otherwise clear the pulse output valid register, update the previous clock status register to the value of the current clock status register, and exit the current clock processing.
[0027] Preferably, dynamic torque calculation and forward / reverse rotation judgment are performed through the speed data signal, including:
[0028] Calculate the speeds of the first speed signal and the second speed signal by the number of clock pulses between adjacent pulses of the first speed signal and the second speed signal, including:
[0029] ;
[0030] Among them, rmp is the speed, H is the clock frequency, and t is the number of clock pulses between adjacent pulses;
[0031] The number of turns of the third speed signal is used in combination with the first speed signal and the second speed signal as the reference pulse point of the encoder to align the pulses of the first speed signal and the second speed signal. Among them, each time the number of turns of the third speed signal changes, the pulses of the first speed signal and the second speed signal can be aligned with reference to the change of the third speed signal.
[0032] Preferably, dynamic torque calculation is performed based on the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the number of delay clocks between the second rotational speed signal and the first rotational speed signal, including:
[0033] Calculate the rotation angle, and the formula is as follows:
[0034] ;
[0035] where NUM A is the number of adjacent pulse clocks of the first rotational speed signal, and NUM1 and NUM2 are the number of delay clocks between the second rotational speed signal and the first rotational speed signal under no-load and load conditions, respectively;
[0036] The formula for calculating the dynamic torque is as follows:
[0037] ;
[0038] where T is the dynamic torque, G is the shear modulus of the shaft material, and the shear modulus is the deformation ability of the material under shear stress, and J is the polar moment of inertia of the shaft.
[0039] Preferably, forward and reverse rotation judgment is performed based on the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the number of delay clocks between the second rotational speed signal and the first rotational speed signal, including:
[0040] Judge that if half of the number of adjacent pulse clocks of the first rotational speed signal is greater than the number of delay clocks between the second rotational speed signal and the first rotational speed signal, it is forward rotation;
[0041] Judge that if half of the number of adjacent pulse clocks of the first rotational speed signal is less than the number of delay clocks between the second rotational speed signal and the first rotational speed signal, it is reverse rotation.
[0042] Preferably, the process of the main control chip for forward and reverse rotation judgment is as follows:
[0043] Configure the rotational speed pulse registers of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal respectively through the main control chip;
[0044] The register of the number of adjacent pulse clocks of the first rotational speed signal and the second rotational speed signal;
[0045] The register of the number of turns of the third rotational speed signal and the number of delay clocks between the second rotational speed signal and the first rotational speed signal;
[0046] The register for identifying the rotation direction of the current rotational speed and the trigger signal register for marking the data write buffer;
[0047] During each synchronous clock cycle, determine whether the first rotational speed pulse exists. If the first rotational speed pulse exists, output the number of first rotational speed pulses and trigger the trigger signal register for writing marked data to the buffer to write data to the buffer;
[0048] Determine whether half of the adjacent pulse clocks of the first rotational speed signal is greater than the delay clocks between the second rotational speed signal and the first rotational speed signal. If it is greater, set the forward rotation flag; otherwise, clear the forward rotation flag;
[0049] When the first rotational speed pulse exists, reset the first rotational speed pulse clocks and the delay clocks between the second rotational speed signal and the first rotational speed signal, and clear the trigger signal register for writing marked data to the buffer;
[0050] If the first rotational speed pulse does not exist, increment the adjacent pulse clocks of the first rotational speed signal by 1;
[0051] Determine whether the second rotational speed pulse exists. If the first rotational speed pulse exists, output the adjacent pulse clocks of the second rotational speed signal, record the delay clocks between the second rotational speed signal and the first rotational speed signal, and reset the number of second rotational speed pulses;
[0052] If the second rotational speed pulse does not exist, increment the adjacent pulse clocks of the second rotational speed signal by 1 and increment the delay clocks between the second rotational speed signal and the first rotational speed signal by 1;
[0053] During each synchronous clock cycle, determine whether the third rotational speed pulse exists. If it exists, increment the number of turns of the third rotational speed signal by 1.
[0054] Preferably, the rotational speed signals are output through the main control chip, including:
[0055] Adopt an RJ45 network interface and output the adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clocks between the second rotational speed signal and the first rotational speed signal through the UDP network protocol;
[0056] Use port 1200 to transmit control signals, use port 1201 to transmit AD data streams, and use port 1202 to transmit rotational speed data streams;
[0057] Cache the data of the three ports respectively. When data needs to be sent, set the send request flag and sequentially judge the request flag through the network arbitration register and perform data sending operations;
[0058] Among them, a rotation speed buffer is set in the main control chip. In each synchronous clock cycle, the trigger signal register status of the mark data written into the buffer is read. When the register status is 1, the process of writing into the buffer is entered, and four groups of rotation speed-related data are written in sequence, including: the first rotation speed signal, the number of adjacent pulse clocks of the second rotation speed signal, the number of turns of the third rotation speed signal, and the delay clock number between the second rotation speed signal and the first rotation speed signal.
[0059] Preferably, the AD data stream communicates through port 1201. Each data packet reserves 2 bytes of a fixed segment for sending rotation speed data, only the number of adjacent pulse clocks of the first rotation speed signal;
[0060] The AD data stream triggers a transmission every 1440 bytes. The transmission period is related to the sampling rate, number of bits, and number of channels of the AD. The transmission interval is 2 ms, and the rotation speed data is uploaded synchronously with the AD data stream;
[0061] The rotation speed data is represented by 16 bits. The rotation speed pulse is expressed in exponential form with base 2. The data valid bit is 12 bits, and the exponent bit is 4 bits. When the transmission direction is involved, 1 bit of the data valid bit is occupied.
[0062] In a second aspect, in some embodiments, a rotation speed integrated circuit for data acquisition is further proposed, which is applicable to the method described in the above embodiments, and includes an input interface, a main control chip, a conditioning circuit, a power supply circuit, and a protection circuit;
[0063] The conditioning circuit includes a first resistor, a second resistor, and a third resistor:
[0064] The power supply circuit includes a fourth resistor, a fifth resistor, and a sixth resistor;
[0065] The protection circuit includes a first diode, a second diode, and a third diode;
[0066] The three pins of the input interface are respectively electrically connected to the three IO pins of the main control chip through the first resistor, the second resistor, and the third resistor;
[0067] The three IO pins of the main control chip are respectively grounded through the first diode, the second diode, and the third diode;
[0068] The ends of the first diode, the second diode, and the third diode far from the ground are respectively connected to the seventh resistor through the fourth resistor, the fifth resistor, and the sixth resistor. The other end of the seventh resistor is connected to the input interface through the fourth diode;
[0069] One end of the seventh resistor is respectively connected to the 12V power supply and a capacitor, and the other end of the capacitor is grounded.
[0070] Preferably, the main control chip obtains the rotational speed pulse signal, including: the front-end rotational speed sensor is connected to the IO pin of the main control chip through the sensor signal conditioning circuit, and the main control chip obtains the level acquisition through the IO pin to determine whether there is a rotational speed signal. If there is, the rotational speed pulse signal is obtained for calculating the rotational speed data.
[0071] Beneficial effects:
[0072] High-speed synchronous measurement of multiple rotational speeds meets the measurement requirements of dynamic torque, rotation direction, and fault location;
[0073] Through the specially designed high sampling rate and real-time calculation mechanism, the present invention can analyze the rotational speed of rotating machinery with higher precision, avoiding the problem of low measurement accuracy caused by insufficient sampling rate in the prior art;
[0074] Utilize the UDP protocol and multiple ports to achieve synchronous transmission of rotational speed data and AD data stream, ensuring the real-time performance and synchronization of different data streams, and meeting the requirements of complex rotating machinery performance evaluation and fault diagnosis;
[0075] Buffering and efficient processing of multiple rotational speed data. The independent rotational speed buffer design ensures the integrity and efficient processing of rotational speed data, while reducing the communication load and improving the stability and reliability of the system;
[0076] Anti-shake processing of rotational speed signal. The anti-shake program effectively eliminates the signal fluctuations caused by environmental interference or sensor abnormalities, ensuring the accuracy of the measurement signal and avoiding misjudgment of pulse output. Brief description of the drawings
[0077] Figure 1 It is a schematic diagram of the method framework provided by the present invention;
[0078] Figure 2 It is a schematic diagram of the overall rotational speed pulse acquisition and sending process provided by the present invention;
[0079] Figure 3 It is a schematic diagram of the circuit provided by the present invention;
[0080] Figure 4 It is a schematic diagram of the basic clock source provided by the present invention;
[0081] Figure 5 It is a schematic diagram of the rotational speed acquisition process provided by the present invention;
[0082] Figure 6 It is a schematic diagram of the process when judging the forward and reverse rotation provided by the present invention;
[0083] Figure 7 It is a schematic diagram of the internal rotational speed buffer of the main control chip provided by the present invention;
[0084] Figure 8 Provide a schematic diagram of rotational speed fluctuation for the present invention;
[0085] Figure 9 Provide a schematic diagram of torsional vibration measurement for the present invention;
[0086] Figure 10 Provide a schematic diagram of rotational speed output synchronized with the AD data stream for the present invention. Specific embodiments
[0087] To make the technical solution of the present invention clearer, the following further describes the present invention in detail with reference to specific embodiments in the accompanying drawings.
[0088] Embodiment 1
[0089] To make the purpose, technical solution and advantages of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention. Unless otherwise defined, the technical terms or scientific terms used herein shall have the ordinary meaning as understood by those of ordinary skill in the art in the field to which the present invention belongs. The words such as "including" used herein mean that the elements or objects appearing before the word cover the elements or objects listed after the word and their equivalents, without excluding other elements or objects.
[0090] Regarding the problems existing in the prior art, such as Figure 1 and Figure 2 shown, a rotational speed integration method for data acquisition includes the steps of:
[0091] The main control chip acquires rotational speed pulse signals, where the rotational speed pulse signals include a first rotational speed signal and a second rotational speed signal at different positions of the rotating machinery, and a third rotational speed signal configured as a reference position at one end of the rotating machinery linkage component;
[0092] The main control chip configures five registers to respectively identify the valid rotational speed pulses of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal to obtain rotational speed data signals. Among them, the rotational speed data includes the number of pulse clocks between adjacent pulses of the first rotational speed signal and the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal;
[0093] Perform dynamic torque calculation and forward / reverse rotation judgment through the rotational speed data signals;
[0094] Output the rotational speed data signals through the main control chip.
[0095] In some specific embodiments, the main control chip acquires the rotational speed pulse signal, including: when the front-end rotational speed sensor is connected to the IO pin of the main control chip through the sensor signal conditioning circuit, the main control chip acquires the level acquisition through the IO pin, determines whether there is a rotational speed signal, and if so, acquires the rotational speed pulse signal for calculating the rotational speed data.
[0096] In some specific embodiments, in combination with Figure 2 , in combination with the sensor signal conditioning, the front-end rotational speed sensor conditions its signal through the signal conditioning circuit and then connects it to the I / O pin of the main control chip. The purpose of this step is to ensure that the sensor signal is adapted and recognized by the main control chip;
[0097] Rotational speed pulse confirmation and real-time calculation: The main control chip confirms whether there is a rotational speed pulse signal by acquiring the levels of multiple I / O pins. If a rotational speed pulse is confirmed, the main control chip calculates the rotational speed data in real time;
[0098] Data caching and synchronization: The calculated rotational speed data is cached, and at the same time, the real-time data of rotational speed A is transmitted to the conventional AD data acquisition module, which can ensure the synchronization of the rotational speed data and the AD data, facilitating subsequent data processing and analysis;
[0099] Data sending: When the amount of data in the cache reaches the preset trigger value, the rotational speed port and the conventional AD port independently send data sending requests. At this time, the network communication module receives these requests and performs sending arbitration, and finally completes the data sending.
[0100] In some specific embodiments, in combination with Figure 4 , the FPGA chip (main control chip) uses an external active crystal oscillator to provide a 50 MHz basic clock source and generates two clocks through an internal PLL (phase-locked loop) frequency division module
[0101] The specific working process is as follows:
[0102] External clock input: The external active crystal oscillator provides a 50 MHz basic clock signal (inclk0), which provides the basic frequency for the internal clock source of the FPGA;
[0103] PLL frequency division module: Through the internal PLL frequency division module, the 50 MHz basic clock is divided into two clocks with different frequencies:
[0104] 25 MHz clock (c0): This clock signal is used as the sampling clock for rotational speed acquisition. This frequency is used for high-speed sampling of rotational speed signals to support high-precision dynamic measurement;
[0105] 16.777216 MHz clock (c1): This clock signal is used as the 192 kHz sampling clock for conventional AD sampling. This frequency is suitable for conventional data acquisition, ensuring sufficient sampling accuracy and synchronization.
[0106] Clock output: The divided-frequency outputs (c0 and c1) of the PLL module provide two clock frequencies suitable for rotational speed acquisition and AD sampling respectively, ensuring the synchronization and accuracy of different acquisition tasks.
[0107] This clock distribution method ensures that the FPGA can simultaneously process high-speed rotational speed signal acquisition and conventional AD data acquisition, while maintaining the accuracy and synchronization of each data acquisition, making it suitable for use in complex measurement and analysis systems.
[0108] In some specific embodiments, in combination with Figure 5 , five registers are configured through the main control chip to respectively identify the valid rotational speed pulses of the first, second, and third rotational speed signals to obtain rotational speed data signals, including:
[0109] Use the current input status buffer to store the current level status of the rotational speed signal in real time.
[0110] Use the input status buffer time register to record the holding time after the change of the rotational speed signal level to judge the stability of the signal change.
[0111] Use the current clock status register to store the stable signal status after interference filtering.
[0112] Use the previous clock status register to save the rotational speed signal status of the previous clock cycle for comparison with the current signal.
[0113] Use the pulse output valid register to indicate whether there is a valid rotational speed pulse signal. When the signal change is valid, it is set to 1.
[0114] Specifically, the current input status buffer (speed_temp) stores the current level status of the rotational speed signal in real time. It is used to monitor whether the signal changes. In each clock cycle, the level status of the rotational speed signal is read and speed_temp is updated, providing a reference for subsequent judgment of whether the signal has changed.
[0115] The input status buffer time register (speed_keep) records the holding time after the change of the rotational speed signal level to judge the stability of the signal change. If speed_temp (current input status) is different from the previous status (i.e., the signal changes), the speed_keep timer is cleared; if there is no change, speed_keep is incremented. If speed_keep reaches the preset time threshold, it indicates that the signal is stable and the signal change can be confirmed as valid.
[0116] The current clock status register (speed_now) stores the stable signal status after interference filtering; when the signal passes the verification for the speed_keep time, speed_now is updated to the value of speed_temp, indicating that the current signal is stable.
[0117] The previous clock status register (speed_before) saves the rotational speed signal status of the previous clock cycle and is used in conjunction with speed_now. speed_before saves the signal status of the previous cycle for comparison with the current cycle's status to determine whether the signal has changed effectively (such as rising edge or falling edge).
[0118] The pulse output valid register (speed_pulse) indicates whether there is a valid rotational speed pulse signal. When the signal status changes effectively (for example, changes from low to high level), speed_pulse is set to 1, indicating that a valid rotational speed pulse signal is detected; otherwise, speed_pulse is 0, indicating no valid pulse signal.
[0119] In some specific embodiments, in combination with Figure 5 , the main control chip configures five registers to respectively identify the valid rotational speed pulses of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal to obtain the rotational speed data signal, including using the 25 MHz clock output by the pll frequency division module as the synchronization beat to drive multiple registers in real time. The processing flow of each clock beat is as follows:
[0120] Read the logic level of the rotational speed input interface, compare this level with the value in the current input status buffer register, and at the same time update the current input status buffer to the level value of the current input interface;
[0121] If the comparison result is different, indicating that the current rotational speed input signal level has changed, clear the input status buffer time register. If the comparison result is the same, judge whether the value of the input status buffer time register is greater than the predetermined value;
[0122] If the input status buffer time register is less than the predetermined value, increment the input status buffer time register by 1. If the input status buffer time register reaches the predetermined value, confirm the level jump of the rotational speed input signal, update the current clock status register to the value of the current input status buffer, and clear the input status buffer time register;
[0123] After the current clock status register is updated, check whether the current clock status register is 1 and whether the previous clock status register is 0. If it is determined that there is a rising edge change, set the pulse output enable register to 1; otherwise, clear the pulse output enable register, update the previous clock status register with the value of the current clock status register, and exit the current clock processing.
[0124] Specifically:
[0125] 1. Read the logic level of the rotation speed input interface:
[0126] Read the current level status from the rotation speed input interface and compare it with the value in speed_temp (the current input status buffer).
[0127] At the same time, update speed_temp with the currently read level value to prepare for the next comparison.
[0128] 2. Level change detection:
[0129] If the current level is different from the value in speed_temp, it means that the level of the rotation speed input interface has changed. In this case, perform the following operations:
[0130] Clear speed_keep, that is, reset the signal hold time counter to prepare for recalculating the signal stability time.
[0131] 3. Stability judgment:
[0132] If the current level is the same as the value in speed_temp, it means that the level has not changed, and enter the stage of judging whether the signal is stable:
[0133] Judge whether the value of speed_keep is greater than the predetermined value. If the value of speed_keep is less than the predetermined value, it means that the signal change is not stable enough and needs to continue timing, and speed_keep is incremented by 1.
[0134] If the value of speed_keep reaches the predetermined value, it means that the signal change has become stable, and confirm that the level change is valid:
[0135] Update the value of speed_now with the value of speed_temp, that is, update it to the stable level status.
[0136] Clear speed_keep to prepare for the next level change.
[0137] 4. Predetermined value and rotation speed range:
[0138] The preset value determines the duration of signal stability judgment. The larger the preset value, the stronger the anti-interference ability, but it will cause the maximum measurable speed range to shift downward. For example:
[0139] If the preset value is set to 1, it means that a level change requires 2 clock cycles to be confirmed (a complete cycle requires 4 clocks). Based on a 25 MHz synchronous clock, the maximum speed is calculated as:
[0140] Maximum speed = 250000004 × 60 = 375,000,000 rpm;
[0141] If the preset value is doubled, the maximum speed will be halved.
[0142] 5. Rising edge detection and pulse validity confirmation:
[0143] When speed_now is updated, determine whether it is a rising edge change:
[0144] If the value of speed_now is 1 and the value of speed_before is 0, it means that the signal has a rising edge change, confirming a valid pulse:
[0145] Setting speed_pulse to 1 indicates that the current speed input signal is a valid pulse signal.
[0146] If the condition is not met (ie, there is no rising edge change), speed_pulse is cleared to zero, indicating that there is no valid pulse.
[0147] 6. Update status and exit processing:
[0148] Update speed_before to the value of speed_now so that comparison can be performed on the next clock cycle.
[0149] Exit the current clock processing flow and wait for the signal detection of the next cycle;
[0150] Therefore, the system determines whether the signal has changed by comparing speed_temp with the current input level. Using speed_keep as a time counter, the level change is considered valid only when the signal changes steadily (i.e., the hold time reaches a predetermined value). Speed_now is compared with speed_before to determine whether the signal has experienced a rising edge change, thereby confirming a valid pulse signal. If a valid rising edge change occurs, speed_pulse is set to 1, indicating that the current signal is a valid pulse.
[0151] When using Hall, photoelectric and other rotational speed sensors, due to the unevenness or roughness of the surface of the measured object, or the interference of the system power supply, etc., there will be abnormal fluctuations in the level of the rotational speed interface, resulting in misjudgment of a pulse output. The abnormal fluctuations are often very short-lived. Through anti-shake program processing, the abnormal fluctuations can be avoided and the real rotational speed pulses can be confirmed.
[0152] In some specific embodiments, dynamic torque calculation and forward / reverse rotation judgment are performed through rotational speed data signals, including:
[0153] Calculating the rotational speeds speed_a_out and speed_b_out of the first rotational speed signal and the second rotational speed signal through the number of adjacent pulse clocks of the first rotational speed signal and the second rotational speed signal, including:
[0154] ;
[0155] where rmp is the rotational speed, H is the clock frequency, and t is the number of adjacent pulse clocks;
[0156] The number of turns speed_c_num of the third rotational speed signal is used in combination with the first rotational speed signal and the second rotational speed signal as the reference pulse point of the encoder to align the pulses of the first rotational speed signal and the second rotational speed signal. Among them, each time the number of turns of the third rotational speed signal changes, the pulses of the first rotational speed signal and the second rotational speed signal can be aligned with reference to the change of the third rotational speed signal.
[0157] Specifically, the clock frequency H can be 25 MHz, and it is converted to rotational speed (revolutions per minute) by dividing by the number of clocks and multiplying by 60. The formula is as follows:
[0158] ;
[0159] The third rotational speed signal is used as a reference position for positioning analysis. It records the change in the number of turns of the rotating machinery and is used in combination with the first rotational speed signal and the second rotational speed signal as a positioning reference;
[0160] For example, when the third rotational speed signal has 1 pulse per revolution, the first rotational speed signal and the second rotational speed signal may have thousands of pulses, which makes the third rotational speed signal the reference pulse point for positioning the combination of the first rotational speed signal and the second rotational speed signal. Each time the number of turns of the third rotational speed signal changes, it will provide precise positioning for the pulses of the combination of the first rotational speed signal and the second rotational speed signal, thus achieving more accurate analysis.
[0161] In some specific embodiments, dynamic torque calculation is performed based on the number of adjacent pulse clocks speed_a_out and speed_b_out of the first rotational speed signal and the second rotational speed signal, the number of turns speed_c_num of the third rotational speed signal, and the number of delay clocks speed_b_delay_out between the second rotational speed signal and the first rotational speed signal (recording the number of delay clocks of rotational speed B relative to rotational speed A), including:
[0162] Calculate the rotation angle, and the formula is as follows:
[0163] ;
[0164] where NUM A is the number of adjacent pulse clocks of the first rotational speed signal, and NUM1 and NUM2 are respectively the number of delay clocks between the second rotational speed signal and the first rotational speed signal under no-load and load conditions;
[0165] The formula for calculating the dynamic torque is as follows:
[0166] ;
[0167] where T is the dynamic torque, G is the shear modulus of the shaft material, and the shear modulus is the deformation ability of the material under shear stress, and J is the polar moment of inertia of the shaft.
[0168] Specifically, the number of delay clocks between the second rotational speed signal and the first rotational speed signal records the delay of the second rotational speed signal relative to the first rotational speed signal. By measuring the delay between the second rotational speed signal and the first rotational speed signal on the rotating shaft, the relative delay between the second rotational speed signal and the first rotational speed signal can be obtained, thereby judging the torsional state of the rotating shaft;
[0169] When measuring the torque, the first rotational speed signal and the second rotational speed signal are pasted at a given interval L on the rotating machine, with 1 pulse per revolution. Under no-load conditions, record the number of delay clocks NUM1 of the first rotational speed signal and the second rotational speed signal,
[0170] Under load conditions, record the number of delay clocks NUM2 of the first rotational speed signal and the second rotational speed signal. Then, the change in the number of delay clocks under load can be calculated. Combining with the number of adjacent pulse clocks NUM_A of the first rotational speed signal, the torsional angle of the rotating shaft can be calculated;
[0171] Under no-load conditions: Record the number of delay clocks NUM1 between the first rotational speed signal and the second rotational speed signal;
[0172] Under load conditions: Record the number of delay clocks NUM2 between the first rotational speed signal and the second rotational speed signal;
[0173] By calculating the change in the extended clock count (NUM1 - NUM2), the relative change between the second rotational speed signal and the first rotational speed signal under the load condition can be obtained;
[0174] T: Represents the dynamic torque, and the unit is usually Newton - meter (Nm);
[0175] G: The shear modulus of the shaft material, which represents the material's resistance to deformation during torsion;
[0176] J: The polar moment of inertia of the shaft, which depends on the geometric shape of the shaft. For example, for a solid circular shaft, the calculation formula for the polar moment of inertia is:
[0177] ;
[0178] where d is the diameter of the shaft;
[0179] L: The spacing for rotational speed extraction, which refers to the distance between the points where the rotational speed signals are measured. Torque T is a key physical quantity in rotating machinery, and it represents the product of force and the lever arm.
[0180] In some specific embodiments, in combination with Figure 6 , positive and negative rotation judgment is performed through the adjacent pulse clock counts speed_a_clk and speed_b_clk of the first rotational speed signal and the second rotational speed signal, the number of turns speed_c_num of the third rotational speed signal, and the extended clock count speed_b_delay_clk between the second rotational speed signal and the first rotational speed signal, including:
[0181] If it is determined that half of the adjacent pulse clock count of the first rotational speed signal speed_a_clk is greater than the extended clock count speed_b_delay_clk between the second rotational speed signal and the first rotational speed signal, it is a positive rotation;
[0182] If it is determined that half of the adjacent pulse clock count of the first rotational speed signal speed_a_clk is less than the extended clock count speed_b_delay_clk between the second rotational speed signal and the first rotational speed signal, it is a reverse rotation.
[0183] In some specific embodiments, in combination with Figure 6 , the process of the main control chip for positive and negative rotation judgment is as follows:
[0184] The main control chip configures the rotational speed pulse registers speed_a_pulse, speed_b_pulse, and speed_c_pulse of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal respectively;
[0185] Adjacent pulse clock number registers speed_a_clk and speed_b_clk for the first rotation speed signal and the second rotation speed signal;
[0186] Number of turns speed_c_num of the third rotation speed signal, and adjacent pulse clock number register speed_b_delay_clk between the second rotation speed signal and the first rotation speed signal;
[0187] Rotation direction register speed_direction indicating the current rotation speed and trigger signal register wr_fifo_flag marking data writing to the buffer;
[0188] In each synchronization clock cycle, determine whether the first rotation speed pulse exists. If the first rotation speed pulse exists, output the number of first rotation speed pulses and trigger the trigger signal register for marking data writing to the buffer to write data to the buffer;
[0189] Determine whether half of the adjacent pulse clock number of the first rotation speed signal is greater than the delay clock number between the second rotation speed signal and the first rotation speed signal. If it is greater, set the forward rotation flag; otherwise, clear the forward rotation flag;
[0190] When the first rotation speed pulse exists, reset the adjacent pulse clock number of the first rotation speed pulse and the delay clock number between the second rotation speed signal and the first rotation speed signal, and clear the trigger signal register for marking data writing to the buffer;
[0191] If the first rotation speed pulse does not exist, increment the adjacent pulse clock number of the first rotation speed signal by 1;
[0192] Determine whether the second rotation speed pulse exists. If the first rotation speed pulse exists, output the adjacent pulse clock number of the second rotation speed signal, record the delay clock number between the second rotation speed signal and the first rotation speed signal, and reset the number of second rotation speed pulses;
[0193] If the second rotation speed pulse does not exist, increment the adjacent pulse clock number of the second rotation speed signal by 1 and increment the delay clock number between the second rotation speed signal and the first rotation speed signal by 1;
[0194] In each synchronization clock cycle, determine whether the third rotation speed pulse exists. If it exists, increment the number of turns of the third rotation speed signal by 1.
[0195] Specifically,
[0196] Detection and processing of the first rotation speed pulse:
[0197] Determine whether the first rotation speed pulse exists:
[0198] In each synchronous clock cycle, first check whether speed_a_pulse (the first rotational speed pulse) is 1, indicating the existence of the first rotational speed pulse;
[0199] If the first rotational speed pulse exists, perform the following operations:
[0200] Output the clock number of the first rotational speed pulse: Output the clock number of the first rotational speed pulse (i.e., speed_a_clk);
[0201] Set the data write buffer flag: Set wr_fifo_flag to 1 to trigger data writing to the buffer;
[0202] Forward and reverse rotation judgment:
[0203] Judge whether half of the clock number of the first rotational speed pulse is greater than the delay clock number between the second rotational speed pulse and the first rotational speed pulse; if the condition is true, set the forward rotation flag (speed_direction = 1).
[0204] If the condition is not true, clear the forward rotation flag (speed_direction = 0);
[0205] Reset operation: Reset the clock number of the first rotational speed pulse speed_a_clk and the delay clock number between the second rotational speed pulse and the first rotational speed pulse speed_b_delay_clk, and clear wr_fifo_flag;
[0206] The first rotational speed pulse does not exist:
[0207] If the first rotational speed pulse does not exist, increment the clock number of the first rotational speed pulse speed_a_clk by 1, indicating waiting for the arrival of the next pulse;
[0208] Second rotational speed pulse detection and processing:
[0209] Judge whether the second rotational speed pulse exists:
[0210] If the first rotational speed pulse exists, check whether the second rotational speed pulse exists;
[0211] If the second rotational speed pulse exists:
[0212] Output the clock number of the second rotational speed pulse: Output the clock number of the second rotational speed pulse (i.e., speed_b_clk);
[0213] Record the delay: Record the clock delay number between the second rotational speed pulse and the first rotational speed pulse (speed_b_delay_clk);
[0214] Reset the number of second rotation pulses' clocks: Reset speed_b_clk to prepare for the pulses in the next cycle;
[0215] If the second rotation pulse does not exist:
[0216] Increment operation: Increment the number of second rotation pulses' clocks speed_b_clk by 1, and at the same time increase the delay clock number speed_b_delay_clk between the second rotation pulse and the first rotation pulse;
[0217] Third rotation pulse detection and processing:
[0218] Determine whether the third rotation pulse exists:
[0219] Within each synchronous clock cycle, check whether the third rotation pulse exists;
[0220] If the third rotation pulse exists, increment the number of third rotation pulses speed_c_num by 1;
[0221] Accumulation and overflow: The number of third rotation pulses is not cleared, but continuously accumulated. If it exceeds the predetermined value, it will be automatically cleared and start counting again;
[0222] Process overview:
[0223] Within each synchronous clock cycle, the system detects the signals of the first rotation pulse, the second rotation pulse, and the third rotation pulse, and processes them respectively;
[0224] For each rotation signal, the system calculates the number of adjacent pulse clocks, the delay, and the forward and reverse rotation judgment to ensure accurate synchronization and perform necessary data caching;
[0225] If the first rotation pulse and the second rotation pulse exist, the system will perform forward and reverse rotation judgment and trigger the data writing operation at the same time;
[0226] The third rotation pulse is used for counting. By accumulating its pulses, a reference for positioning analysis is provided;
[0227] Overall function:
[0228] Through the operations within the synchronous clock cycle, ensure the accurate synchronization of the rotation signals and store the results in the buffer,
[0229] Forward and reverse rotation judgment. By judging the relative delay between the first rotation pulse and the second rotation pulse, the rotation direction can be determined to assist the system in dynamic analysis.
[0230] Third rotational speed pulse positioning. The third rotational speed pulse serves as a reference signal to assist in precisely positioning and analyzing the relationship between the first and second rotational speed pulses, providing support for advanced analyses such as torque calculation.
[0231] In some specific embodiments, in combination with Figure 7 , the main control chip outputs rotational speed signals, including:
[0232] Adopt an RJ45 network interface and output the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal through the UDP network protocol;
[0233] Use port 1200 to transmit control signals, use port 1201 to transmit AD data streams, and use port 1202 to transmit rotational speed data streams;
[0234] Cache the data of the three ports respectively. When data needs to be sent, set the send request flag, and sequentially judge the request flag through the network arbitration register and perform data sending operations;
[0235] Among them, set up a rotational speed buffer area in the main control chip. In each synchronous clock cycle, read the trigger signal register status of the marker data written into the buffer area. When the register status is 1, enter the write buffer process and sequentially write 4 groups of rotational speed-related data, including: the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal.
[0236] In some specific embodiments, the AD data stream communicates through port 1201. Each data packet reserves a fixed segment of 2 bytes for sending rotational speed data, only the number of adjacent pulse clocks of the first rotational speed signal;
[0237] The AD data stream triggers a send every 1440 bytes. The send period is related to the sampling rate, number of bits, and number of channels of the AD. The send interval is 2 ms, and the rotational speed data is uploaded synchronously with the AD data stream;
[0238] The rotational speed data is represented in 16 bits, uses an exponential form with base 2 to express rotational speed pulses, has 12 valid data bits and 4 exponent bits. When indicating the transmission direction, it occupies 1 valid data bit.
[0239] Specifically, the rotational speed output synchronized with the AD data stream:
[0240] AD data stream communication: Use port 1201 to transmit the AD data stream. Each data packet reserves a fixed segment of 2 bytes for sending rotational speed data, and only sends the clock number of the first rotational speed pulse (speed_a_clk, that is, the clock number of the first rotational speed pulse);
[0241] By synchronizing with the AD data stream, it is ensured that the rotational speed data and the AD data can be transmitted within the same cycle, thus enabling synchronous measurement.
[0242] Relationship between the data packet sending period and the AD sampling rate:
[0243] Size of the AD data stream: Sending is triggered every 1440 bytes, which means that 533 data packets need to be sent per second, and the sending interval is approximately 2 ms.
[0244] AD sampling rate: With a sampling rate of 48 kHz, 32-bit data transmission, and dual-channel sampling, 768,000 bytes need to be transmitted per second (48,000 * 32 / 4 * 2 = 768,000).
[0245] Reducing the communication data volume:
[0246] To reduce the communication burden, the rotational speed data is represented using only 16 bits (2 bytes). Although the actual measurement range of the rotational speed may span from a few Hz to hundreds of thousands of Hz and cannot be directly represented by 16-bit data, an exponential form (exponential expression with base 2) is adopted to represent the rotational speed.
[0247] Rotational speed accuracy: The significant bits of the data are 12 bits, and the exponent bits are 4 bits, ensuring a rotational speed accuracy of five ten-thousandths. When the transmission direction is involved, 1 significant bit of the data is occupied, and at this time, the rotational speed transmission accuracy is ten ten-thousandths.
[0248] Output of the rotational speed data stream:
[0249] An independent rotational speed buffer uses the on-chip memory of the FPGA (designed as a dual-port RAM with a width of 16 bits and a depth of 1024) as the rotational speed data buffer to ensure that the data can be efficiently stored and processed without interference.
[0250] Data writing process:
[0251] Within each synchronous clock cycle, check the status of the register wr_fifo_flag. If wr_fifo_flag is 1 (indicating a data write request), then enter the write buffer process.
[0252] The written rotational speed data includes:
[0253] Number of clock cycles between adjacent pulses of the first rotational speed pulse (speed_a_out);
[0254] Number of clock cycles between adjacent pulses of the second rotational speed pulse (speed_b_out);
[0255] Number of revolutions of the third rotational speed pulse (speed_c_num);
[0256] The number of clock cycles of the second rotation speed pulse delayed from the first rotation speed pulse (speed_b_delay_out);
[0257] Real-time calculation of the effective data volume: The system calculates the effective data volume in the rotation speed data buffer in real time. When the effective data volume in the buffer is greater than 600, the rotation speed port send request is set, triggering the network arbitration register to perform arbitration and starting a data read operation.
[0258] Network communication and data sending:
[0259] Data request and arbitration: When the data volume is greater than 600, the system will request data sending by setting the send request flag.
[0260] The network arbitration register will sequentially judge the request flag to ensure the smooth data sending of the rotation speed data, AD data, and control signal. Through the arbitration mechanism, the system can manage the sending of multiple data streams to ensure no conflicts occur.
[0261] Synchronization of rotation speed data: The synchronization of rotation speed data and the AD data stream is achieved through the same sending period. Within each sending period, the number of clock cycles of the first rotation speed pulse (speed_a_clk) is sent to the network synchronously to ensure data synchronization and consistency.
[0262] The number of clock cycles of the first rotation speed pulse (speed_a_clk) is sent synchronously with the AD data stream to ensure the precise synchronization of the rotation speed data and AD data. Data compression and transmission accuracy: By representing the rotation speed data in exponential form, 16-bit data is compressed and stored and transmitted to ensure communication efficiency. An independent rotation speed data buffer is used to manage the data. When the data volume reaches a certain threshold, a data write operation is triggered. The UDP protocol and ports 1200, 1201, and 1202 are used to process the control signal, AD data, and rotation speed data respectively. Through network arbitration, multiple data streams can be sent orderly in the network.
[0263] In some embodiments, the present application proposes a rotation speed integrated circuit for data acquisition, combined with Figure 3 , applicable to the method described in the above embodiments, including an input interface INPUT, a main control chip FPGA, a conditioning circuit, a power supply circuit, and a protection circuit;
[0264] The conditioning circuit includes a first resistor R14, a second resistor R15, and a third resistor R16:
[0265] The power supply circuit includes a fourth resistor R17, a fifth resistor R18, and a sixth resistor R19;
[0266] The protection circuit includes a first diode D1, a second diode D2, and a third diode D3;
[0267] The three pins of the input interface INPUT are electrically connected to three IO pins of the main control chip FPGA through a first resistor R14, a second resistor R15, and a third resistor R16 respectively;
[0268] The three IO pins of the main control chip FPGA are grounded through a first diode D1, a second diode D2, and a third diode D3 respectively;
[0269] The ends of the first diode D1, the second diode D2, and the third diode D3 far from the ground are connected to a seventh resistor R20 through a fourth resistor R17, a fifth resistor R18, and a sixth resistor R19 respectively, and the other end of the seventh resistor R20 is connected to the input interface INPUT through a fourth diode V5;
[0270] One end of the seventh resistor R20 is connected to a 12V power supply and a capacitor C181 respectively, and the other end of the capacitor C181 is grounded;
[0271] Port 5, port 6, and port 7 of the input interface INPUT are connected to a first rotational speed pulse signal (SPEED A), a second rotational speed pulse signal (SPEED B), and a third rotational speed pulse signal (SPEED C) respectively.
[0272] In some specific embodiments, combined with Figure 8 It is a rotational speed fluctuation diagram during measurement.
[0273] In some specific embodiments, combined with Figure 9 It is a torsional vibration measurement diagram during measurement, with the abscissa being time, the ordinate being the rotational speed order, and the color representing the torsional vibration amplitude.
[0274] In some specific embodiments, combined with Figure 10 It is a synchronous order analysis diagram of the rotational speed and vibration data in the AD data stream packet using port 1201 during measurement.
[0275] As mentioned above, it is only the specific implementation manner of the embodiments of the present invention, but the protection scope of the embodiments of the present invention is not limited thereto. Any changes or substitutions within the technical scope disclosed in the embodiments of the present invention should be covered by the protection scope of the embodiments of the present invention. Therefore, the protection scope of the embodiments of the present invention should be subject to the protection scope of the claims.
Claims
1. A rotational speed integration method for data acquisition, characterized in that Including the steps: The main control chip obtains the rotational speed pulse signal, where the rotational speed pulse signal includes a first rotational speed signal and a second rotational speed signal at different positions of the rotating machinery, and a third rotational speed signal configured as a reference position at one end of the linkage component of the rotating machinery; Five registers are configured by the main control chip to respectively identify the effective rotational speed pulses of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal to obtain the rotational speed data signal. Among them, the rotational speed data signal includes the number of adjacent pulse clocks of the first rotational speed signal and the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal, including: Use the current input status buffer to store the current level status of the rotational speed signal in real time; Use the input status buffer time register to record the holding time after the change of the rotational speed signal level to judge the stability of the signal change; Use the current clock status register to store the stable signal status after interference filtering; Use the previous clock status register to save the rotational speed signal status of the previous clock cycle for comparison with the current signal; Use the pulse output valid register to indicate whether there is an effective rotational speed pulse signal. When the signal change is effective, set it to 1; Perform dynamic torque calculation and forward / reverse rotation judgment through the rotational speed data signal; Output the rotational speed data signal through the main control chip.
2. The rotational speed integration method of a data acquisition device according to claim 1, characterized in that, Five registers are configured by the main control chip to respectively identify the effective rotational speed pulses of the first rotational speed signal, the second rotational speed signal, and the third rotational speed signal to obtain the rotational speed data signal, including using the 25MHz clock output by the pll frequency division module as the synchronization beat to drive multiple registers in real time. The processing flow of each clock beat is as follows: Read the logic level of the rotational speed input interface, compare the level with the value in the current input status buffer register, and update the current input status buffer to the level value of the current input interface at the same time; If the comparison result is different, indicating that the current rotational speed input signal level has changed, clear the input status buffer time register. If the comparison result is the same, judge whether the value of the input status buffer time register is greater than the predetermined value; If the input status buffer time register is less than the predetermined value, add 1 to the input status buffer time register. If the input status buffer time register reaches the predetermined value, confirm the level jump of the rotational speed input signal, update the current clock status register to the value of the current input status buffer, and clear the input status buffer time register; After the current clock status register is updated, judge whether the current clock status register is 1 and whether the previous clock status register is 0. If it is judged that there is a rising edge change, set the pulse output valid register to 1, otherwise clear the pulse output valid register, update the previous clock status register to the value of the current clock status register, and exit the current clock processing.
3. The rotational speed integration method of data acquisition according to claim 2, characterized in that Perform dynamic torque calculation and forward / reverse rotation judgment through the rotational speed data signal, including: Calculate the rotational speeds of the first rotational speed signal and the second rotational speed signal through the number of adjacent pulse clocks of the first rotational speed signal and the second rotational speed signal, including: ; Among them, rmp is the rotational speed, H is the clock frequency, and t is the number of adjacent pulse clocks; The number of turns of the third rotational speed signal is used in combination with the first rotational speed signal and the second rotational speed signal as the reference pulse point of the encoder to align the pulses of the first rotational speed signal and the second rotational speed signal. Among them, each time the number of turns of the third rotational speed signal changes, the pulses of the first rotational speed signal and the second rotational speed signal can be aligned with reference to the change of the third rotational speed signal.
4. A rotational speed integration method for data acquisition according to claim 1, characterized in that Dynamic torque calculation is performed through the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal, including: Calculate the rotation angle, and the formula is as follows: ; where NUM A is the number of adjacent pulse clocks of the first rotational speed signal, and NUM1 and NUM2 are the number of delay clocks between the second rotational speed signal and the first rotational speed signal under no-load and load conditions, respectively; The formula for calculating the dynamic torque is as follows: ; Among them, T is the dynamic torque, G is the shear modulus of the shaft material, and the shear modulus is the deformation ability of the material under shear stress, J is the polar moment of inertia of the shaft, and L is the rotational speed extraction interval.
5. A rotational speed integration method for data acquisition according to claim 1, characterized in that Forward and reverse rotation judgment is performed through the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal, including: If it is judged that half of the number of adjacent pulse clocks of the first rotational speed signal is greater than the delay clock number between the second rotational speed signal and the first rotational speed signal, it is a forward rotation; If it is judged that half of the number of adjacent pulse clocks of the first rotational speed signal is less than the delay clock number between the second rotational speed signal and the first rotational speed signal, it is a reverse rotation.
6. A rotational speed integration method for data acquisition according to claim 5, characterized in that, The process of the main control chip for forward and reverse rotation judgment is as follows: In each synchronous clock cycle, judge whether the first rotational speed pulse exists. If the first rotational speed pulse exists, output the number of first rotational speed pulses, and trigger the trigger signal register for writing marked data to the buffer to write data to the buffer; Judge whether half of the number of adjacent pulse clocks of the first rotational speed signal is greater than the delay clock number between the second rotational speed signal and the first rotational speed signal. If it is greater, set the forward rotation flag, otherwise clear the forward rotation flag; When the first rotational speed pulse exists, reset the number of first rotational speed pulse clocks and the delay clock number between the second rotational speed signal and the first rotational speed signal, and clear the trigger signal register for writing marked data to the buffer; If the first rotational speed pulse does not exist, add 1 to the number of adjacent pulse clocks of the first rotational speed signal; Judge whether the second rotational speed pulse exists. If the first rotational speed pulse exists, output the number of adjacent pulse clocks of the second rotational speed signal, record the delay clock number between the second rotational speed signal and the first rotational speed signal, and reset the number of second rotational speed pulses; If the second rotational speed pulse does not exist, add 1 to the number of adjacent pulse clocks of the second rotational speed signal and add 1 to the delay clock number between the second rotational speed signal and the first rotational speed signal; In each synchronous clock cycle, judge whether the third rotational speed pulse exists. If it exists, add 1 to the number of turns of the third rotational speed signal.
7. A rotational speed integration method for data acquisition according to claim 1, characterized in that Output the rotational speed signal through the main control chip, including: Adopt an RJ45 network interface and output the number of adjacent pulse clocks of the first rotational speed signal, the second rotational speed signal, the number of turns of the third rotational speed signal, and the delay clock number between the second rotational speed signal and the first rotational speed signal through the UDP network protocol; Use port 1200 to transmit control signals, use port 1201 to transmit AD data streams, and use port 1202 to transmit rotational speed data streams; Cache the data of the three ports respectively. When data needs to be sent, set the send request flag, and sequentially judge the request flag through the network arbitration register and perform the data sending operation; Among them, a rotation speed buffer is set in the main control chip. In each synchronous clock cycle, read the trigger signal register status of the marker data written into the buffer. When the register status is 1, enter the write buffer process, and sequentially write 4 groups of rotation speed related data, including: the first rotation speed signal, the number of adjacent pulse clocks of the second rotation speed signal, the number of turns of the third rotation speed signal, and the delay clock number between the second rotation speed signal and the first rotation speed signal.
8. A rotation speed integration method for data acquisition according to claim 7, characterized in that The AD data stream communicates through port 1201. Each data packet reserves a fixed segment of 2 bytes for sending rotation speed data, only the number of adjacent pulse clocks of the first rotation speed signal; The AD data stream triggers a send every 1440 bytes. The send period is related to the sampling rate, number of bits and number of channels of the AD. The send interval is 2 ms, and the rotation speed data is uploaded synchronously with the AD data stream; The rotation speed data is represented by 16 bits, and the rotation speed pulse is expressed in exponential form with base 2. The data valid bit is 12 bits, and the exponent bit is 4 bits. When the transmission direction is involved, it occupies 1 bit of the data valid bit.
9. A rotational speed integrated circuit for data acquisition, applicable to the method according to any one of claims 1-8, characterized in that It includes an input interface, a main control chip, a conditioning circuit, a power supply circuit and a protection circuit; The conditioning circuit includes a first resistor, a second resistor and a third resistor: The power supply circuit includes a fourth resistor, a fifth resistor and a sixth resistor; The protection circuit includes a first diode, a second diode and a third diode; The three pins of the input interface are respectively electrically connected to the three IO pins of the main control chip through the first resistor, the second resistor and the third resistor; The three IO pins of the main control chip are respectively grounded through the first diode, the second diode and the third diode; The ends of the first diode, the second diode and the third diode far from the ground are respectively connected to the seventh resistor through the fourth resistor, the fifth resistor and the sixth resistor, and the other end of the seventh resistor is connected to the input interface through the fourth diode; One end of the seventh resistor is respectively connected to the 12V power supply and a capacitor, and the other end of the capacitor is grounded.
Citation Information
Patent Citations
High-precision pulse time interval measurement circuit
CN102073268A
EQEP module and motor position and speed measuring system and method
CN115143906A