Application Research of Small Laser Stepper Motor Control System
2026-04-06 07:36:49··#1
Abstract: The small laser experimental system requires the control of multiple hybrid stepper motors and reactive stepper motors. Precise control of these stepper motors is essential for both the spatial positioning of the target and the adjustment of the waveplate in the optical path. Using the PCL839 motion control card and a self-developed motor control switch and control software, not only can precise motion control of the stepper motors be achieved, but also the special control requirements of the target range can be met, enabling real-time online control. Keywords: small laser; stepper motor; motion control Abstract: A small laser experiment system is made of many stepping motors. Adjusting the spatial position of the target bolus or glass patch in the ray path is impossible without accurate stepping motor control. Using the PCL839 control and motor control switch, we developed our own system, enabling accurate and real-time stepping motor control. Keywords: small laser; stepping motor; motion control 1 Introduction The small laser experiment system requires the control of the following equipment: a synchronization system, two 300J power supplies, four 20KJ power supplies, one diode power supply, a set of liquid crystal light valves, and three-way stepper motor control. In the target range, there are four-channel CCD image acquisition, 19-channel stepper motor control, vacuum display, etc. Based on user requirements, the small laser computer control system is divided into a device control system and a target range control system. Operations such as optical path collimation, beam spot image movement, and lens rotation all rely on the rotation of stepper motors. Achieving high-precision positioning control of the stepper motors is a challenge for the target range control system. The control system, composed of an industrial computer, a PCL839 motion control card, and a control switch, not only meets the high-precision requirements of the target range for motor rotation but also enables real-time online control. 2. Control System Structure and Function The target range control system controls the vacuum extraction of the vacuum chamber, the movement of the target pellet, and the adjustment of the optical path. There are four hybrid motors inside the target chamber to move the target pellet. There are 15 reactive motors on the optical path to transmit the laser beam. [align=center] Figure 1. Target Range Control System Structure Diagram[/align] The target range control computer decomposes the control signal through the PCL839 motion control card and transmits it to the motor control switch (self-developed). The motor control switch further subdivides the control signal (address signal and pulse count) and then sends the level signal and corresponding pulse count to the target motor to drive it. 3. PCL839 Card The PCL839 card is a stepper motor control card provided by Advantech, which can provide precise control pulses to meet the high-precision and real-time control requirements of stepper motors. The card has the following main performance characteristics: It can simultaneously and independently control three-axis stepper motors, providing stepping pulses and direction signals for each axis; all motor control signal outputs and switch signal inputs are opto-isolated; it provides 16 input/output TTL channels; all functions and motion control can be implemented by software; interrupt inputs can be selected by jumper connectors. 4 Stepper Motor Driver Design 4.1 Physical Structure The hardware signal logic of the motor driver is as follows: Up to 30 motors share drive channel 1, including: PULSE, DIR, EL+, EL-, ORG, FREE. 4.2 Drive Control Software Design The relationship between motor object classes is shown in Figure 2. MotionController: Encapsulates the PCL839 card; StepMotor: Has a many-to-one Client/Service relationship with MotionController. MotionController provides a service queue and caches command requests submitted by StepMotor; when a command is completed or an alarm occurs, MotionController calls the alarm method provided by StepMotor. In this way, StepMotor can implement asynchronous service requests. PCL839Service: The command request submitted by StepMotor is encapsulated as PCL839Service. [align=center] Figure 2 Motor object class call relationship[/align] The following is the design of 3 important class objects: (1) PCL839Service. PCL839Service represents a motor request command. StepMotor creates an instance of this object, saves it in MotionController, and is responsible for clearing it when the task is completed. In MotionController, PCL839Service is saved using STL deque. (2) MotionController. MotionController has the following running parameters: Provides the following alarms: l Enabled returns false; indicating that the device may be faulty; l bool returns false; indicating that the device may be faulty; l Busy returns true; indicating that the motor is running. MotionController has no control parameters. MotionController has no experimental data. The processing flow of MoveAsStep() is as follows: 1. StepMotor sends a MoveAsStep request; 2. PCL839 queues the request; 3. PCL839 begins processing the request, first calling StepMotor.SetReady(); 4. StepMotor.SetReady sets the operating parameters, making the motor Online, and then makes the motor start running; 5. If PCL839 detects that the motor has stopped, it makes the motor Offline, and then calls StepMotor.StepOver(); 6. PCL839 removes the request from the request queue. The processing flow of Hold() is as follows: 1. StepMotor issues a Hold request, 2. PCL839 queues the request; 3. PCL839 begins to process the request, first calling StepMotor.SetReady(); 4. StepMotor.SetReady sets the operating parameters to make the motor Online; 5. After StepMotor issues Release(), PCL839 makes the motor Offline; 6. PCL839 removes the request from the request queue. (3) class StepMotor asynchronous commands will generate PCL839Service, which is handed over to PCL839 for queuing and processing. If completed, PCL839 will call the event handling function of StepMotor. 5 System Software Design The basic principles of software design are simple and reliable operation and beautiful interface. The stepper motor control system consists of four steps: motor parameter setting, motor selection, step count setting, and forward/backward/stop. To ensure intuitive and convenient control operation, a complete motor layout diagram of the target range is provided to the user. Users can directly click on the motor to be controlled, making operation more intuitive and convenient. Figure 3 shows the control interface. [align=center] Figure 3 Stepper Motor Control System Software[/align] When the stepper motor first starts rotating, its rotation speed is slow, taking several time pulses to reach normal speed. Therefore, to control the motor's rotation speed, two speed values must be set: minimum FL and maximum FH. In engineering applications, whether adjusting the spatial position of the target or the optical path, the current number of steps (remaining steps) of the stepper motor should be fed back to the user in real time, allowing the user to adjust the motor (forward/backward/stop) at any time based on the target and optical path conditions. The Advantech PCL839 stepper motor driver application provides an interface for querying the remaining pulse count (steps) of the motor. However, after testing, it was found that the feedback value had a large error. Through multiple experiments, the status feedback function of the MotionController class was finally modified as follows. The main code is: unsigned int r0; int status = Out_byte(0, 0x80); r0 = In_byte(1) & 0xFF; r0 = (In_byte(2) & 0xFF) * 256 + r0; r0 = (In_byte(3) & 0x3) * 65536 + r0; 6 Conclusion The small laser experimental system has multiple stepper motors of different types that need to be controlled. The hardware control system is composed of an industrial control computer, a PCL839 motion control card, and a self-developed control switch. Special function control software was developed to meet the specific requirements of the small laser experimental system. It can not only realize various high-precision positioning, limit, automatic trajectory and other motion control, but also meet the special control requirements of the target range for stepper motors and realize real-time online control. References: [1] Taksshi Kenjo and Akira Sugawara, “Stepping Motors and Their Microprocessor Controls”, Second Edition, Oxford University Press, 1994 [2] F. Betin, M. Deloizy, and C. Goeldel, “Closed loop control of stepping motor drive: Comparison between PID control, self-tuning regulation and fuzzy logic control,” Eur. Power Electron. J., vol. 8, no. 1–2, pp.33–39, June 1999. [3] Hu Jinming, Hou Shizhu et al. Optimization and maintenance application of electromagnetic speed-regulating motor control system. Microcomputer Information, 2002 (6): 41-43. [4] Liu Shaoke, Yuan Haizhou, Lu Shengwang. Computer control method for stepper motor drive [J]. Electrical Drive Automation, 2000 (4): 40-42. [5] LJ Lagin et al., “The Overview of the National Ignition Facility Distributed Computer Control System", ICALEPCS 2001. [6] P. VanArsdall B. Reed, R. Bettenhausen J. Spann, F. Holloway J. Wiedwald, M. Miller, "INTEGRATED COMPUTER CONTROL SYSTEM", UCRL-LR-105821-97-3. [7] SM Yang and EL Kuo. "Damping conml of two-phase hybrid stepping motors”, IEEE Trammtiom on Power Electronics, Vol. 18, No. 3, May 2003.