Share this

Design of a projectile velocity measurement system based on a USB interface

2026-04-06 06:13:38 · · #1
Introduction Currently, the main methods for measuring muzzle velocity include laser measurement, infrared measurement, and coil target measurement. Due to the light pollution caused by propellant gases, both laser and infrared measurement methods are affected, and the powerful mechanical impact of artillery can also affect measurement performance. Furthermore, field operations require portable testing systems. This paper describes a modification from discrete logic devices to CPLD for measuring muzzle velocity, improving the integration of the measurement system. The transmission interface uses the currently popular high-speed serial data transmission interface, USB 2.0. This interface is convenient to operate and fast, with a theoretical maximum transmission speed of 480 Mbps. Therefore, the reliability and convenience of projectile velocity measurement are greatly improved, possessing significant practical value and broad application prospects. [b]1 Measurement Principle[/b] First, two induction coil targets with a spacing of s (20 cm) are installed at the muzzle end; the output of the target sensor is differentially connected to the measuring instrument. When firing, the magnetic projectile exits the muzzle, passes through the induction coil targets, and generates an induced electromotive force within the targets. Two abrupt signals with a certain time interval (Δt) are obtained at the input end of the measuring instrument, as shown in signals A and B in Figure 1. After conditioning and shaping, the two abrupt signals are transformed into pulse signals with a velocity of ds/dt and an initial velocity of V=s/Δt for the projectile. The time interval Δt is measured by counting, using a 40 MHz active crystal oscillator as the counting pulse source, and the minimum resolution of the counting can reach 0.25μs. The measurement principle is shown in Figure 2. [b]2 System Scheme and Hardware Implementation[/b] In Figure 1, when the projectile passes through coils A and B, it will generate an induced signal with a certain pulse amplitude, and there is a certain time interval between the two signals. The conditioning part is to shape the induced signal into a regular square wave and then input it into the velocity measurement module. After completing the velocity measurement, the velocity measurement module transmits the result to the main control console via the USB interface. The main control console software displays and processes the result, as shown in Figure 3. 2.1 Conditioning Module The signal output by the projectile passing through the induction coil is ys(t), with a signal amplitude of about 150 mV. Due to external interference (such as temperature and power supply changes), even without a projectile passing through the induction coil, there is still a random signal output of about 20 mV, yn(t), which is the background noise. The expression for the output y(t) of the induction coil is: y(t) = ys(t) + yn(t). In reality, the output signal is the superposition of the induced signal ys(t) and the background noise yn(t). Common methods to separate the useful signal from the projectile passing through the induction coil from the random background noise include: threshold comparison method, filtering, and intelligent method. This system uses the threshold comparison method. It is simple, clear, and easy to implement. Because the analog signal output by the induction coil at the front end is weak, the instrumentation operational amplifier IN129 with differential input is selected at the front end of the conditioning module. It has high input impedance and includes three stages of operational amplifiers internally. The back end uses the high-precision dual operational amplifier AD712, which has the advantages of small input offset voltage and small input offset voltage drift, which can reduce signal distortion during transmission and amplification. The final stage uses the voltage comparator LM311 to implement the threshold comparison. The threshold is an empirical value derived from theoretical calculations and experiments. The entire process involves the projectile's induced signal (approximately 150 mV) passing through a coil, then through a high-input-impedance instrumentation amplifier IN129, followed by amplification by a certain factor using a high-precision operational amplifier AD712. Finally, it is compared with a reference voltage and shaped to output a square wave. The output square wave signal is directly used as the gate control for counting. 2.2 The velocity measurement module, under the control of start/stop pulses, mainly employs three methods to achieve counting: MCU (microcontroller) implementation, digital integrated circuit (IC) integration, and CPLD/FPGA hardware description language implementation. When using a microcontroller timer or interrupt method, the counting speed is limited by the MCU's clock frequency, affecting the accuracy of projectile velocity measurement. Using IC integration is too cumbersome and increases the printed circuit board size, impacting stability and integration. This system uses a hardware description language implementation in a CPLD, offering high integration, good stability, and allowing for hardware upgrades without modifying the printed circuit board. The speed measurement module is implemented in the Altera MAX3000A series EPM3128ATC144-10 chip, as shown in Figure 4. The main functional sub-modules include: a counting control module, a 24-bit counting module, and an I2C transceiver module. Upon receiving the start counting signal (rising edge), the counting control module notifies the 24-bit counting module to begin resetting and counting. When the stop signal arrives, counting stops and an interrupt request is sent to the firmware of the CY7C68013 chip. The firmware receives the count value via the I2C bus and waits for the next count. 2.3 USB 2.0 Interface Chip CY7C68013 The CY7C68013 chip is a high-speed USB 2.0 device controller from Cypress Semiconductor's EZ-FX2 series, supporting up to 480 Mbps (high-speed) operation. It integrates a USB 2.0 transceiver, SIE (Serial Interface Engine), an enhanced 8051 microcontroller, and programmable peripheral interfaces (GPIF, FIFO, I2C). Upon power-up, the CY7C68013 chip can read the firmware program from the external E2PROM via the I2C interface to complete the protocol bootstrapping process. As shown in Figure 5, after the measurement begins, the CY7C68013 chip operates under the control of the firmware. When interrupt INT6 is received, it indicates that the measurement is complete and converted into a 24-bit count value. The firmware program reads the 24-bit count value, i.e., the time interval (Δt) between the projectiles passing through the induction coil target, via the I2C interface, and then uploads it to the host computer via the USB interface. During continuous firing measurements, the above process is repeated, except that the CY7C68013 resets the count value to zero each time it reads back data, and allows the next count. [b]3 Software Design[/b] The software design is divided into the CY7C68013 chip firmware program design and the host computer application software design, with the firmware program design being the main focus. The program flow is shown in Figure 6. The firmware program development is completed using Keil C51 and utilizes Hex2bix. The executable converts the HEX file to an I2C file using the powerful Keil C51 compilation environment, and then downloads the I2C file to an E2PROM (24LC64) using the EZ-USB Control Panel. In the program writing, endpoints 2 and 4 are set as block outputs, and endpoints 6 and 8 are set as block inputs. After a shell is fired, it generates a count value after passing through the front and rear coils. The data from the 24-bit counting module is read using the I2C bus, and the high, medium, and low 8 bits are sent back to the CY7C68013, and then transmitted to the host computer via USB 2.0. The application uses Visual C++ 6.0 development tools. To test the shell velocity, first click the "Prepare for Test" button, then fire N shells (N≤20), and then click "Test Complete." The shell velocity is displayed in the left text box, thus realizing the measurement of single-shot or burst-fire shell velocity. Create a new MFC project, and open the USB device in BOOL CUsbTestDlg::OnInitDialog() to obtain the endpoint information. Control information is sent to endpoint 2, and the firmware program performs either "preparing for test" or "test completed" operation based on the sent information. [b]Conclusion[/b] With the development of Universal Serial Bus (USB) interface technology, USB interfaces have been widely used in the testing field. This paper introduces a gun velocity measurement system that utilizes USB interface technology combined with large-scale integrated circuits and electronic design automation (EDA). This system has high practical value in gun velocity measurement, demonstrating high flexibility and stability in actual use; coupled with its excellent cost-effectiveness, this implementation method has good application prospects in the testing field. Editor: He Shiping
Read next

CATDOLL Milana Soft Silicone Head

You can choose the skin tone, eye color, and wig, or upgrade to implanted hair. Soft silicone heads come with a functio...

Articles 2026-02-22