Self-adaptive method and system of coreless direct current motor
By testing and adjusting control parameters at a variety of temperatures, the coreless DC motor achieves stable operation under different temperature conditions, solves the problem of motor performance degradation caused by changes in the accuracy of the Hall sensor signal, and improves the accuracy and accuracy of speed control. Motor adaptability.
Patent Information
- Application Number
- CN202410845261.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-27
- Publication Date
- 2024-10-01
- Estimated Expiration
- 2044-06-27
AI Technical Summary
When the temperature of the coreless DC motor changes, the accuracy of the Hall sensor output signal changes, causing the microcontroller to match the wrong commutation sequence, affecting the motor performance, such as unstable speed control or insufficient torque output.
By testing and operating the motor at various temperatures, the control parameters corresponding to each temperature are obtained, the power-on sequence and control parameters in the commutation table are adjusted, the Hall sensor is used to detect changes in the magnetic field, and the microcontroller reads the electrical signal through the timer. The logic control unit generates a new control signal and adjusts the PWM duty cycle to optimize the speed until the error threshold is met to achieve adaptive control.
The motor can operate stably under different temperature conditions with accurate speed control, avoiding performance degradation caused by temperature changes and improving the adaptability and reliability of the motor.
Smart Images

Figure CN118739912A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electric motors, and more particularly to an adaptive method and system for a coreless DC motor. Background Technology
[0002] With the continuous development of motor technology and people's increasing pursuit of motor performance and reliability, brushless motors have emerged. The DC coreless motor is a type of brushless motor. Brushless motors use a microcontroller for sensor-driven control, and the control algorithm enables electronic commutation and controls the motor's rotor.
[0003] Currently, coreless motors typically use Hall effect sensors to detect changes in the internal magnetic field and output electrical signals to control the motor's rotation. The output signal of a Hall effect sensor is easily affected by ambient temperature, and its accuracy varies with temperature. Under the influence of temperature changes, the error between the actual and ideal electrical signals can cause the microcontroller to match incorrect commutation timing using preset commutation tables and control parameters, resulting in incorrect PWM (Pulse Width Modulation). This, in turn, affects the motor's performance, such as unstable speed control or insufficient torque output.
[0004] Therefore, it is necessary to provide a hollow cup DC motor that can be used under different temperature conditions. Summary of the Invention
[0005] The purpose of this invention is to provide an adaptive method for a coreless DC motor, based on a microcontroller connected to the motor. The microcontroller stores a commutation table, characterized in that the commutation table includes a power-on sequence, digital signals, and control parameters. The method includes the following steps:
[0006] The motor was tested and operated at various temperatures. The control parameters corresponding to each temperature were obtained. The energizing sequence corresponding to the commutation table was obtained according to the control parameters. The logic control unit energized each winding of the motor in sequence according to the energizing sequence.
[0007] When the motor's windings are energized and the rotor drives the permanent magnet to rotate, it generates a change in the magnetic field. The Hall sensor detects the change in the magnetic field and continuously outputs an electrical signal based on the change in the magnetic field.
[0008] The microcontroller continuously reads the digital signal corresponding to the electrical signal through a timer unit;
[0009] The logic control unit retrieves the commutation table based on the digital signal and obtains the control signal;
[0010] The advanced timer unit sets the PWM duty cycle according to the control signal and adjusts the motor speed through the PWM duty cycle;
[0011] Based on the control signal, the speed control unit calculates the speed error E;
[0012] An error threshold S is set within the logic control unit. If the relationship E≥S is satisfied, the logic control unit executes a loop program, continuously generating new control parameters and comparing the speed error E with the error threshold S based on the control parameters, until the relationship E<S is satisfied. Then, the logic control unit exits the loop program and retains the control parameters in the current loop.
[0013] Even better, the commutation table also includes commutation steps, each with a corresponding energizing sequence;
[0014] The motor operates according to the power-on sequence and commutation steps. The temperature sensor obtains the temperature T1 when the motor is running, and the temperature sensor is set with a critical temperature T2. When T1 < T2, the motor operates stably; when T1 ≥ T2, the efficiency of the motor decreases.
[0015] More preferably, if the motor operating efficiency decreases, the logic control unit increases the control parameters, and the corresponding energizing sequence in the commutation table is changed according to the control parameters;
[0016] When the motor is running stably, the commutation table acquires and saves the control parameters and power-on sequence corresponding to the current temperature.
[0017] More preferably, if the commutation meter records a power-on sequence that matches the digital signal, the logic control unit obtains the first control signal based on the control parameters corresponding to the digital signal.
[0018] If the commutation table does not record a power-on sequence that matches the digital signal, the logic control unit adds a second control parameter and updates the commutation table, obtaining the second control signal based on the added control parameter.
[0019] More preferably, when the control signal is the first control signal, the power-on sequence preset by the commutation table is executed; when the control signal is the second control signal, the second control signal is transmitted to the speed control unit through the advanced timer unit. The speed control unit obtains the set speed and the actual speed, calculates the speed error E based on the set speed S1 and the actual speed S2, and satisfies the relationship: E=|S1-S2|.
[0020] If E < S, the logic control unit retains the second control parameter and saves the current commutation table; if E ≥ S, the logic control unit deletes the second control parameter and adds a third control parameter. The logic control unit obtains the third control signal based on the third control parameter and transmits it to the advanced timer unit. The advanced timer unit resets the PWM duty cycle through the third control signal and adjusts the actual speed S2 of the motor according to the PWM duty cycle. The system then determines whether the third control parameter is usable based on the actual speed S2 adjusted by the third control signal.
[0021] More preferably, the timer unit includes a general-purpose timer unit. Through the general-purpose timer unit, the microcontroller acquires the electrical signal from the Hall sensor. The electrical signal is converted into a digital signal by the analog-to-digital converter and transmitted to the timer unit.
[0022] Control parameters and set speeds are stored in peripheral memory. The direct memory access unit (DMI) allows data transfer between the microcontroller and peripheral devices without processing the processor. The speed control unit obtains the set speed through the DMI, and the logic control unit obtains the control parameters through the DMI.
[0023] More preferably, the method further includes the step of:
[0024] If the motor stops, the power management unit triggers the power saving mode, the timer unit and the direct memory access unit are powered off, and the logic control unit operates at the first power P1.
[0025] More preferably, if the motor starts, the Hall sensor outputs an electrical signal, and the electrical signal enters the analog-to-digital converter unit. The analog-to-digital converter unit converts the electrical signal into an interrupt signal and transmits it to the logic control unit. According to the interrupt signal, the logic control unit interrupts the power saving mode of the power management unit and clears the interrupt signal. Through the interrupt power saving mode, the power-off devices are restored to power.
[0026] After the power-on mode is restored, the logic control unit operates at the second power P2 and satisfies the following relationship:
[0027] P1≤P2×0.1.
[0028] Even better,
[0029] The higher the PWM duty cycle, the higher the proportion of voltage received by the motor, and the faster the motor speed.
[0030] The lower the PWM duty cycle, the lower the proportion of voltage received by the motor, and the slower the motor speed.
[0031] When the duty cycle is 0%, the motor is powered off, and the speed gradually decreases until it eventually stops rotating.
[0032] A system for a coreless DC motor, the system implementing the aforementioned adaptive method for a coreless DC motor.
[0033] The present invention has the following beneficial effects:
[0034] This invention obtains a commutation table containing control parameters for each temperature by testing and operating a motor at various temperatures. Based on these control parameters, the motor is driven to operate at these temperatures. The accuracy of the control parameters at different temperatures is determined by comparing the speed error E with the error threshold S. By executing a cyclic program on the motor, the commutation table and control parameters are continuously optimized, enabling the motor to adapt to different temperature conditions. Attached Figure Description
[0035] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.
[0036] Figure 1 This is a structural block diagram of the motor described in one embodiment of this application;
[0037] Figure 2 This is a connection block diagram of the motor described in one embodiment of this application;
[0038] Figure 3 This is a connection block diagram of the direct memory access unit in the motor described in one embodiment of this application;
[0039] Figure 4 This is a connection block diagram of the timer unit in the motor described in one embodiment of this application;
[0040] Figure 5 This is a connection block diagram of the analog-to-digital conversion unit in the motor described in one embodiment of this application;
[0041] Figure 6 This is a connection block diagram of the power management unit in the motor described in one embodiment of this application;
[0042] Figure 7 This is a connection block diagram of the logic control unit in the motor described in one embodiment of this application;
[0043] Explanation of reference numerals: 500, Temperature sensor; 400, Motor; 300, Peripheral memory; 200, Hall sensor; 100, Microcontroller; 10, Commutation meter; 20, Timer unit; 21, Advanced timer unit; 22, General purpose timer unit; 30, Logic control unit; 40, Speed control unit; 50, Analog-to-digital converter; 60, Direct memory access unit; 70, Power management unit. Detailed Implementation
[0044] To facilitate understanding of this application, a more complete description will be provided below with reference to the accompanying drawings. Preferred embodiments of this application are shown in the drawings. However, this application can be implemented in many different forms and is not limited to the embodiments described herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of the disclosure of this application.
[0045] It should be noted that when a component is said to be "fixed to" another component, it can be directly attached to the other component or there may be an intervening component. When a component is said to be "connected to" another component, it can be directly connected to the other component or there may be an intervening component. The terms "vertical," "horizontal," "left," "right," and similar expressions used in this document are for illustrative purposes only.
[0046] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein in the specification of this application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. The term "and / or" as used herein includes any and all combinations of one or more of the associated listed items.
[0047] Please refer to Figure 1 - Figure 7 An adaptive method for a hollow cup DC motor 400, based on a microcontroller 100 connected to the motor 400, is characterized in that the method includes the following steps:
[0048] S01 tests the operation of motor 400 at various temperatures, obtains the control parameters corresponding to each temperature, obtains the energizing sequence corresponding to the commutation table 10 according to the control parameters, and the logic control unit 30 energizes each winding of the motor in sequence according to the energizing sequence.
[0049] More specifically, the commutation table 10 also includes commutation steps, each with a corresponding energizing sequence. The motor operates according to the energizing sequence and commutation steps. The temperature sensor 500 acquires the operating temperature T1 of the motor 400, and the temperature sensor 500 is set with a critical temperature T2. When T1 < T2, the motor 400 operates stably; when T1 ≥ T2, the efficiency of the motor 400 decreases. If the efficiency of the motor 400 decreases, the logic control unit 30 increases the control parameters, and the corresponding energizing sequence in the commutation table 10 changes according to the control parameters. When the motor 400 is running stably, the commutation table 10 acquires and saves the control parameters and energizing sequence corresponding to the current temperature.
[0050] In this specific embodiment, according to step S01, a specific example is provided to demonstrate the commutation table and corresponding control parameters under different temperature conditions:
[0051] This example sets six energizing sequences for motor 400, labeled A, B, C, D, E, and F, and sets the critical temperature T2 of the temperature controller to 70°C. This example uses a speed control unit 40, with control parameters including proportional (P), integral (I), and derivative (D). Three temperatures T1 are set: 25°C, 50°C, and 75°C. The commutation table entries include commutation steps and energizing sequences. Commutation steps refer to the order in which current switches between different motor 400 coils during motor 400 control. Commutation steps supply power to different windings of motor 400 at different times, generating a rotating magnetic field that drives the rotor of motor 400 to rotate continuously. The energizing sequence refers to which one or more motor 400 windings are energized in each commutation step, and the direction of the current. The energizing sequence determines the direction and magnitude of the generated magnetic field.
[0052] First, define commutation table 10. Commutation table 10 has six commutation steps: Step 1, Step 2, Step 3, Step 4, Step 5, and Step 6. Step 1 corresponds to energizing sequence A, Step 2 to energizing sequence B, Step 3 to energizing sequence C, Step 4 to energizing sequence D, Step 5 to energizing sequence E, and Step 6 to energizing sequence F. This is the default energizing sequence for each commutation step of motor 400.
[0053] Then, the motor 400 was run at three temperature conditions: 25℃, 50℃, and 75℃, and the commutation table 10 and control parameters corresponding to each temperature condition were obtained:
[0054] When T1 = 25℃, then T1 < T2. The energizing sequence corresponding to each commutation step is the same as that in commutation table 10, and the control parameters are: proportional P = 1.0, integral I = 0.1, and derivative D = 0.01.
[0055] When T1 = 50℃, then T1 < T2. The energizing sequence corresponding to each commutation step is the same as that in commutation table 10, and the control parameters are: proportional P = 1.0, integral I = 0.1, and derivative D = 0.01.
[0056] When T1 = 75℃, the relationship TI ≥ T2 is satisfied. In the commutation table, the energizing sequence for each commutation step is as follows: Step 1 corresponds to energizing sequence A, Step 2 to energizing sequence C, Step 3 to energizing sequence E, Step 4 to energizing sequence B, Step 5 to energizing sequence D, and Step 6 to energizing sequence F. The control parameters are increased to: Proportional P = 1.5, Integral I = 0.2, and Derivative D = 0.03.
[0057] When the operating temperature T1 of motor 10 is greater than or equal to T2, the control parameters P, I, and D will increase as the operating temperature T1 rises. This is because the performance of motor 400 changes under high-temperature conditions, requiring adjustment of the control parameters to maintain stable control. At 75℃, the energizing sequence of the commutation meter is adjusted. This is to adapt to the operating characteristics of motor 400 under high-temperature conditions and optimize the operating efficiency and stability of motor 400.
[0058] When the windings of the S02 motor 400 are energized and started, the rotor of the motor 400 drives the permanent magnet to rotate and generate a change in magnetic field. The Hall sensor 200 detects the change in magnetic field and continuously outputs an electrical signal according to the change in magnetic field.
[0059] The permanent magnet typically has two magnetic poles, a north pole and a south pole. As the permanent magnet rotates, these two poles move relative to the fixed position of the Hall sensor 200. Because the magnetic field of the permanent magnet is directional, rotation causes the Hall sensor 200 to be in different magnetic field positions, resulting in changes in the magnetic field strength and direction. If the permanent magnet continues to rotate, the Hall sensor 200 will periodically detect these changes in the magnetic field. The frequency of these changes is directly related to the rotational speed of the permanent magnet. When the magnetic field passes through the Hall sensor 200, the current flowing inside the sensor is perpendicular to the direction of the magnetic field. Under the influence of the magnetic field, a Hall voltage is generated within the sensor. The Hall sensor 200 converts the detected Hall voltage into a corresponding electrical signal, the amplitude and frequency of which are proportional to the strength and rate of change of the magnetic field. This electrical signal is typically output as a voltage or current and is then transmitted to the microcontroller 100 for processing.
[0060] The S03 microcontroller 100 continuously reads the electrical signal output by the Hall sensor 200 through the timer unit 20;
[0061] The timer unit 20 includes a general-purpose timer unit 22. Based on the input capture function of the general-purpose timer unit 22, the microcontroller 100 acquires the electrical signal from the Hall sensor 200. The electrical signal is converted into a digital signal by the analog-to-digital converter unit 50 and transmitted to the timer unit 20. More specifically, the electrical signal enters the timer unit 20 through the GPIO pins of the microcontroller 100. The timer's prescaler and auto-reload register are configured to set the counter's time base. The timer's capture register is configured to select which input pin to capture and select the capture condition. When the edge of the input signal arrives, the current timer count value is copied to the capture register. An interrupt is triggered or a flag is set to notify the microcontroller 100 of the capture event. The analog-to-digital converter unit 50, also known as the ADC, configures the ADC's reference voltage and resolution. The ADC input channel connected to the output of the Hall sensor 200 is selected. The sampling time is set according to the characteristics of the input signal to ensure sufficient accuracy. Conversion is initiated via software or automatically triggered by a timer. The ADC acquires the voltage signal from the input pin. The sampled voltage is kept stable by a sample-and-hold circuit. The analog voltage is quantized into discrete digital values, and the quantized voltage values are encoded into digital signals. Finally, the conversion result is read from the data register into the memory of the microcontroller 100.
[0062] More specifically, according to step S03, this specific embodiment provides a specific example, the following of the running code and code comments in the example:
[0063] / / Timer capture configuration function
[0064] voidTimer_Capture_Init(){
[0065] / / Assuming timer TIM2 is used and the system clock is 80MHz
[0066] RCC->APB1ENR|=RCC_APB1ENR_TIM2EN; / / Enable TIM2 clock
[0067] TIM2->PSC=79; / / Set the prescaler to 79 (80MHz / (79+1)=1MHz, i.e., 1 microsecond unit)
[0068] TIM2->ARR = 0xFFFF; / / Automatic reload register, maximum value
[0069] / / Configure capture mode
[0070] TIM2->CCMR1|=TIM_CCMR1_CC1S_0; / / Input capture selects the CC1 channel.
[0071] TIM2->CCER|=TIM_CCER_CC1E; / / Enable capture 1
[0072] TIM2->CCER&=~TIM_CCER_CC1P; / / Capture rising edge
[0073] TIM2->DIER|=TIM_DIER_CC1IE; / / Capture interrupt 1 enable
[0074] / / Start the timer
[0075] TIM2->CR1|=TIM_CR1_CEN; / / Enable timer
[0076] }
[0077] / / ADC initialization function
[0078] void ADC_Init()
[0079] / / Assuming ADC1 is used
[0080] RCC->APB2ENR|=RCC_APB2ENR_ADC1EN; / / Enable ADC1 clock ADC1->CR1=0; / / Clear CR1 register
[0081] ADC1->CR2 = ADC_CR2_ADON; / / Enable ADC and set continuous conversion mode / / Set ADC resolution to 12 bits
[0082] ADC1->CR1|=ADC_CR1_RES_12BIT;
[0083] / / Configure the sampling time to 15 cycles
[0084] ADC1->SMPR2=ADC_SMPR2_SMP1_15CYCLES;
[0085] / / Select Channel 1
[0086] ADC1->SQR3=ADC_SQR3_SQ1_0;
[0087] / / Enable ADC ADC1->CR2|=ADC_CR2_ADON;
[0088] / / ADC readout function
[0089] uint16_tADC_Read(){
[0090] / / Start ADC conversion
[0091] ADC1->CR2|=ADC_CR2_SWSTART;
[0092] / / Wait for conversion to complete
[0093] while(!(ADC1->SR&ADC_SR_EOC));
[0094] / / Read the conversion result
[0095] returnADC1->DR;
[0096] }
[0097] The S04 logic control unit 30 retrieves the commutation table 10 based on the electrical signal and obtains the control signal;
[0098] The control parameters are stored in the peripheral memory 300, and the logic control unit 30 retrieves these parameters via the direct memory access unit 60 (DMA). The peripheral memory 300 typically has a larger storage capacity, capable of holding more control parameters and configuration data. The internal memory capacity of the microcontroller 100 is limited and may not be sufficient to store all the necessary control parameters. The peripheral memory 300 is non-volatile, retaining data even in the event of a power outage. The control parameters need to be preserved after a power outage in the motor 400 system so that they can be directly used upon the next startup without reconfiguration.
[0099] The Direct Memory Access Unit 60, also known as the DMA unit, can directly read control parameters from the peripheral memory 300 and transfer them to the memory area used by the logic control unit 30 without consuming CPU resources. This improves data transfer efficiency and reduces the load on the CPU. Using the DMA unit for data transfer ensures that control parameters are quickly obtained when needed, meeting the requirements of real-time control. Especially in high-performance motor 400 control applications, fast response is crucial. Data transfer via DMA allows the CPU to focus on other tasks, such as processing complex control algorithms and real-time decisions, thereby improving the overall system performance and responsiveness.
[0100] Control parameters typically include PID (proportional, integral, and derivative) parameters, commutation timing, PWM duty cycle, etc., which directly affect the performance and stability of the motor 400. The logic control unit 30 generates control signals based on these parameters to ensure the motor 400 operates according to the expected performance. The control parameters can be dynamically adjusted according to different operating conditions (such as load changes and temperature changes). The logic control unit 30 uses these dynamically adjusted control parameters to generate appropriate control signals to adapt to different operating environments and optimize the performance of the motor 400. In a closed-loop control system, the logic control unit 30 needs to continuously adjust the control signals to minimize errors and ensure that the motor 400 operates according to the set trajectory or speed. Control parameters are crucial to achieving this process; they determine the generation method and adjustment strategy of the control signals.
[0101] More specifically, according to step S04, this specific embodiment provides a specific example, the following of the running code and code comments of the adaptive control function in the example:
[0102] #include<stdint.h>
[0103] / / Assume the control parameters are stored at a certain address in peripheral memory 300.
[0104] #defineCONTROL_PARAM_ADDRESS0x0800F000
[0105] / / Control parameter structure
[0106] typedef struct {
[0107] uint16_tcommutationTable;
[0108] floatpwmDutyCycle;
[0109] floatpidParams[3]; / / P,I,D
[0110] ControlParams;
[0111] / / DMA configuration function
[0112] void DMA_Config(){
[0113] / / Configure DMA registers
[0114] / / Assuming DMA1 channel 1 is used
[0115] RCC->AHBENR|=RCC_AHBENR_DMA1EN; / / Enable DMA1 clock
[0116] DMA1_Channel1->CPAR = CONTROL_PARAM_ADDRESS; / / Peripheral address
[0117] DMA1_Channel1->CMAR = (uint32_t)&controlParams; / / Memory address to be stored DMA1_Channel1->CNDTR = sizeof(ControlParams) / sizeof(uint32_t); / / Data size DMA1_Channel1->CCR = DMA_CCR_MINC|DMA_CCR_TCIE|DMACCR_EN; / / Configure DMA
[0118] }
[0119] / / Logic Control Unit 30
[0120] voidLogicControlUnit(ControlParams*params){
[0121] / / Generate control signals based on control parameters
[0122] uint16_tcommutationTable=params->commutationTable;
[0123] floatpwmDutyCycle=params->pwmDutyCycle;
[0124] floatp=params->pidParams[0];
[0125] floati=params->pidParams[1];
[0126] floated=params->pidParams[2];
[0127] / / Example: Setting the PWM duty cycle
[0128] SetPWM(pwmDutyCycle);
[0129] / / Example: Adjusting engine speed using PID parameters
[0130] PID_Controller(p,i,d);
[0131] }
[0132] int main(){
[0133] / / Initialize the system
[0134] SystemInit();
[0135] / / Configure DMA
[0136] DMA_Config();
[0137] / / Wait for DMA transfer to complete
[0138] while(!(DMA1->ISR&DMA_ISR_TCIF1));
[0139] / / Logic control unit 30 processing
[0140] LogicControlUnit(&controlParams);
[0141] while(1) / / Main loop
[0142] }
[0143] The S05 advanced timer unit 21 sets the PWM duty cycle according to the control signal and adjusts the speed of the motor 400 through the PWM duty cycle;
[0144] Specifically, a higher PWM duty cycle results in a higher proportion of voltage received by motor 400, leading to a faster motor speed; a lower PWM duty cycle results in a lower proportion of voltage received by motor 400, leading to a slower motor speed. When the duty cycle is 0%, motor 400 is de-energized, its speed gradually decreases, and it eventually stops rotating. According to the energizing sequence of the commutation table, the logic control unit 30 cyclically energizes each motor 400 coil sequentially.
[0145] S06 Based on the control signal, the speed control unit 40 determines whether to calculate the speed error; wherein, the set speed is stored in the peripheral memory 300, and the speed control unit 40 obtains the set speed through the direct memory access unit 60. When the control signal is the second control signal, the logic control unit 30 executes the adaptive control function. In the adaptive control function, the second control signal is transmitted to the speed control unit 40 through the advanced timer unit 21. The speed control unit 40 obtains the set speed and the actual speed, and calculates the speed error E based on the set speed S1 and the actual speed S2, specifically: E = |S1 - S2|. Based on the actual speed S2 adjusted by the third control signal, it determines whether the third control parameter is available.
[0146] The S07 logic control unit 30 sets an error threshold S and analyzes the speed error E based on the error threshold S to determine whether to reconfigure the speed of the motor 400. If the speed error E < the error threshold S, the second control parameter is retained, and the commutation table is updated. When the speed error E ≥ the error threshold S, the logic control unit 30 deletes the second control parameter and adds a third control parameter. The logic control unit 30 obtains the third control signal based on the third control parameter and transmits it to the advanced timer unit 21. The advanced timer unit 21 resets the PWM duty cycle using the third control signal and readjusts the actual speed S2 of the motor 400 based on the PWM duty cycle. The system determines whether the third control parameter is usable based on the adjusted actual speed S2. If E ≥ S, the logic control unit 30 executes the adaptive control function cyclically until the expression is satisfied. If E < S, the logic control unit 30 exits the loop but retains the control parameters in the current loop.
[0147] Based on steps S05, S06, and S07, this specific embodiment provides a specific example:
[0148] First, set the following initial parameters: set speed = 1500 RPM, actual speed = 1400 RPM, initial PWM duty cycle = 50, error threshold S = 50 RPM.
[0149] Calculate the speed error E:
[0150] Speed error E = |S1 - S2| = |1500 - 1400| = 100 RPM
[0151] Because E(100RPM)≥S(50RPM), the motor needs to be reconfigured to 400 RPM.
[0152] Based on the error threshold, E(100RPM)≥S(50RPM), therefore the control parameters need to be adjusted to generate a third control signal and adjust the PWM duty cycle: the PWM duty cycle adjusted by the speed control unit 40 is 55%. The advanced timer unit 21 sets the PWM duty cycle to 55% according to the third control signal. At this time, the voltage received by the motor 400 is 12V*55%=6.6V.
[0153] If the adjusted actual speed S2 is 1460 RPM, the speed error E = |S1 - S2| = |1500 - 1460| = 50 RPM is recalculated. Since E(40 RPM) < S(50 RPM), the third control parameter is valid, the commutation table is updated, and the current control parameter is retained. If the adjusted actual speed S2 is 1430 RPM, the speed error E = |S1 - S2| = |1500 - 1430| = 70 RPM is recalculated. Since E(70 RPM) ≥ S(50 RPM), the third control parameter is invalid. The logic control system deletes the third control parameter and adds a new control parameter, iteratively judging whether the control parameter is valid until the expression: speed error E < S is satisfied.
[0154] If motor 400 stops, power management unit 70 triggers power saving mode, timer unit 20 and direct memory access unit 60 are powered off, and logic control unit 30 operates at first power.
[0155] When motor 400 stops, continuing to operate all system units would result in unnecessary power consumption. Power-off timer unit 20 and direct memory access unit 60 (DMA) can significantly reduce energy consumption. In battery-powered systems, reducing unnecessary power consumption directly extends battery life. Triggering power-saving modes is a key energy-saving measure. By reducing the number and power of operating units, system heat generation can be reduced. This is especially important in high ambient temperatures or poor ventilation conditions. Effective management of power-saving modes during system design reduces stringent requirements for heat dissipation and power supply design, thereby simplifying the overall design and improving system reliability.
[0156] Timer unit 20 manages commutation timing and PWM signal generation while motor 400 is running. These functions are no longer needed when motor 400 stops, so power is cut off to save energy. DMA units are typically used for efficient data transfer, reducing CPU load. With motor 400 stopped, data transfer requirements are reduced, and power-off avoids unnecessary energy consumption. Logic control unit 30 continuously monitors Hall sensor 200 or other start signals in low-power mode.
[0157] When motor 400 starts (S09), Hall sensor 200 outputs an electrical signal, which enters analog-to-digital converter 50. Analog-to-digital converter 50 converts the electrical signal into an interrupt signal and transmits it to logic control unit 30. Based on the interrupt signal, logic control unit 30 executes an interrupt control function, interrupting the power-saving mode of power management unit 70 and clearing the interrupt signal. Through the interrupt power-saving mode, the de-energized devices are restored to power. Logic control unit 30 operates at a second power P2, where the first power P1 is less than the second power P2, specifically: first power P1 ≤ second power P2 × 0.1.
[0158] More specifically, according to step S09, an instance is simulated, and the following parameters are set:
[0159] In power-saving mode, the power consumption of timer unit 20 is 0W; the power consumption of DMA unit is 0W; the power consumption of logic control unit 30 is 0.1W; and the total power consumption is 0.1W. After exiting power-saving mode, the power consumption of timer unit 20 is 0.5W; the power consumption of DMA unit is 0.3W; the power consumption of logic control unit 30 is 1W; and the total power consumption is 1.8W.
[0160] Motor 400 starts rotating, the rotor drives the permanent magnet to rotate and generates a change in magnetic field. Hall sensor 200 detects the change in magnetic field and outputs an electrical signal, which enters the ADC. The electrical signal output by Hall sensor 200 is 2.5V, and the ADC converts the 2.5V electrical signal into a digital signal 512. The 512 is transmitted as an interrupt signal to the logic unit. The logic control unit 30 receives the interrupt signal and executes the interrupt control function. Timer unit 20 is powered on again, with a power consumption of 0.5W; DMA unit is powered on again, with a power consumption of 0.3W; logic control unit 30 switches from the first power mode (0.1W) to the second power mode (1W).
[0161] Therefore, this invention obtains a commutation table 10 containing control parameters corresponding to each temperature by testing and running the motor 400 at various temperatures, and drives the motor 400 to operate at various temperatures based on these control parameters. The accuracy of the control parameters at different temperatures is determined by comparing the speed error E and the error threshold S. By executing a cyclic program with the motor 400, the commutation table 10 and control parameters are continuously optimized, enabling the motor 400 to be suitable for different temperature conditions.
[0162] This specific embodiment also provides a system for a hollow cup DC motor 400, the system being used to implement the above-described adaptive method for the hollow cup DC motor 400.
[0163] The system includes:
[0164] Logic control module: used to interrupt the power management unit 70 and implement adaptive function.
[0165] Power management module: used to provide power to each unit of motor 400, and has a power saving mode that is activated when motor 400 stops.
[0166] Timer module: Used to capture the electrical signal from Hall sensor 200 and to set the PWM duty cycle to regulate the speed of motor 400.
[0167] Analog-to-digital converter module: Used to convert electrical signals into digital signals so that each module can operate normally.
[0168] Judgment module: Used to determine whether the speed error E needs to be calculated and whether the third control parameter is available.
[0169] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0170] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.
Claims
1. An adaptive method for a coreless DC motor, based on a microcontroller connected to the motor, wherein the microcontroller stores a commutation table, characterized in that: The commutation table is provided with a power-on sequence, a digital signal and a control parameter, and the method comprises the steps of: Test and operate the motor at various temperatures, obtain the control parameters corresponding to each temperature, obtain the corresponding power-on sequence in the commutation table based on the control parameters, and the logic control unit energizes each winding of the motor in turn according to the power-on sequence; Each winding of the motor is powered on and started. The motor's rotor drives the permanent magnet to rotate and generate magnetic field changes. The Hall sensor detects the magnetic field changes and continuously outputs electrical signals according to the magnetic field changes. The microcontroller continuously reads the digital signal corresponding to the electrical signal through the timer unit; The logic control unit retrieves the commutation table according to the digital signal and obtains a control signal; The advanced timer unit sets the PWM duty cycle according to the control signal and adjusts the motor speed through the PWM duty cycle; According to the control signal, the speed control unit calculates the speed error E; An error threshold S is set in the logic control unit. If the relationship: E≥S is satisfied, the logic control unit executes the loop program, continuously generates new control parameters, and continuously compares the speed error E and the error threshold S according to the control parameters until the relationship: E<S is satisfied. Then the logic control unit jumps out of the loop program and retains the control parameters in the current loop.
2. The self-adaptive method of a coreless DC motor according to claim 1, characterized in that: The commutation table also has commutation steps, and each commutation step has a corresponding power-on sequence; Among them, the motor runs according to the power-on sequence and the commutation steps, the temperature sensor obtains the temperature T1 when the motor is running, and the temperature sensor is set with a critical temperature T2. When T1<T2, the motor runs stably; when T1≥T2, the efficiency of the motor operation is reduced.
3. The self-adaptive method of a coreless DC motor according to claim 2, characterized in that: If the motor operating efficiency decreases, the logic control unit increases the control parameter, and according to the control parameter, the corresponding power-on sequence in the commutation table changes; When the motor is running stably, the commutation table obtains and saves the control parameters and power-on sequence corresponding to the current temperature.
4. The self-adaptive method of a coreless DC motor according to claim 1, characterized in that: If the commutation table records a power-on sequence that matches the digital signal, the logic control unit obtains a first control signal according to a control parameter corresponding to the digital signal; If the commutation table does not record a power-on sequence that matches the digital signal, the logic control unit adds a second control parameter, updates the commutation table, and obtains the second control signal according to the newly added control parameter.
5. The self-adaptive method of a coreless DC motor according to claim 4, characterized in that: When the control signal is the first control signal, the power-on sequence preset in the commutation table is executed. When the control signal is the second control signal, the second control signal is transmitted to the speed control unit through the advanced timer unit. The speed control unit obtains the set speed and the actual speed, and calculates the speed error E according to the set speed S1 and the actual speed S2, and satisfies the relationship: E = |S1-S2|; Among them, if E<S, the logic control unit retains the second control parameter and saves the current commutation table; if E≥S, the logic control unit deletes the second control parameter and adds a third control parameter. The logic control unit obtains a third control signal according to the third control parameter and transmits it to the advanced timer unit. The advanced timer unit resets the PWM duty cycle through the third control signal and adjusts the actual speed S2 of the motor according to the PWM duty cycle; and determines whether the third control parameter is available based on the actual speed S2 adjusted by the third control signal.
6. The self-adaptive method of a coreless DC motor according to claim 1, characterized in that: The timer unit includes a universal timer unit, through which the microcontroller obtains the electrical signal of the Hall sensor, and the electrical signal is converted into a digital signal through the analog-to-digital conversion unit and transmitted to the timer unit; The control parameters and the set speed are stored in the peripheral memory, wherein the direct memory access unit supports data transmission between the microcontroller and the peripheral device by skipping the processor, the speed control unit obtains the set speed through the direct memory access unit, and the logic control unit obtains the control parameters through the direct memory access unit.
7. The self-adaptive method of a coreless DC motor according to claim 1, characterized in that: The method further comprises the steps of: If the motor stops, the power management unit triggers the power saving mode, the timer unit and the direct memory access unit are powered off, and the logic control unit operates at the first power P1.
8. The self-adaptation method of a coreless DC motor according to claim 7, characterized in that: If the motor starts, the Hall sensor outputs an electrical signal, and the electrical signal enters the analog-to-digital conversion unit, which converts the electrical signal into an interrupt signal and transmits it to the logic control unit. According to the interrupt signal, the logic control unit interrupts the power saving mode of the power management unit and clears the interrupt signal. By interrupting the power saving mode, the power-off components are powered on again. After the power-on mode is restored, the logic control unit operates at the second power P2 and satisfies the relationship: P1≤P2×0.
1.
9. The self-adaptive method of a coreless DC motor according to claim 1, characterized in that: The higher the PWM duty cycle, the higher the proportion of voltage received by the motor and the faster the motor speed; The lower the PWM duty cycle, the lower the voltage ratio received by the motor, and the slower the motor speed; When the duty cycle is 0%, the motor is powered off, and the speed gradually decreases and eventually stops.
10. A system of a coreless DC motor, the system implementing the self-adaptation method of a coreless DC motor as claimed in any one of claims 1 to 9.
Citation Information
Patent Citations
Position sensor-free double closed-loop speed regulation control method for brushless DC motor
CN103248294A
Method and system for controlling brushless direct current motor of electric vehicle
CN103490681A
Self-adaptive and / or self-tunable control system for DC brushless motor parameters and method thereof
CN107947662A
Refrigeration cycle device
JP1996285388A
