1 Overall hardware design of DC motor
As shown in Figure 1, the system is controlled by FPGA chips as a whole, and its control core is ALTERA's NiosII soft-core CPU. This paper will focus on the design and generation of the two control function modules PWM module and speed measurement module in the figure. Both control function modules use VHDL hardware description language to design and generate callable IP cores, which are compiled and simulated by QuartusII to verify their correctness. Finally, the generated custom interface function module is added to the top-level schematic diagram to complete the design of the entire speed regulation system.
2 Design of PWM Function Module
The PWM module uses the DC motor duty cycle to control the motor armature voltage, thereby controlling the speed of the DC motor. The design process is shown in Figure 2.
The simulation waveform of the PWM function module is shown in Figure 3.
As can be seen from Figure 3, a clock signal Clk is given during simulation, and Sta is used to control the forward and reverse rotation of the DC motor. 0 in Figure 3 indicates that the DC motor is in the forward state, 1 indicates stopping, and 3 indicates reversing; Conword is the duty cycle signal, and there are three values of 25%, 78%, and 50% in the simulation; PWM A indicates the duty cycle output when the DC motor is in the forward state, and the output of PWM B is 0 at this time; PWM B indicates the duty cycle output when the DC motor is in the reverse state, and the output value of PWM A is 0 at this time; and when the motor is in the stopped state, as shown in the figure when the Sta value is 1, the output values of PWM A and PWM B are both 0. The simulation timing diagram verifies that this design is effective, and thus generates a PWM function module.
The PWM function module is shown in Figure 4.
The principle of the PWM control function module is as follows: the base frequency signal of the clock source 50MHz is divided by 64 as the base frequency signal of the PWM module, and 256 base frequency pulse signals are used as a cycle of PWM output. The value of Conword given by the NiosII processor specifies the duration of the high level within a PWM cycle. Changing the value of Conword immediately changes the value of the duty cycle output. Sta is used to control the forward and reverse rotation of the motor.
The pin allocation diagram of the PWM control function module is shown in Figure 5.
3 Design of speed measurement function module
The function of the speed measurement module is mainly to use the period of the base frequency to calculate the period of the grating signal and calculate the speed of the DC motor. The flow chart of its design is shown in Figure 6.
The timing simulation waveform of the speed measurement module is shown in Figure 7.
As can be seen from Figure 7, a clock signal Clk is given for timing during simulation, en is the enable signal, which means that the grating is valid, dout indicates the grating effective time, and there are three values of 200, 400, and 700 in the simulation. The timing simulation verifies that the speed measurement module of this design is valid, so it is generated into a speed measurement function module.
The speed measurement function module is shown in Figure 8.
Its working principle is as follows: given a known base frequency, the grating is used as the threshold, the number of base frequency pulses is measured, the period of the grating signal is calculated from the period of the base frequency, and then the speed is calculated. The motor control algorithm is adjusted according to the speed measured by the speed measurement module to achieve the effect of closed-loop control.
The pin allocation diagram of the speed measurement module is shown in Figure 9.
4 Conclusion
According to the functional requirements of the DC motor, the PWM function module and the speed measurement module were designed using the VHDL language, and simulation was performed to verify the correctness of the design and complete the system design. The innovation of this paper is to directly design the control function module using software and hardware. This design has the advantages of short development cycle, good general ability, and easy development and expansion, and is worth promoting.
Previous article:Long-distance data transmission based on current loop circuit
Next article:Design of 10-bit high-precision ADC based on STC12C5410AD
Recommended ReadingLatest update time:2024-11-16 21:24
- Popular Resources
- Popular amplifiers
- 西门子S7-12001500 PLC SCL语言编程从入门到精通 (北岛李工)
- New Energy Vehicle Detection and Diagnosis Experiment (Edited by Mao Caiyun, Zhou Xien, and Long Jiwen)
- Virtualization Technology Practice Guide - High-efficiency and low-cost solutions for small and medium-sized enterprises (Wang Chunhai)
- ESP32-S3 source code
- MathWorks and NXP Collaborate to Launch Model-Based Design Toolbox for Battery Management Systems
- STMicroelectronics' advanced galvanically isolated gate driver STGAP3S provides flexible protection for IGBTs and SiC MOSFETs
- New diaphragm-free solid-state lithium battery technology is launched: the distance between the positive and negative electrodes is less than 0.000001 meters
- [“Source” Observe the Autumn Series] Application and testing of the next generation of semiconductor gallium oxide device photodetectors
- 采用自主设计封装,绝缘电阻显著提高!ROHM开发出更高电压xEV系统的SiC肖特基势垒二极管
- Will GaN replace SiC? PI's disruptive 1700V InnoMux2 is here to demonstrate
- From Isolation to the Third and a Half Generation: Understanding Naxinwei's Gate Driver IC in One Article
- The appeal of 48 V technology: importance, benefits and key factors in system-level applications
- Important breakthrough in recycling of used lithium-ion batteries
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- [Mill Edge AI Computing Box FZ5 Review] PYNQ Framework Transplantation (Long Article Warning)
- MSP430 MCU Principle and Application Experiment Example
- [AT-START-F425 Review] GPIO key interrupt + CAN receive counter
- A power engineer's insights on EMI!
- MSP430 MCU Development Record (28)
- TWS Bluetooth Headset Disassembly
- [GD32L233C-START Review] Review 3: Accurate delay measurement using timer time5
- 【Chuanglong TL570x-EVM】Review 03 - Evaluation Board Test Manual
- [nRF52840 DK Review] Custom BLE Services
- Download and get a gift | Keysight Technologies [Cheats on how to choose and use oscilloscope probes]