Stepper motor control method and controller for vacuum valve
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHENZHEN HUAXIN SEMICON EQUIP TECH CO LTD
- Filing Date
- 2026-07-06
- Publication Date
- 2026-07-31
AI Technical Summary
[0002]目前真空阀中步进电机电流监测与保护方案主要采用固定阈值二值化判断机制,仅能实现关断与复位两种简单响应,依赖被动式热敏电阻器件,热响应存在数秒至数十秒的滞后性,故障发生时无法及时切断电流,易造成电机绕组烧毁与机械结构损坏
[0006]本申请解决了现有技术无法区分正常冲击电流与故障电流的问题,通过实时电流采样与分级保护机制,大幅降低误触发概率,提升系统运行稳定性。同时突破了传统被动热保护的响应滞后缺陷,实现故障电流的毫秒级检测与保护动作,有效避免电机过热烧毁与机械卡滞损坏。通过建立了待机与运动状态的差异化控制逻辑,在运动状态下保证电机额定力矩输出,满足真空阀快速响应要求,同时解决了待机状态下的能耗过高问题,实现安全性与能效性的平衡。简化了硬件保护电路设计,通过软件算法实现多级保护功能,降低系统硬件成本与复杂度。
Smart Images

Figure CN122495908A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of motor control technology, and in particular to a stepper motor control method and controller for a vacuum valve. Background Technology
[0002] Currently, the current monitoring and protection schemes for stepper motors in vacuum valves mainly adopt a fixed threshold binary judgment mechanism, which can only achieve two simple responses: shutdown and reset. Relying on passive thermistor devices, the thermal response has a lag of several seconds to tens of seconds. When a fault occurs, the current cannot be cut off in time, which can easily cause the motor windings to burn out and the mechanical structure to be damaged. Summary of the Invention
[0003] This application provides a stepper motor control method and controller for a vacuum valve, aiming to solve the problems existing in current stepper motor current monitoring and protection schemes.
[0004] In a first aspect, embodiments of this application provide a stepper motor control method for a vacuum valve, including: The system acquires motion commands sent from an external host computer and obtains the position increment encoding signal of the corresponding valve plate of the vacuum valve. Based on the motion commands and the position increment encoding signal, the system determines the current operating status of the vacuum valve. If the vacuum valve is determined to be in motion based on the current operating status, control the stepper motor to operate at the preset rated power; During the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal of the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage. The protection action corresponding to the stepper motor is determined based on the current amplitude signal, instantaneous current signal, and short-circuit trigger signal, and then the protection action is executed.
[0005] In a second aspect, this application provides a controller, including a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program and, when executing the computer program, implement the method as provided in the first aspect.
[0006] This application solves the problem of existing technologies being unable to distinguish between normal inrush current and fault current. Through real-time current sampling and a graded protection mechanism, it significantly reduces the probability of false triggering and improves system operational stability. Simultaneously, it overcomes the response lag defect of traditional passive thermal protection, achieving millisecond-level detection and protection action for fault current, effectively preventing motor overheating and burnout, as well as mechanical jamming damage. By establishing differentiated control logic for standby and operating states, it ensures the rated torque output of the motor in operating state, meeting the rapid response requirements of the vacuum valve, while simultaneously solving the problem of excessive energy consumption in standby state, achieving a balance between safety and energy efficiency. The hardware protection circuit design is simplified, and multi-level protection functions are implemented through software algorithms, reducing system hardware costs and complexity.
[0007] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Attached Figure Description
[0008] To more clearly illustrate the technical solutions of the embodiments of this application, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0009] Figure 1 This is a schematic flowchart illustrating the steps of a stepper motor control method for a vacuum valve according to an embodiment of this application; Figure 2 This is a schematic block diagram of a control system provided in one embodiment of this application; Figure 3 This is a schematic diagram of a graded response principle provided in an embodiment of this application; Figure 4 This is a circuit schematic diagram of a current signal acquisition circuit provided in one embodiment of this application; Figure 5 This is a schematic block diagram of a controller provided in one embodiment of this application; Figure 6 This is a schematic block diagram of another controller provided in one embodiment of this application.
[0010] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and do not limit this application. Detailed Implementation
[0011] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0012] The flowchart shown in the attached diagram is for illustrative purposes only and does not necessarily include all content and operations / steps, nor does it necessarily have to be performed in the order described. For example, some operations / steps can be broken down, combined, or partially merged, so the actual execution order may change depending on the actual situation.
[0013] It should be understood that, in order to clearly describe the technical solutions of the embodiments of the present invention, the terms "first" and "second" are used in the embodiments of the present invention to distinguish identical or similar items with essentially the same function and effect. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and the terms "first" and "second" are not necessarily different.
[0014] It should be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the scope of the application. As used in this specification and the appended claims, the singular forms “a,” “an,” and “the” are intended to include the plural forms unless the context clearly indicates otherwise.
[0015] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0016] Currently, the current monitoring and protection schemes for stepper motors in vacuum valves mainly adopt a fixed threshold binary judgment mechanism, which can only achieve two simple responses: shutdown and reset. Relying on passive thermistor devices, the thermal response has a lag of several seconds to tens of seconds. When a fault occurs, the current cannot be cut off in time, which can easily cause the motor windings to burn out and the mechanical structure to be damaged.
[0017] Please refer to Figure 1 This application provides a stepper motor control method for a vacuum valve. The vacuum valve can be a butterfly valve, gate valve, or other valve with a valve plate structure, and the type of vacuum valve is not limited.
[0018] In some embodiments, combined with Figure 2 and Figure 3 The hardware system upon which this method is based will be described.
[0019] like Figure 2As shown, the control system includes a communication module, a controller, a drive module, and a stepper motor housed within the vacuum valve. The communication module is connected to the controller and an external application terminal for bidirectional transmission of control commands and status data. The controller is the core control unit of the system; its output is connected to the control terminal of the drive module to output drive timing signals and protection control signals. The power output terminal of the drive module is connected to the windings of the stepper motor to output drive current to the stepper motor. The output shaft of the stepper motor is connected to the valve plate of the vacuum valve to drive the valve plate to rotate and adjust the valve opening.
[0020] like Figure 3 As shown, the drive module has a built-in current sampling circuit, which adopts a high-side and low-side dual current sensing architecture, specifically including a high-side current sensing resistor, a low-side current sensing resistor, and a high-speed operational amplifier unit. The high-side current sensing resistor is connected in series on the high-potential side of the stepper motor winding power supply circuit to collect the short-circuit detection voltage under abnormal winding insulation scenarios; the low-side current sensing resistor is connected in series on the low-potential side of the stepper motor winding power supply circuit to collect the operating current signal of the motor throughout its entire operating cycle. The high-speed operational amplifier unit includes two independent signal processing branches: the first is a current amplitude output branch, which differentially amplifies the signal collected by the low-side current sensing resistor and outputs a current amplitude analog signal proportional to the instantaneous current signal; the second is a short-circuit trigger output branch, which has a built-in threshold detection network with hysteresis interval, performs threshold comparison and debouncing processing on the voltage signal collected by the high-side current sensing resistor, and outputs a stable short-circuit trigger switch signal. The above-mentioned current amplitude analog signal is connected to the analog-to-digital converter interface of the controller, and the short-circuit trigger switch signal is connected to the high-speed interrupt interface of the controller.
[0021] like Figure 4 As shown, the drive module has a built-in current signal acquisition circuit and adopts a dual-branch architecture that decouples low-side precision sampling and high-side fault detection. Specifically, it includes three parts: a current detection module, an overcurrent detection module, and a reference voltage module.
[0022] The current detection module is connected in series on the low side of the corresponding drive circuit of the stepper motor. It is used to collect and amplify the current signal on the low side and output a high-precision motor current detection signal for the current closed-loop control, overcurrent classification judgment and stall identification of the stepper motor. The overcurrent detection module is connected in series on the high side of the drive circuit. It is used to collect the current signal on the high side and output a short-circuit trigger signal to realize independent and rapid detection of abnormal faults such as short circuit to ground of motor windings. The reference voltage module is connected to the current detection module and the overcurrent detection module respectively, and provides the same reference source for the two circuits to ensure that the reference temperature drift characteristics of the two circuits are consistent and to avoid measurement errors and threshold offsets caused by different reference references.
[0023] The provided stepper motor control method for the vacuum valve includes steps S101 to S104. Details are as follows: Step S101. Obtain the motion command sent by the external host computer and obtain the position increment code signal of the valve plate corresponding to the vacuum valve. Determine the current operating status of the vacuum valve based on the motion command and the position increment code signal.
[0024] Specifically, this step is used to identify the operating mode of the vacuum valve, providing a basis for subsequent control strategy switching.
[0025] In practice, the controller collects two types of input signals in real time. The first type is external command signals, which are control commands such as valve opening and closing commands, opening adjustment commands, and standby commands issued by external application terminals through the communication module. The controller then parses the target parameters and execution requirements contained in the commands, such as the target opening degree, running speed, and direction of movement. The second type is position feedback signals, which are position increment encoded signals linked to the valve plate shaft through the encoder interface. The real-time position, rotation direction, and rotation speed of the valve plate are obtained through pulse counting and phase detection.
[0026] The controller combines two types of signals for comprehensive judgment: when there is a valid motion command and the command has not been completed, or when the position increment encoding signal shows that the valve plate is in a continuous rotation state, the vacuum valve is determined to be in motion state; when there is no valid motion command, and the position increment encoding signal has no valid pulse output within the preset judgment time and the valve plate maintains a fixed opening, the vacuum valve is determined to be in a static standby state.
[0027] For example, the specific logic for determining the current operating status of the vacuum valve includes: First, the controller acquires motion commands sent from an external host computer. The controller listens in real-time to command frames sent from the external application terminal via the communication module, verifies and parses the command frames to identify whether the command type is a motion command or a standby command, and parses parameters such as the target opening, running speed, and direction of motion.
[0028] Secondly, the position increment encoding signal of the valve plate corresponding to the vacuum valve is obtained. The controller acquires two pulse signals output by the quadrature encoder connected to the valve plate shaft through the incremental encoder interface. By pulse counting and phase detection calculation, the real-time position, rotation direction and position increment per unit time of the valve plate are obtained.
[0029] Finally, the current operating status of the vacuum valve is determined based on the motion command and position increment encoding signal. The specific determination rules include, but are not limited to: If a valid motion command is received and the command has not yet been completed, it is determined to be in motion state regardless of whether the valve plate is displaced. This ensures that the motor can reach the rated torque level during the command response phase and avoids insufficient torque during the start-up phase. If no motion command is received, but the position increment encoding signal has a valid pulse output within multiple consecutive sampling periods, it indicates that the valve plate is in an inertial rotation or external force driven state, which is also judged as a motion state to avoid the failure of the protection mechanism in non-active motion scenarios. If no motion command is received and the position increment encoding signal does not have a valid pulse output within the preset judgment time, and the valve plate remains in a fixed position, it is judged to be in a static standby state.
[0030] By using dual-signal judgment logic, active and passive motion states can be accurately identified, avoiding control strategy errors caused by misjudgment of state and improving system reliability.
[0031] Step S102. If it is determined that the vacuum valve is in motion based on the current operating status, control the stepper motor to operate at the preset rated power.
[0032] Specifically, this step is used to ensure that the stepper motor outputs sufficient torque during the valve's operation, so as to avoid the energy efficiency optimization strategy affecting the valve's response speed and load-bearing capacity.
[0033] When the system is determined to enter motion state, the controller first immediately releases the current derating limit applied in the static standby state, restores the amplitude of the reference current control signal to the preset rated reference value, so that the maximum current that the drive module can output reaches the rated peak level of the motor.
[0034] Subsequently, the controller calculates the real-time speed of the stepper motor based on the position increment encoding signal, compares the real-time speed with the pre-stored speed range threshold to determine the current speed range, and retrieves the pre-stored correspondence between speed ranges and control modes to match the corresponding drive control mode. The micro-step control mode refers to a drive method that uses sinusoidal subdivision control of the motor winding current to break down the stepper motor's inherent full step angle into multiple micro-step angles, resulting in smoother motor operation and lower vibration and noise. The full-step control mode refers to a drive method that switches the winding energization state in units of the motor's inherent full step angle, resulting in greater output torque and faster response speed. When the motor is in the low-speed operating range, the micro-step control mode is used to reduce operating vibration and noise; when the motor is in the medium-to-high speed operating range, it switches to the full-step control mode to ensure output torque and response speed.
[0035] The controller generates a corresponding timing SPWM drive signal based on the matched control mode and outputs it to the drive module. The drive module controls the stepper motor to run smoothly at rated power, driving the valve plate to complete the specified opening / closing or opening degree adjustment action.
[0036] Step S103. During the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal of the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage.
[0037] Specifically, this step is used to achieve high-precision, high-response-speed real-time acquisition of motor current, providing an accurate data foundation for subsequent graded protection determination.
[0038] The specific sampling process is divided into two parallel signal processing branches: Current Amplitude and Instantaneous Current Sampling Branch: The low-side current sensing resistor converts the instantaneous current in the motor winding circuit into a millivolt-level voltage signal. This signal is input to a differential amplifier circuit composed of a high-speed operational amplifier. The differential structure suppresses common-mode interference such as power supply ground noise and common impedance coupling, accurately amplifying the weak voltage signal and outputting an analog signal of the current amplitude that is linearly related to the instantaneous current signal. The controller periodically samples and converts this analog signal to digital data via a built-in high-speed ADC interface. The sampling frequency is no less than 1kHz, and the conversion accuracy is no less than 12 bits, obtaining a digitized instantaneous current sample value. The average amplitude of the motor current is obtained by performing a moving average calculation on the instantaneous current values over multiple consecutive sampling periods.
[0039] Short-circuit detection branch: The high-side current sensing resistor collects the voltage signal from the high-potential side of the power supply circuit and inputs this signal to a high-speed threshold detection circuit with a hysteresis interval. When abnormal faults such as insulation damage or inter-turn short circuits occur in the motor windings, an unexpected short-circuit current path is formed, and the voltage on the high-side current sensing resistor rises rapidly. When the voltage exceeds the preset upper threshold, the threshold detection circuit flips and outputs a valid short-circuit trigger signal. When the fault is cleared and the voltage falls back below the lower threshold, the circuit resets and outputs an invalid signal. The hysteresis interval effectively eliminates false triggers caused by current spikes and electromagnetic interference, ensuring the stability and reliability of the short-circuit detection signal. This short-circuit trigger signal is directly connected to the controller's high-speed I / O interrupt interface, enabling microsecond-level short-circuit event response.
[0040] For example, the current amplitude and instantaneous current sampling branches adopt a differential amplification architecture. The low-side current sensing resistor converts the instantaneous current of the motor winding circuit into a millivolt-level voltage signal, which is then input to the differential amplification unit for differential amplification. The potential difference between the power ground of the drive circuit and the signal ground of the sampling circuit caused by common impedance coupling will appear simultaneously at the two input terminals of the differential amplification unit as a common-mode signal, thus canceling each other out. This can effectively suppress common-mode interference commonly found in industrial environments, such as ground bounce and crosstalk, and improve the signal-to-noise ratio of current sampling.
[0041] Since the hardware front end has suppressed most of the interference through differential filtering, there is no need to use low-pass filtering with a large time constant. The bandwidth of this sampling branch can reach more than 100kHz, which can realize microsecond-level current signal acquisition, meet the real-time requirements of high-speed motion control of stepper motors, and avoid control oscillation and adjustment lag caused by filtering delay.
[0042] The controller performs periodic sampling and analog-to-digital conversion on the analog signal through the built-in high-speed ADC interface. The sampling frequency is not less than 1kHz and the conversion accuracy is not less than 12 bits to obtain the digitized instantaneous current sample value. The average amplitude of the motor current can be obtained by performing a moving average calculation on the instantaneous current values of multiple consecutive sampling periods.
[0043] For example, the short-circuit detection branch is an independent hardware threshold detection channel, and its operation is not affected by interference from the main sampling channel, thus forming a redundant protection mechanism. The high-side current sensing resistor collects the voltage signal from the high-potential side of the power supply circuit, which is attenuated to an appropriate voltage by a voltage divider network and then input to a voltage comparison unit with hysteresis feedback for comparison with a reference threshold. The hysteresis feedback design provides the comparison unit with two different thresholds for triggering and de-triggering, forming a hysteresis width. This effectively eliminates false triggering caused by current spikes and electromagnetic interference, avoiding repeated alarm and de-triggering oscillations at critical current positions.
[0044] The short-circuit detection branch is also equipped with a clamping protection device, which can clamp the input pins of the comparator unit for overvoltage, discharge transient interference energy such as electrostatic discharge and surges, improve the circuit's EMC immunity, and adapt to the complex electromagnetic environment of industrial sites. The short-circuit trigger signal is directly connected to the controller's high-speed IO interrupt interface, enabling microsecond-level short-circuit event response.
[0045] The reference voltage module uses a high-precision reference voltage source and outputs two reference voltages from the same source: one provides a reference voltage for the current detection module, setting the static operating point of the differential amplifier unit at the midpoint of the power supply voltage to achieve conditioning of the bipolar current signal under single power supply; the other provides a threshold reference voltage for the overcurrent detection module to ensure the accuracy and stability of the fault detection threshold.
[0046] Since the two reference voltages are output from the same source, their temperature drift characteristics are consistent, which can avoid measurement errors and threshold shifts caused by different reference sources, and improve the reliability of the circuit in a wide temperature industrial environment of -40℃ to 85℃.
[0047] Step S104. Determine the corresponding protection action for the stepper motor based on the current amplitude signal, instantaneous current signal and short-circuit trigger signal, and execute the protection action.
[0048] Specifically, this step is the core of the hierarchical protection logic. The controller matches the corresponding protection level and protection action based on the collected current amplitude data, instantaneous current data and short-circuit trigger signal to achieve hierarchical closed-loop safety control.
[0049] In practice, the controller's storage unit pre-stores a mapping table of multiple current threshold levels and corresponding protection actions. The controller compares the calculated average amplitude of the motor current with each threshold level sequentially, and combines this with the instantaneous current characteristics and the short-circuit trigger signal status to determine the current protection level and execute the corresponding protection action.
[0050] The protection levels are divided into four levels in order of severity from low to high: the first warning level, the second current limiting level, the third severe overcurrent level, and the fourth short circuit level. Different levels correspond to different levels of intervention measures to maintain the continuity of system operation to the greatest extent possible while ensuring equipment safety.
[0051] While performing protection actions, the controller synchronously records the time of the fault occurrence, current value, protection level and action type, generates an operation event log, and can report it to an external application terminal through the communication module.
[0052] In some embodiments, if it is determined that the vacuum valve is in motion based on the current operating state, controlling the stepper motor to operate at a preset rated power includes: removing the current derating limit on the stepper motor; obtaining the current speed range of the stepper motor; obtaining the mapping relationship between the preset speed range and the control mode; determining the corresponding control mode in the mapping relationship based on the current speed range; and controlling the stepper motor to operate at rated power according to the control mode.
[0053] The specific implementation process of controlling a stepper motor to operate at a preset rated power during motion includes: The first step is to remove the current derating limit on the stepper motor. When the system switches from a static standby state to a motion state, the controller immediately cancels the reference current derating parameter in the standby state and restores the amplitude of the reference current control signal to the preset rated reference value, so that the peak value of the motor current output by the drive module can reach the rated peak level, ensuring the full torque output of the motor.
[0054] The second step is to obtain the current speed range of the stepper motor. The controller calculates the real-time speed of the stepper motor based on the number of pulses of the position increment encoding signal per unit time, and compares the real-time speed with the pre-stored multi-speed range thresholds to determine the current speed range.
[0055] The third step is to obtain the preset mapping relationship between speed range and control mode. The controller's storage unit is pre-configured with a mapping table corresponding to speed range and control mode. For example, the low speed range (such as 0 to 30% of the rated speed) corresponds to the micro-step control mode, and the medium and high speed range (such as 30% to 100% of the rated speed) corresponds to the full-step control mode.
[0056] The fourth step is to determine the corresponding control mode in the mapping relationship based on the current speed range.
[0057] The fifth step involves controlling the stepper motor to operate at its rated power according to the control mode. The controller generates drive pulse timing signals with corresponding microstepping based on the selected control mode and outputs them to the drive module, which then drives the stepper motor.
[0058] By switching between speed adaptive control modes, the smoothness of low-speed operation and the torque performance of high-speed operation can be balanced, enabling the motor to achieve optimal operating performance at rated power.
[0059] In some embodiments, during the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal corresponding to the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage. This includes: acquiring the current sampling signal through a low-side current sensing resistor, performing differential amplification on the current sampling signal; converting the differentially amplified current sampling signal into a digital signal, obtaining the instantaneous current signal based on the digital signal, and calculating the current amplitude signal from the instantaneous current signal of a continuous sampling period; acquiring the short-circuit detection voltage signal through a high-side current sensing resistor, inputting the short-circuit detection voltage signal into a threshold detection circuit with a hysteresis interval, and generating a debouncing short-circuit trigger signal.
[0060] The specific process of motor current sampling and signal processing includes: The first step involves acquiring a current sampling signal through a low-side current sensing resistor, followed by differential amplification. The low-side current sensing resistor is a high-precision milliohm-level sampling resistor connected in series in the power supply ground loop of the motor windings. When the motor running current flows through the resistor, it generates a weak voltage signal proportional to the current amplitude. This voltage signal is input to a differential amplifier circuit composed of a high-speed operational amplifier. The differential structure effectively suppresses common-mode interference such as power supply ground noise and common impedance coupling. The amplified signal is an analog voltage signal linearly corresponding to the instantaneous current signal.
[0061] The second step involves converting the differentially amplified current sampling signal into a digital signal. Based on this digital signal, an instantaneous current signal is obtained, and the current amplitude signal is calculated from the instantaneous current signal over a continuous sampling period. The controller uses its built-in high-speed ADC channel to periodically sample and convert the amplified analog current amplitude signal to digital values. Then, multiple instantaneous current sampling values within a sliding time window are averaged to obtain the average amplitude of the motor current, which is used for threshold comparison in subsequent graded protection.
[0062] The third step involves acquiring the short-circuit detection voltage signal through the high-side current sensing resistor. This signal is then input to a threshold detection circuit with a hysteresis range to generate a debounced short-circuit trigger signal. The high-side current sensing resistor is connected in series with the positive terminal of the motor winding power supply. When abnormalities such as insulation damage or inter-turn short circuits occur in the motor windings, an unexpected large current path is generated, causing the voltage across the high-side current sensing resistor to rise rapidly. This voltage signal is input to a high-speed comparator with a built-in hysteresis network. When the voltage exceeds the upper threshold, the comparator outputs a high-level short-circuit trigger signal; when the voltage falls back below the lower threshold, the comparator resets and outputs a low-level signal. The hysteresis range prevents false triggering caused by current spikes and electromagnetic interference, ensuring the reliability of the short-circuit signal.
[0063] The dual-branch sampling architecture enables high-precision current amplitude monitoring and fast and reliable short-circuit fault identification simultaneously, providing accurate input signals for graded protection.
[0064] For example, the specific circuit structure for motor current sampling and signal processing is as follows: Figure 4 As shown, the specific working process includes: The low-side current sensing branch consists of the low-side current sensing resistor R5 and the differential amplifier unit. The low-side current sensing resistor R5 is a high-precision, low-temperature-drift alloy resistor, connected in series between the low-potential end of the stepper motor winding and the system ground terminal. Its resistance accuracy is controlled within ±0.1%, and its temperature drift coefficient is less than 25ppm / ℃, ensuring long-term stability and temperature adaptability of the current sampling. The resistance value can be selected between 50mΩ and 100mΩ, allowing the voltage drop generated under rated current to match the input dynamic range of the differential amplifier unit, ensuring sampling accuracy while avoiding excessive power loss.
[0065] The differential amplifier unit consists of a first operational amplifier of the dual operational amplifier chip U1 and an external resistor network, including a first resistor R1, a second resistor R2, a third resistor R3, and a fourth resistor R4. One end of the first resistor R1 is connected to the ground terminal of the low-side current sensing resistor R5, and the other end is connected to the inverting input terminal INNA of the first operational amplifier. One end of the second resistor R2 is connected to the connection terminal between the low-side current sensing resistor R5 and the motor winding, and the other end is connected to the non-inverting input terminal INPA of the first operational amplifier. The third resistor R3 is connected between the inverting input terminal INNA and the output terminal OUTA of the first operational amplifier, forming a negative feedback loop used to set the circuit gain. The fourth resistor R4 is connected between the output terminal Vref of the reference voltage module and the non-inverting input terminal INPA of the first operational amplifier, used to match the gain parameters of the differential amplifier circuit, and at the same time to provide a static operating point reference for the operational amplifier.
[0066] To ensure the common-mode rejection capability of the differential amplifier circuit, the first resistor R1 and the second resistor R2 have equal resistance values, and the third resistor R3 and the fourth resistor R4 have equal resistance values, with the resistance tolerance controlled within ±1%. The circuit gain is determined by the ratio of the resistance values of the third resistor R3 to the first resistor R1. The reference voltage output by the reference voltage module is half the operating power supply voltage of the operational amplifier, setting the quiescent operating point of the operational amplifier at the midpoint of the power supply voltage, thus achieving conditioning of the bipolar current signal under single-supply operation.
[0067] When a forward current (current flowing from the motor windings to ground) is detected, the potential at the low-side current sensing resistor R5 and the winding connection terminal is higher than that at the ground terminal, the potential at the non-inverting input terminal of the first operational amplifier is higher than that at the inverting input terminal, and the output voltage is higher than the reference voltage. When a reverse current (current flowing from ground to the motor windings) is detected, the potential at the ground terminal is higher than that at the winding connection terminal, the potential at the inverting input terminal of the operational amplifier is higher than that at the non-inverting input terminal, and the output voltage is lower than the reference voltage. The output voltage has a linear relationship with the motor winding current and can be directly fed into the controller's analog-to-digital converter interface.
[0068] The high-side overcurrent detection branch consists of a high-side current sensing resistor R6, a voltage divider module, a clamping protection module, a voltage comparison unit, and a hysteresis feedback unit.
[0069] The high-side current sensing resistor R6 is connected in series between the positive terminal V1 of the drive power supply and the high-potential terminal of the stepper motor winding. To improve the sensitivity of short-circuit fault detection, its resistance is higher than that of the low-side current sensing resistor R5. Under short-circuit fault conditions, it can generate a sufficiently large voltage change, which is convenient for the voltage comparison unit to detect. The high-side current sensing resistor R6 also uses a high-precision, low-temperature drift alloy resistor, and its rated power is selected to withstand the large current impact during short-circuit faults.
[0070] The voltage divider module consists of a seventh resistor R7 and an eighth resistor R8 connected in series. Its input is connected to the junction of the high-side current sensing resistor R6 and the motor winding, and its output is connected to the inverting input INNB of the second operational amplifier. The voltage divider module proportionally attenuates the high-voltage signal on the high-side to a voltage range that the operational amplifier can withstand, thus matching the input voltage range of the operational amplifier.
[0071] The clamping protection module consists of a clamping diode D1. The cathode of the clamping diode D1 is connected to the inverting input INNB of the second operational amplifier, and the anode is connected to the system ground. When an abnormal negative overvoltage signal, electrostatic discharge, or surge transient interference occurs at the inverting input, the clamping diode D1 conducts forward, clamping the voltage at the inverting input near the forward voltage drop of the diode. This dissipates the transient interference energy, prevents negative overvoltage from damaging the input stage of the operational amplifier, and improves the EMC immunity of the circuit.
[0072] The hysteresis feedback unit consists of resistors R9 (ninth), R10 (tenth), and R11 (eleventh). Resistor R9 is connected between the output of the reference voltage module and the non-inverting input INPB of the second operational amplifier. Resistor R10 is connected between the non-inverting input INPB and the system ground. Resistor R11 is connected between the output OUTB of the operational amplifier and the non-inverting input INPB. These three sets of resistors together form a hysteresis feedback network, providing the voltage comparison unit with two different threshold voltages: a fault trigger threshold and a fault clear threshold, thus creating the hysteresis width. The hysteresis width can be set between 4mV and 8mV according to application requirements, balancing anti-interference capability and detection sensitivity. It effectively suppresses false triggering caused by circuit noise and avoids alarm oscillations at critical current points.
[0073] When the motor is driven normally, the voltage between the high-side current sensing resistor R6 and the winding connection node fluctuates slightly with the operating current. After voltage division, the voltage input to the inverting input of the second operational amplifier is higher than the fault trigger threshold of the non-inverting input. The comparator outputs a low level and does not trigger a fault alarm.
[0074] When a short-circuit fault to ground occurs in the motor windings, the current flows directly from the drive power supply through the high-side current sensing resistor R6 and the short-circuit point to ground. The low-side sampling branch cannot detect this short-circuit current, but the high-side sampling branch can fully capture the short-circuit current. At this time, the voltage drop across the high-side current sensing resistor R6 increases significantly, and the voltage at the winding-side node drops rapidly. After voltage division, the voltage at the inverting input terminal is lower than the fault trigger threshold, causing the comparator output to flip to a high level and output a valid short-circuit trigger signal, triggering the short-circuit alarm.
[0075] After the fault is cleared, the motor current gradually decreases, the winding-side node voltage gradually increases, and the voltage at the inverting input terminal also increases accordingly. Due to the hysteresis characteristic, the comparator output will only flip to a low level and clear the fault alarm when the voltage rises to the fault clearance threshold. This design avoids signal oscillation under critical fault conditions and ensures detection stability.
[0076] like Figure 4 As shown, in this embodiment, the first operational amplifier and the second operational amplifier are integrated into the same dual operational amplifier chip U1, which can simplify the circuit layout and ensure the consistency of device parameters. The first operational amplifier and the second operational amplifier can also be set separately, which will not be described in detail in this embodiment.
[0077] This sampling architecture employs a decoupled design of low-side precision sampling and high-side threshold detection, breaking the traditional limitation that high reliability and low cost cannot be simultaneously achieved. The low-side sampling branch does not need to withstand high common-mode voltage, and can use ordinary-specification operational amplifiers to achieve high-precision, high-bandwidth current acquisition, significantly reducing the cost of the main sampling channel; the high-side sampling branch is only used for fault threshold detection and does not require high-precision linear sampling. The high-voltage signal is attenuated to the input range of ordinary operational amplifiers through a voltage divider network, and can also be implemented using low-cost devices.
[0078] In terms of reliability, the independent high-side detection channel provides redundant safety protection mechanisms for the system. Even if the main sampling channel malfunctions, the high-side overcurrent detection can still reliably trigger short-circuit protection. At the same time, the same reference voltage source ensures that the temperature drift characteristics of the two references are consistent, avoiding measurement errors and threshold shifts caused by temperature drift and parameter differences, and ensuring stable operation of the circuit in a wide-temperature industrial environment.
[0079] In some embodiments, determining and executing the protection action corresponding to the stepper motor based on the current amplitude signal, instantaneous current signal, and short-circuit trigger signal includes: comparing the current amplitude signal with multiple preset current thresholds; determining the corresponding protection level based on the comparison result, instantaneous current signal, and short-circuit trigger signal; the protection level includes a first warning level, a second current limiting level, a third severe overcurrent level, and a fourth short-circuit level; the current threshold corresponding to the first warning level is less than the current threshold corresponding to the second current limiting level, and the current threshold corresponding to the second current limiting level is less than the current threshold corresponding to the third severe overcurrent level; acquiring the protection action corresponding to each protection level; if the protection level is the first warning level, the protection action includes recording the current motor current data and running time; if the protection level is the second current limiting level, the protection action includes adjusting the reference current of the stepper motor to a preset ratio; if the protection level is the third severe overcurrent level, the protection action includes controlling the stepper motor to stop and outputting an interlock signal; if the protection level is the fourth short-circuit level, the protection action includes cutting off the stepper motor drive output and outputting fault information; acquiring the execution time and execution status of the protection action to complete the control of the stepper motor.
[0080] The specific logic of protection level determination and protection action execution includes: The first step is to compare the current amplitude signal with multiple preset current thresholds. The controller calculates the average amplitude of the motor current and compares it sequentially with the pre-stored multi-level rated current ratio thresholds. Each threshold is parameterized based on the motor's rated current, which can adapt to motors of different specifications.
[0081] The second step is to determine the corresponding protection level based on the comparison results, instantaneous current signal, and short-circuit trigger signal. The protection levels include a first warning level, a second current-limiting level, a third severe overcurrent level, and a fourth short-circuit level; wherein the current threshold corresponding to the first warning level is less than the current threshold corresponding to the second current-limiting level, and the current threshold corresponding to the second current-limiting level is less than the current threshold corresponding to the third severe overcurrent level.
[0082] Specific threshold setting examples include, but are not limited to: The first warning level trigger threshold is: the average current is greater than 1.1 times the rated current; The trigger threshold for the second current limiting level is: the average current is greater than 1.41 times the rated current; The third severe overcurrent level trigger threshold is: the average current is greater than twice the rated current and the duration exceeds the preset duration; The fourth short-circuit level trigger condition is determined by combining the instantaneous current change rate and the hardware short-circuit trigger signal.
[0083] The third step is to obtain the protection action corresponding to each protection level and execute the corresponding action: If the protection level is the first warning level, the current motor current data and running time are recorded, and the normal operation of the motor is not interfered with. This level is used for overcurrent trend prediction and operation data analysis. If the protection level is the second current limiting level, the reference current of the stepper motor is adjusted to a preset ratio. By reducing the reference current, the maximum output current of the motor is limited, thus preventing the motor from overheating and aging due to long-term full-load operation. If the protection level is the third severe overcurrent level, the stepper motor is controlled to stop and an interlock signal is output. The drive current is gradually reduced until the motor stops. At the same time, other related equipment in the system is notified to enter a safe state to prevent the fault from spreading. If the protection level is the fourth short-circuit level, the stepper motor drive output will be cut off and a fault message will be output. Power supply to the motor will be stopped immediately to prevent the fault from spreading and burning out the windings and drive circuit.
[0084] The fourth step is to obtain the execution time and status of the protection action to complete the control of the stepper motor. The controller records the trigger time, execution duration, and current status after the protection action, updates the system operation log, and completes the protection response process.
[0085] Through a four-level hierarchical protection mechanism, differentiated intervention strategies can be adopted for different levels of overcurrent and short circuit scenarios, taking into account both the continuity of system operation and the safety of equipment.
[0086] In some embodiments, after obtaining the execution time and execution status of the protection action and completing the control of the stepper motor, the method further includes: after executing the protection action, continuously monitoring the motor current of the stepper motor and updating the protection level; if the protection level is a first warning level or a second current limiting level, if the motor current recovers to the normal range within a preset time, automatically releasing the corresponding protection action; if the protection level is a third severe overcurrent level or a fourth short circuit level, maintaining the protection action until a manual reset command sent by an external terminal is received, so as to complete the reset operation of the stepper motor in response to the manual reset command.
[0087] The protection action is followed by a tiered recovery mechanism, the specific process of which includes: First, after executing the protection action, the stepper motor current is continuously monitored and the protection level is updated. The controller continuously collects current data in real time, re-compares the thresholds, and dynamically updates the current protection level.
[0088] Secondly, if the protection level is the first warning level or the second current limiting level, the corresponding protection action will be automatically released if the motor current returns to the normal range within a preset time.
[0089] Specifically, for the first warning level, when the current drops below 1.1 times the rated current, the warning record is automatically cleared and normal operation is restored. For the second current limiting level, when the current continues to drop to the normal range and maintains the preset recovery time, the reference current limit is gradually lifted, restoring to the rated reference value, thus achieving automatic recovery. If the current limiting state continues to exceed the preset timeout threshold and cannot be restored, hardware interlocking is triggered, and the system enters a locked state.
[0090] Finally, if the protection level is the third severe overcurrent level or the fourth short-circuit level, the protection will remain active until a manual reset command is received from an external terminal. The stepper motor will then be reset in response to the manual reset command. Severe overcurrent and short-circuit faults are high-risk faults. After the system triggers the protection, it will remain in a stopped and interlocked state and cannot automatically recover. Maintenance personnel must investigate the cause of the fault and send a manual reset command through an external terminal to deactivate the protection and restore system operation.
[0091] The tiered recovery mechanism enables adaptive recovery from minor faults and secure locking of severe faults, balancing ease of operation and maintenance with system security.
[0092] In some embodiments, if the corresponding protection level is any one of a first warning level, a second current limiting level, or a third severe overcurrent level, the corresponding protection level is determined based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal, including: comparing the current amplitude signal with a preset first warning current threshold, a second current limiting current threshold, and a third overcurrent current threshold, respectively; wherein the first warning current threshold is less than the second current limiting current threshold, and the second current limiting current threshold is less than the third overcurrent current threshold; if the current amplitude signal is greater than or equal to the first warning current threshold and less than the second current limiting current threshold, the protection level is determined to be the first warning level; or, if the current amplitude signal is greater than or equal to the second current limiting current threshold and less than the third overcurrent current threshold, the protection level is determined to be the second current limiting level; or, if the current amplitude signal is greater than or equal to the third overcurrent current threshold, and the duration of the current amplitude signal being greater than or equal to the third overcurrent current threshold exceeds a preset overcurrent determination duration, the protection level is determined to be the third severe overcurrent level.
[0093] The controller is pre-configured with three levels of current judgment thresholds: a first warning current threshold, a second current-limiting current threshold, and a third overcurrent current threshold. The first warning current threshold is lower than the second current-limiting current threshold, and the second current-limiting current threshold is lower than the third overcurrent current threshold. Each threshold is parameterized based on the stepper motor's rated current and can be flexibly adjusted according to motor specifications and load conditions.
[0094] As exemplary parameters, the first warning current threshold is set to 1.1 times the motor's rated current, corresponding to the mild overload warning range; the second current limiting current threshold is set to 1.41 times the motor's rated current, corresponding to the moderate overload current limiting range; and the third overcurrent current threshold is set to 2 times the motor's rated current, corresponding to the severe overcurrent fault range. Simultaneously, an overcurrent judgment duration is pre-configured to filter out instantaneous current spikes and avoid false judgments.
[0095] During the determination process, the controller will compare the real-time calculated current amplitude signal with the three current thresholds mentioned above, and determine the corresponding protection level according to the following rules: If the current amplitude signal is greater than or equal to the first warning current threshold and less than the second current limiting current threshold, the protection level is determined to be the first warning level. At this level, the system does not interfere with the normal operation of the motor; it only records the current motor current data and running time for overcurrent trend analysis and potential hazard prediction.
[0096] If the current amplitude signal is greater than or equal to the second current limiting threshold and less than the third overcurrent threshold, the protection level is determined to be the second current limiting level. This level is a current limiting protection level. The system limits the maximum output current of the stepper motor by adjusting the reference current amplitude of the stepper motor to a preset ratio, thereby preventing the motor from overheating and aging of the windings due to long-term overload operation.
[0097] If the current amplitude signal is greater than or equal to the third overcurrent threshold, and the duration of the current amplitude signal being greater than or equal to the third overcurrent threshold exceeds the preset overcurrent judgment duration, the protection level is determined to be the third severe overcurrent level. Through duration verification, transient current spikes caused by motor startup and instantaneous load fluctuations can be effectively eliminated, improving the accuracy of fault judgment. After a severe overcurrent is determined, the system controls the stepper motor to stop and outputs an interlock signal to prevent further escalation of the fault.
[0098] Furthermore, the three-level overcurrent determination and short-circuit level determination in this embodiment form a linkage mechanism: during the overcurrent determination process, the controller synchronously collects the instantaneous current signal and the short-circuit trigger signal. When the current amplitude continues to rise and simultaneously meets the triple conditions of current change rate exceeding the standard, instantaneous current amplitude exceeding the standard, and hardware short-circuit trigger signal being valid, it is directly determined to be the fourth short-circuit level, and emergency shutdown protection is executed, realizing full-level coverage determination from mild overload to short-circuit fault.
[0099] In some embodiments, if the corresponding protection level is the fourth short-circuit level, the corresponding protection level is determined based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal, including: calculating the current change rate corresponding to the instantaneous current signal; comparing the current change rate with a preset rate threshold and comparing the instantaneous current signal with a preset short-circuit current threshold; if the current change rate is greater than the preset rate threshold, the instantaneous current signal is greater than the preset short-circuit current threshold, and the short-circuit trigger signal is valid, the protection level is determined to be the fourth short-circuit level.
[0100] The specific logic for determining the fourth short-circuit level includes: First, the rate of change of the motor current is calculated. The controller calculates the rate of change of the current through differential calculation based on the instantaneous current values of multiple consecutive sampling periods, which reflects the steepness of the current rise.
[0101] Secondly, the rate of change is compared with a preset rate threshold, and the instantaneous current signal is compared with a preset short-circuit current threshold.
[0102] Finally, if the rate of change of current is greater than the preset rate threshold, the instantaneous current signal is greater than the preset short-circuit current threshold, and the short-circuit trigger signal is valid, it is determined that the system enters the fourth short-circuit level.
[0103] This judgment logic employs a triple redundancy mechanism in both hardware and software. By combining current change rate characteristics, instantaneous current amplitude, and hardware short-circuit detection signals, it can effectively distinguish between normal motor stall and short circuit due to winding insulation failure: in a stall scenario, the current rise rate is relatively gradual, and the high-side current detection shows no abnormal short-circuit characteristics; while in an insulation short circuit, the current spikes instantaneously, triggering the high-side detection signal simultaneously. A short-circuit fault is only determined when all three conditions are met simultaneously, significantly reducing the probability of false positives.
[0104] Upon confirming a short circuit fault, the controller immediately responds via a hardware interrupt, directly cutting off the drive output of the drive module, stopping power supply to the motor, generating a corresponding fault code, reporting it to an external terminal via the communication module, and triggering a hardware interlock.
[0105] Through a triple short-circuit detection mechanism combining hardware and software, millisecond-level short-circuit fault response can be achieved, while ensuring the accuracy of fault identification and avoiding malfunctions.
[0106] In some embodiments, the method further includes: if it is determined that the vacuum valve is in a static standby state based on the current operating state, acquiring the step number of the stepper motor drive signal and the position increment encoding signal of the valve plate; determining whether the stepper motor has lost steps based on the matching relationship between the step number of the drive signal and the position increment encoding signal; if the stepper motor has not lost steps, adjusting the corresponding reference current amplitude to de-rate the stepper motor; if the stepper motor has lost steps, increasing the reference current amplitude of the stepper motor until it is determined that the stepper motor has not lost steps based on the updated step number of the drive signal and the position increment encoding signal.
[0107] If the vacuum valve is determined to be in a static standby state based on the current operating status, the stepper motor drive signal step count and the valve plate position increment encoding signal are acquired. After entering the standby state, the controller continues to output holding current to maintain the valve plate position, while continuously counting the output drive signal steps and acquiring the position increment encoding signal.
[0108] The stepper motor's step loss is determined by the matching relationship between the drive signal step count and the position increment encoding signal. Under normal circumstances, the output drive step count and the actual position increment of the valve plate are in a fixed proportional relationship. If, after outputting a certain number of drive signals, the actual position increment corresponding to the position increment encoding signal is less than the theoretical value, it indicates that the motor's holding torque is insufficient, resulting in step loss.
[0109] If the stepper motor does not lose steps, the corresponding reference current amplitude is adjusted to derated the stepper motor. If no step loss occurs after multiple consecutive checks, it indicates that there is sufficient margin in the current holding torque. The controller gradually reduces the amplitude of the reference current, thereby reducing the holding current of the motor. While ensuring the stability of the valve plate position, this reduces standby power consumption and motor heat generation, achieving energy efficiency optimization.
[0110] By using standby derating control, static standby power consumption can be significantly reduced without affecting the reliability of valve position maintenance, thus extending the service life of the motor and drive circuit.
[0111] In some embodiments, determining whether a stepper motor has lost steps based on the matching relationship between the number of drive signal steps and the position increment encoding signal includes: calculating the actual position increment of the valve plate based on the position increment encoding signal; comparing the number of drive signal steps with the actual position increment; and determining that the stepper motor has lost steps if the number of drive signal steps and the actual position increment do not match.
[0112] The specific implementation process of out-of-step determination and out-of-step compensation includes: The actual position increment of the valve plate is calculated based on the position increment encoded signal. The controller counts pulses of the position increment encoded signal within a unit detection cycle, converts it into the actual rotation angle of the valve plate, and further converts it into the actual number of motor steps.
[0113] The drive signal step count is compared with the actual position increment. If the drive signal step count and the actual position increment do not match, it is determined that the stepper motor has lost a step. The controller counts the number of drive pulses output to the drive module within the same detection cycle and converts them into the theoretical number of rotation steps of the stepper motor. The theoretical number of steps is compared with the actual number of steps. If the deviation between the actual number of steps and the theoretical number of steps exceeds the preset deviation threshold, it is determined that a step has been lost, indicating that the current holding current is insufficient to maintain the load torque.
[0114] If the stepper motor loses a step, the reference current amplitude of the stepper motor is increased until it is determined, based on the updated drive signal step count and position increment encoding signal, that the stepper motor has not lost a step. After a step loss is determined, the controller gradually increases the amplitude of the reference current, checking the step loss status after each increase, until the step loss phenomenon disappears. The current value at this point is the optimal holding current under the current load.
[0115] Through the out-of-step closed-loop feedback mechanism, the standby current can be adaptively and dynamically adjusted, achieving the lowest power consumption operation while ensuring position stability.
[0116] Please see Figure 5 As shown, Figure 5 This is a schematic diagram of the controller 200 provided in an embodiment of this application. The controller 200 is used to execute the steps of the stepper motor control method for the vacuum valve shown in the above embodiments.
[0117] like Figure 5 As shown, the controller 200 includes: The status acquisition unit 201 is used to acquire motion commands sent by an external host computer and acquire the position increment encoding signal of the valve plate corresponding to the vacuum valve, and determine the current operating status of the vacuum valve based on the motion commands and the position increment encoding signal. The motor control unit 202 is used to control the stepper motor to operate at a preset rated power if it is determined that the vacuum valve is in motion based on the current operating state. The current sampling unit 203 is used to sample the motor current and motor voltage of the stepper motor during the operation of the stepper motor, obtain the current amplitude signal and instantaneous current signal of the stepper motor according to the sampling result corresponding to the motor current, and generate a short-circuit trigger signal according to the sampling result corresponding to the motor voltage. The protection execution unit 204 is used to determine the protection action corresponding to the stepper motor based on the current amplitude signal, the instantaneous current signal and the short circuit trigger signal, and to execute the protection action.
[0118] In some embodiments, if it is determined that the vacuum valve is in motion based on the current operating state, controlling the stepper motor to operate at a preset rated power includes: removing the current derating limit on the stepper motor; obtaining the current speed range of the stepper motor; obtaining the mapping relationship between the preset speed range and the control mode; determining the corresponding control mode in the mapping relationship based on the current speed range; and controlling the stepper motor to operate at rated power according to the control mode.
[0119] In some embodiments, during the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal corresponding to the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage. This includes: acquiring the current sampling signal through a low-side current sensing resistor, performing differential amplification on the current sampling signal; converting the differentially amplified current sampling signal into a digital signal, obtaining the instantaneous current signal based on the digital signal, and calculating the current amplitude signal from the instantaneous current signal of a continuous sampling period; acquiring the short-circuit detection voltage signal through a high-side current sensing resistor, inputting the short-circuit detection voltage signal into a threshold detection circuit with a hysteresis interval, and generating a debouncing short-circuit trigger signal.
[0120] In some embodiments, determining and executing the protection action corresponding to the stepper motor based on the current amplitude signal, instantaneous current signal, and short-circuit trigger signal includes: comparing the current amplitude signal with multiple preset current thresholds; determining the corresponding protection level based on the comparison result, instantaneous current signal, and short-circuit trigger signal; the protection level includes a first warning level, a second current limiting level, a third severe overcurrent level, and a fourth short-circuit level; the current threshold corresponding to the first warning level is less than the current threshold corresponding to the second current limiting level, and the current threshold corresponding to the second current limiting level is less than the current threshold corresponding to the third severe overcurrent level; acquiring the protection action corresponding to each protection level; if the protection level is the first warning level, the protection action includes recording the current motor current data and running time; if the protection level is the second current limiting level, the protection action includes adjusting the reference current of the stepper motor to a preset ratio; if the protection level is the third severe overcurrent level, the protection action includes controlling the stepper motor to stop and outputting an interlock signal; if the protection level is the fourth short-circuit level, the protection action includes cutting off the stepper motor drive output and outputting fault information; acquiring the execution time and execution status of the protection action to complete the control of the stepper motor.
[0121] In some embodiments, after obtaining the execution time and execution status of the protection action and completing the control of the stepper motor, the method further includes: after executing the protection action, continuously monitoring the motor current of the stepper motor and updating the protection level; if the protection level is a first warning level or a second current limiting level, if the motor current recovers to the normal range within a preset time, automatically releasing the corresponding protection action; if the protection level is a third severe overcurrent level or a fourth short circuit level, maintaining the protection action until a manual reset command sent by an external terminal is received, so as to complete the reset operation of the stepper motor in response to the manual reset command.
[0122] In some embodiments, if the corresponding protection level is any one of a first warning level, a second current limiting level, or a third severe overcurrent level, the corresponding protection level is determined based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal, including: comparing the current amplitude signal with a preset first warning current threshold, a second current limiting current threshold, and a third overcurrent current threshold, respectively; wherein the first warning current threshold is less than the second current limiting current threshold, and the second current limiting current threshold is less than the third overcurrent current threshold; if the current amplitude signal is greater than or equal to the first warning current threshold and less than the second current limiting current threshold, the protection level is determined to be the first warning level; or, if the current amplitude signal is greater than or equal to the second current limiting current threshold and less than the third overcurrent current threshold, the protection level is determined to be the second current limiting level; or, if the current amplitude signal is greater than or equal to the third overcurrent current threshold, and the duration of the current amplitude signal being greater than or equal to the third overcurrent current threshold exceeds a preset overcurrent determination duration, the protection level is determined to be the third severe overcurrent level.
[0123] In some embodiments, if the corresponding protection level is the fourth short-circuit level, the corresponding protection level is determined based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal, including: calculating the current change rate corresponding to the instantaneous current signal; comparing the current change rate with a preset rate threshold and comparing the instantaneous current signal with a preset short-circuit current threshold; if the current change rate is greater than the preset rate threshold, the instantaneous current signal is greater than the preset short-circuit current threshold, and the short-circuit trigger signal is valid, the protection level is determined to be the fourth short-circuit level.
[0124] In some embodiments, the method further includes: if it is determined that the vacuum valve is in a static standby state based on the current operating state, acquiring the step number of the stepper motor drive signal and the position increment encoding signal of the valve plate; determining whether the stepper motor has lost steps based on the matching relationship between the step number of the drive signal and the position increment encoding signal; if the stepper motor has not lost steps, adjusting the corresponding reference current amplitude to de-rate the stepper motor; if the stepper motor has lost steps, increasing the reference current amplitude of the stepper motor until it is determined that the stepper motor has not lost steps based on the updated step number of the drive signal and the position increment encoding signal.
[0125] In some embodiments, determining whether a stepper motor has lost steps based on the matching relationship between the number of drive signal steps and the position increment encoding signal includes: calculating the actual position increment of the valve plate based on the position increment encoding signal; comparing the number of drive signal steps with the actual position increment; and determining that the stepper motor has lost steps if the number of drive signal steps and the actual position increment do not match.
[0126] It should be noted that those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the controller and each module described above can be referred to the corresponding contents in the various embodiments of the stepper motor control method for the vacuum valve, and will not be repeated here.
[0127] The aforementioned stepper motor control method for the vacuum valve can be implemented as a computer program, which can be used in various ways, such as... Figure 5 It runs on the controller shown.
[0128] Please see Figure 6 , Figure 6 This is a schematic block diagram of the controller provided in an embodiment of this application. The controller includes a processor, a memory, and a network interface connected via a device bus, wherein the memory may include a storage medium and internal memory.
[0129] The storage medium can store operating devices and computer programs. The computer program includes program instructions that, when executed, cause the processor to perform any stepper motor control method for the vacuum valve.
[0130] The processor provides computing and control capabilities to support the operation of the entire controller.
[0131] The internal memory provides an environment for the execution of computer programs stored in non-volatile storage media. When the computer program is executed by the processor, it enables the processor to execute any stepper motor control method for vacuum valves.
[0132] This network interface is used for network communication, such as sending assigned tasks. Those skilled in the art will understand that... Figure 6 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the terminal to which the present application is applied. The specific controller may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.
[0133] It should be understood that the processor can be a Central Processing Unit (CPU), but it can also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. Among these, a general-purpose processor can be a microprocessor or any conventional processor.
[0134] In one embodiment, the processor is configured to run a computer program stored in memory to perform the following steps: The system acquires motion commands sent from an external host computer and obtains the position increment encoding signal of the corresponding valve plate of the vacuum valve. Based on the motion commands and the position increment encoding signal, the system determines the current operating status of the vacuum valve. If the vacuum valve is determined to be in motion based on the current operating status, control the stepper motor to operate at the preset rated power; During the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal of the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage. The protection action corresponding to the stepper motor is determined based on the current amplitude signal, instantaneous current signal, and short-circuit trigger signal, and then the protection action is executed.
[0135] In some embodiments, if it is determined that the vacuum valve is in motion based on the current operating state, controlling the stepper motor to operate at a preset rated power includes: removing the current derating limit on the stepper motor; obtaining the current speed range of the stepper motor; obtaining the mapping relationship between the preset speed range and the control mode; determining the corresponding control mode in the mapping relationship based on the current speed range; and controlling the stepper motor to operate at rated power according to the control mode.
[0136] In some embodiments, during the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal corresponding to the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage. This includes: acquiring the current sampling signal through a low-side current sensing resistor, performing differential amplification on the current sampling signal; converting the differentially amplified current sampling signal into a digital signal, obtaining the instantaneous current signal based on the digital signal, and calculating the current amplitude signal from the instantaneous current signal of a continuous sampling period; acquiring the short-circuit detection voltage signal through a high-side current sensing resistor, inputting the short-circuit detection voltage signal into a threshold detection circuit with a hysteresis interval, and generating a debouncing short-circuit trigger signal.
[0137] In some embodiments, determining and executing the protection action corresponding to the stepper motor based on the current amplitude signal, instantaneous current signal, and short-circuit trigger signal includes: comparing the current amplitude signal with multiple preset current thresholds; determining the corresponding protection level based on the comparison result, instantaneous current signal, and short-circuit trigger signal; the protection level includes a first warning level, a second current limiting level, a third severe overcurrent level, and a fourth short-circuit level; the current threshold corresponding to the first warning level is less than the current threshold corresponding to the second current limiting level, and the current threshold corresponding to the second current limiting level is less than the current threshold corresponding to the third severe overcurrent level; acquiring the protection action corresponding to each protection level; if the protection level is the first warning level, the protection action includes recording the current motor current data and running time; if the protection level is the second current limiting level, the protection action includes adjusting the reference current of the stepper motor to a preset ratio; if the protection level is the third severe overcurrent level, the protection action includes controlling the stepper motor to stop and outputting an interlock signal; if the protection level is the fourth short-circuit level, the protection action includes cutting off the stepper motor drive output and outputting fault information; acquiring the execution time and execution status of the protection action to complete the control of the stepper motor.
[0138] In some embodiments, after obtaining the execution time and execution status of the protection action and completing the control of the stepper motor, the method further includes: after executing the protection action, continuously monitoring the motor current of the stepper motor and updating the protection level; if the protection level is a first warning level or a second current limiting level, if the motor current recovers to the normal range within a preset time, automatically releasing the corresponding protection action; if the protection level is a third severe overcurrent level or a fourth short circuit level, maintaining the protection action until a manual reset command sent by an external terminal is received, so as to complete the reset operation of the stepper motor in response to the manual reset command.
[0139] In some embodiments, if the corresponding protection level is any one of a first warning level, a second current limiting level, or a third severe overcurrent level, the corresponding protection level is determined based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal, including: comparing the current amplitude signal with a preset first warning current threshold, a second current limiting current threshold, and a third overcurrent current threshold, respectively; wherein the first warning current threshold is less than the second current limiting current threshold, and the second current limiting current threshold is less than the third overcurrent current threshold; if the current amplitude signal is greater than or equal to the first warning current threshold and less than the second current limiting current threshold, the protection level is determined to be the first warning level; or, if the current amplitude signal is greater than or equal to the second current limiting current threshold and less than the third overcurrent current threshold, the protection level is determined to be the second current limiting level; or, if the current amplitude signal is greater than or equal to the third overcurrent current threshold, and the duration of the current amplitude signal being greater than or equal to the third overcurrent current threshold exceeds a preset overcurrent determination duration, the protection level is determined to be the third severe overcurrent level.
[0140] In some embodiments, if the corresponding protection level is the fourth short-circuit level, the corresponding protection level is determined based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal, including: calculating the current change rate corresponding to the instantaneous current signal; comparing the current change rate with a preset rate threshold and comparing the instantaneous current signal with a preset short-circuit current threshold; if the current change rate is greater than the preset rate threshold, the instantaneous current signal is greater than the preset short-circuit current threshold, and the short-circuit trigger signal is valid, the protection level is determined to be the fourth short-circuit level.
[0141] In some embodiments, the method further includes: if it is determined that the vacuum valve is in a static standby state based on the current operating state, acquiring the step number of the stepper motor drive signal and the position increment encoding signal of the valve plate; determining whether the stepper motor has lost steps based on the matching relationship between the step number of the drive signal and the position increment encoding signal; if the stepper motor has not lost steps, adjusting the corresponding reference current amplitude to de-rate the stepper motor; if the stepper motor has lost steps, increasing the reference current amplitude of the stepper motor until it is determined that the stepper motor has not lost steps based on the updated step number of the drive signal and the position increment encoding signal.
[0142] In some embodiments, determining whether a stepper motor has lost steps based on the matching relationship between the number of drive signal steps and the position increment encoding signal includes: calculating the actual position increment of the valve plate based on the position increment encoding signal; comparing the number of drive signal steps with the actual position increment; and determining that the stepper motor has lost steps if the number of drive signal steps and the actual position increment do not match.
[0143] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, causes the processor to implement the steps of the stepper motor control method for a vacuum valve as provided in any embodiment of this application.
[0144] The computer-readable storage medium may be an internal storage unit of the controller as described in the foregoing embodiments, such as the hard disk or memory of the controller. Alternatively, the computer-readable storage medium may be an external storage device of the controller, such as a plug-in hard disk, Smart Media Card (SMC), Secure Digital (SD) card, or Flash Card.
[0145] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A stepper motor control method for a vacuum valve, characterized in that, include: The system acquires motion commands sent by an external host computer and acquires the position increment encoding signal of the valve plate corresponding to the vacuum valve. Based on the motion commands and the position increment encoding signal, the system determines the current operating state of the vacuum valve. If it is determined that the vacuum valve is in motion based on the current operating state, the stepper motor is controlled to operate at a preset rated power; During the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal corresponding to the stepper motor are obtained, and a short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage. The protection action corresponding to the stepper motor is determined based on the current amplitude signal, instantaneous current signal, and short-circuit trigger signal, and the protection action is executed.
2. The method according to claim 1, characterized in that, If the vacuum valve is determined to be in motion based on the current operating state, controlling the stepper motor to operate at a preset rated power includes: Remove the current derating limit on the stepper motor; Obtain the current speed range of the stepper motor; Obtain the mapping relationship between the preset speed range and the control mode; The corresponding control mode is determined in the mapping relationship based on the current speed range; The stepper motor is controlled to operate at rated power according to the control mode.
3. The method according to claim 1, characterized in that, During the operation of the stepper motor, the motor current and motor voltage of the stepper motor are sampled. Based on the sampling results corresponding to the motor current, the current amplitude signal and instantaneous current signal corresponding to the stepper motor are obtained. A short-circuit trigger signal is generated based on the sampling results corresponding to the motor voltage, including: The current sampling signal is acquired by using a low-side current sensing resistor, and the current sampling signal is then differentially amplified. The current sampling signal after differential amplification is converted into a digital signal, the instantaneous current signal is obtained based on the digital signal, and the current amplitude signal is calculated from the instantaneous current signal of the continuous sampling period. The short-circuit detection voltage signal is acquired by a high-side current sensing resistor, and then input into a threshold detection circuit with hysteresis interval to generate a debouncing short-circuit trigger signal.
4. The method according to claim 1, characterized in that, The step of determining the protection action corresponding to the stepper motor based on the current amplitude signal, the instantaneous current signal, and the short-circuit trigger signal, and executing the protection action, includes: The current amplitude signal is compared with multiple preset current thresholds to obtain the comparison results; The corresponding protection level is determined based on one or more of the comparison results, instantaneous current signal, and short-circuit trigger signal; the protection level includes a first warning level, a second current limiting level, a third severe overcurrent level, and a fourth short-circuit level; the current threshold corresponding to the first warning level is less than the current threshold corresponding to the second current limiting level, and the current threshold corresponding to the second current limiting level is less than the current threshold corresponding to the third severe overcurrent level. Obtain the protection action corresponding to each protection level; If the protection level is the first warning level, the protection action includes recording the current motor current data and running time; If the protection level is the second current limiting level, the protection action includes adjusting the reference current of the stepper motor to a preset ratio; If the protection level is the third severe overcurrent level, the protection action includes controlling the stepper motor to stop and outputting an interlock signal; If the protection level is the fourth short-circuit level, the protection action includes cutting off the stepper motor drive output and outputting fault information; The execution time and execution status of the protection action are obtained to complete the control of the stepper motor.
5. The method according to claim 4, characterized in that, After acquiring the execution time and execution status of the protection action and completing the control of the stepper motor, the method further includes: After performing the protection action, the motor current of the stepper motor is continuously monitored and the protection level is updated. If the protection level is the first warning level or the second current limiting level, the corresponding protection action will be automatically released if the motor current returns to the normal range within a preset time. If the protection level is the third severe overcurrent level or the fourth short circuit level, the protection action is maintained until a manual reset command is received from an external terminal, so as to complete the reset operation of the stepper motor in response to the manual reset command.
6. The method according to claim 4, characterized in that, If the corresponding protection level is any one of the first warning level, the second current limiting level, or the third severe overcurrent level, the step of determining the corresponding protection level based on one or more of the comparison result, the instantaneous current signal, and the short-circuit trigger signal includes: The current amplitude signal is compared with a preset first warning current threshold, a second current limiting current threshold, and a third overcurrent current threshold, respectively; wherein the first warning current threshold is less than the second current limiting current threshold, and the second current limiting current threshold is less than the third overcurrent current threshold. If the current amplitude signal is greater than or equal to the first warning current threshold and less than the second current limiting current threshold, the protection level is determined to be the first warning level; or, If the current amplitude signal is greater than or equal to the second current limiting current threshold and less than the third overcurrent current threshold, the protection level is determined to be the second current limiting level; or, If the current amplitude signal is greater than or equal to the third overcurrent threshold, and the duration of the current amplitude signal being greater than or equal to the third overcurrent threshold exceeds the preset overcurrent determination duration, the protection level is determined to be the third severe overcurrent level.
7. The method according to claim 4, characterized in that, If the corresponding protection level is the fourth short-circuit level, the step of determining the corresponding protection level based on one or more of the comparison result, instantaneous current signal, and short-circuit trigger signal includes: Calculate the rate of change of the current corresponding to the instantaneous current signal; The rate of change of the current is compared with a preset rate threshold, and the instantaneous current signal is compared with a preset short-circuit current threshold. If the rate of change of current is greater than the preset rate threshold, the instantaneous current signal is greater than the preset short-circuit current threshold, and the short-circuit trigger signal is valid, then the protection level is determined to be the fourth short-circuit level.
8. The method according to claim 1, characterized in that, The method further includes: If the vacuum valve is determined to be in a static standby state based on the current operating state, the stepper motor drive signal step number and valve plate position increment encoding signal are obtained; The stepper motor is judged to have lost steps based on the matching relationship between the number of drive signal steps and the position increment encoding signal. If the stepper motor does not lose steps, the corresponding reference current amplitude is adjusted to derated the stepper motor. If the stepper motor loses a step, the reference current amplitude of the stepper motor is increased until it is determined, based on the updated drive signal step count and the position increment encoding signal, that the stepper motor has not lost a step.
9. The method according to claim 8, characterized in that, The step of determining whether the stepper motor has lost steps based on the matching relationship between the number of drive signal steps and the position increment encoding signal includes: The actual position increment of the valve plate is calculated based on the position increment encoded signal. The number of steps in the drive signal is compared with the actual position increment. If the number of steps in the drive signal does not match the actual position increment, it is determined that the stepper motor has lost steps.
10. A controller, characterized in that, It includes a memory and a processor; the memory is used to store a computer program; the processor is used to execute the computer program and, when executing the computer program, implement the method as described in any one of claims 1 to 9.