Share this

Research on CNC System of CNC Turret Punch Press Based on Motion Control Card

2026-04-06 04:47:52 · · #1

0 Introduction

Currently, the development and research of motion control systems for turret CNC punch presses in China are mainly based on two models: 1) PC+PLC-based motion control systems for turret CNC punch presses; 2) PC+motion control card-based motion control systems for turret CNC punch presses. Because the PC+PLC-based motion control system uses a single-chip PLC to achieve speed and position control of the moving parts, the peripheral circuitry is relatively complex and the calculation speed is relatively slow. Therefore, people prefer motion control systems with faster processing speeds and the ability to meet high-precision speed and position control requirements. Consequently, the PC+motion control card-based motion control system for turret CNC punch presses has been widely used with the development of motion control technology. Furthermore, this system uses servo motors to achieve acceleration and deceleration motion control. As an actuator that converts electrical pulses into angular displacement, the servo motor can control the speed and distance of the moving parts of the equipment according to the frequency and quantity of pulse signals, and control the direction of movement of the equipment through direction signals. This is an economical and simple high-speed control solution.

1. Working principle of motion control system

This system adopts a PC + motion control card motion control system solution. The system program and interface are developed and designed using Visual C++ 6.0 to achieve motion control of servo motors. The system transmits information to the machine control software via a manual operation interface on the PC. The machine control software converts the operation information into motion parameters and calls motion functions in the DLL library based on these parameters. The motion functions then call the motion control card driver to issue control commands to the control card. The motion control card, in turn, sends corresponding control signals (pulses, direction signals) to the motor driver based on the control commands. The motor driver then drives the motor to move, thereby moving the machine components.

2. Hardware composition of the control system

2.1 Hardware Components

The system hardware consists of a PC, a DMC1410B motion control card , servo motor drivers, and servo motors. The DMC1410B motion control card is a pulse-type four-axis motion control card independently developed by Leadshine Technology, capable of outputting pulse and direction signals to control the motor's speed and direction. The DMC1410B motion control card features plug-and-play functionality, continuous motion, linear interpolation, and single-axis motion; it displays trapezoidal and S-shaped acceleration/deceleration curves, with a maximum pulse output frequency of 1.2MHz. It has 16 input and 12 output general-purpose I/O interfaces, and both input and output signals are opto-isolated, significantly improving the reliability and anti-interference performance of the motion control card. The DMC1410 card also supports plug-and-play functionality.

2.2 Main Functions of the Motion Control Card

The motion control card enables the setting of tool paths, return to origin for each axis, jog control, machine tool start/stop, tool selection, display of machining status, and management of machining tasks. It allows for independent and continuous motion of each axis, and by setting speed and acceleration parameters, the motion trajectory can be made trapezoidal or S-shaped with acceleration and deceleration control. Real-time control of the motion control card enables two-axis linear interpolation, three-axis linear interpolation, and multi-axis linkage operations. The DMC1410B motion control card can output two types of pulse signals:

1) Pulse + Direction Form (Single Pulse); 2) Positive Pulse + Negative Pulse (Double Pulse) Form. Each axis has two deceleration and braking signals, +SD and -SD. Upon detecting the deceleration signal, the motor decelerates to low speed. The general-purpose digital output signal OUT is used to control switching devices such as relays, solenoid valves, and indicator lights.

The general digital input signal INPUT is used for signal input of sensors such as proximity switches, photoelectric switches, and buttons.

3 Control System Software Design

3.1 Motion Control Function

This system is based on the Windows XP platform and uses Visual C++ 6.0 as the development tool for program design and development. It is a message-based programming system based on a driver approach. When a user needs to perform a specific function, clicking the corresponding function button generates a corresponding message. The operating system then loops through the messages, searches for them, and sends them to the corresponding objects. Each receiving object has a corresponding message map to associate messages with processing functions. When the target object receives a message map, it begins searching for a matching message processing function and implements the corresponding functionality.

The system supports the DMC1410B motion control card, which offers a rich set of functions including initialization, continuous motion control, single-axis motion control, linear interpolation, circular interpolation, homing, and motion state detection. Since the DMC1410B motion control card supports up to 12 cards operating simultaneously, a single PC can control up to 48 servo motors simultaneously.

In terms of software, the motion control card provides a large number of motion control functions to meet various user requirements in applications. Users only need to call the relevant motion control functions in the motion control card's function library according to the specific requirements of the motion control system to satisfy a variety of multi-axis motion control system requirements.

The functions are listed below:

(1) Initialization function

d1000_board_init software initialization

(2) Continuous motion control function

d1000_start_tv_move controls the continuous motion of one axis using a trapezoidal velocity curve.

d1000_start_sv_move controls the continuous motion of an axis using an S-shaped velocity curve.

d1000_immediate_stop stops an axis in a trapezoidal or S-shape.

d1000_decel_stop stops an axis by decelerating in a trapezoidal or S-shape.

(3) Single-axis motion control function

d1000_start_t_move controls the positional movement of a point with relative coordinates using a trapezoidal velocity curve; d1000_start_sa_move controls the positional movement of a point with absolute coordinates using an S-shaped velocity curve.

(4) Linear interpolation function

Linear interpolation motion of arbitrary 2-axis, 3-axis, and 4-axis phase/absolute coordinates in d1000_start_t/ta_line

(5) Circular interpolation function

Circular interpolation of phase/absolute coordinates on any two axes using d1000_start_t/ta_arc.

(6) Return-to-origin function

d1000_home_move returns to the origin.

3.2 System Programming

3.2.1 Real-time control

As a real-time, multi-tasking motion control system, the CNC turret punch press motion control system needs to perform many tasks, mainly including machine tool start-up and shutdown, linear and circular interpolation calculations, speed and position control, etc. The real-time requirements vary among these tasks. Therefore, based on this, the system's multi-threaded, multi-tasking, and preemptive characteristics can be utilized to assign each system task to different threads and assign priorities to each thread. When a high-priority thread, i.e., one that needs to perform a task with high real-time requirements, automatically terminates the work of other lower-priority threads and switches to execute that thread. This achieves the real-time performance required by the motion control system.

To achieve real-time control of the motion control system, a timed cyclic detection method is adopted. A message timer is added to the running program to handle the message mapping process, and a corresponding OnTimer() function is written. The OnTimer() function is a key function in the real-time motion control system; based on the time parameters set by the timer, it cyclically executes the following functions:

1) Determine the extreme positions of the x and y axes.

2) Real-time display of x-y axis coordinates.

3) Real-time motion control at the zero point, where the x-axis is controlled first and then the y-axis is controlled during the zero-point return.

3.2.2 Motion Control

The DMC1410B motion control card can realize both single-axis point-to-point motion and continuous motion. Therefore, precise position or speed control can be performed on single-axis point-to-point motion. The DMC1410 can describe motion trajectories using both absolute and relative coordinate modes. Each mode has its advantages. For example, in absolute coordinate mode, a curve is defined using a series of coordinate points; modifying the coordinates of an intermediate point will not affect the coordinates of subsequent points. In relative coordinate mode, a curve is defined using a series of coordinate points, and the curve trajectory can be repeated multiple times using a loop command. In the DMC1410 function library, the unit for distance or position is pulse; the unit for speed is pulse/s; and the unit for time is s.

The DMC1410B motion control card provides two acceleration/deceleration methods in position control mode: trapezoidal curve acceleration/deceleration and S-curve acceleration/deceleration.

1) Trapezoidal acceleration and deceleration are commonly used in position control, employing a trapezoidal speed control mode. The reason the motion speed must vary according to a trapezoidal curve is that the motor rotor and the dragged object have inertia and cannot reach the specified speed instantaneously; therefore, there must be a certain acceleration process. The same applies to deceleration; otherwise, the motor will experience step loss, overshoot, or oscillation due to insufficient instantaneous torque, as shown in Figure 1.

Figure 1 Trapezoidal velocity curve

2) Although the trapezoidal velocity curve is simple, its velocity curve is not smooth, and its acceleration has abrupt changes, resulting in impact phenomena during motion, which can easily cause machine noise and wear on the transmission mechanism. On the trapezoidal velocity curve, the lack of smoothness in motion is mainly manifested in the velocity transitions and corresponding acceleration abrupt changes at four instants: when starting, when reaching the maximum speed, when decreasing from the maximum speed, and when finally stopping.

If the acceleration is changed to a linear change, the velocity curve will become smoother. Both the acceleration and deceleration phases will become "S"-shaped. Using this velocity curve results in smoother motion and helps to shorten the acceleration process, reduce vibration and noise of the motion device, and extend the life of the mechanical transmission parts, as shown in Figure 2.

Figure 2 S-shaped velocity curve

Trapezoidal curves allow modification of position and velocity parameters during motion; S-curves only allow modification of position parameters during motion. When accelerating, trapezoidal curves have shorter acceleration and deceleration times, while S-curves provide smoother motion. Therefore, the appropriate acceleration/deceleration curve mode should be selected based on the specific application.

3.2.3 State Detection

Users can read the status of the control axis, the trajectory control status of continuous motion, and the command status from the status register of the motion control card. The operating mode and status of the motion control axis can be queried by calling the motion status detection function.

The motion state detection function is described below:

The syntax definition for d1000_check_done, which detects the motion state of a specified axis, is as follows:

C/C++:

DWORDd1000_check_done(shortaxis);

Parameter description:

Axis: Axis number, ranging from 0 to (n×4-1). Return value:

0: Running

1: Stop when pulse output is complete

2: Command to stop (e.g., calling the d1000_decel_stop function)

3: Stop when encountering a limit switch

4: Stop at the origin.

3.3 Software Structure Design

Based on the motion function requirements and the support of the motion control card system, the system can be mainly divided into the following modules: parameter setting module, motion control module, status display module, code display module, and system management module. The parameter setting module is mainly responsible for setting the pulse input of each motion spindle and selecting the tool. The motion control module mainly controls the movement of moving parts. The status display module is mainly responsible for displaying the system's operating status (position coordinates, speed, etc.) and runtime parameters in real time. The code display module is mainly responsible for displaying codes, reporting errors, and modifying error codes. The system management module is mainly responsible for file management. Through the coordinated control of these modules, the program together constitutes a complete CNC turret system based on the motion control card, as shown in Figure 3.

Figure 3 Software Structure Framework

4. System Optimization Design and Mold Management

4.1 The closest distance method and the cheapest method

Path optimization algorithms based on the nearest distance method and the cheapest method are widely used in various industries. This paper analyzes and summarizes the basic principles of typical process path optimization algorithms, and develops a process path optimization method for turret CNC punch presses, providing corresponding algorithm descriptions. Turret CNC punch presses mainly process various holes, such as round holes, square holes, oval holes, and various complex holes. Path optimization is performed using part graphic information and an interactive manual approach. Specific algorithmic optimization methods are employed to reduce processing time and processing paths, improve production efficiency, and lower production costs.

4.2 Mold Library Management

There are many types and forms of molds. To meet the search and matching requirements of a CNC automatic programming system, the various parameters of the molds need to be defined and categorized reasonably. This mainly includes setting parameters for various molds such as triangles, circles, squares, pentagons, and irregular shapes.

5 Conclusion

Based on the DMC1410B motion control card and the Windows XP system platform, this CNC punch press platform utilizes Visual C++ 6.0 as the development tool to manage the human-machine interface and monitor the motion control system in real time, displaying motion trajectories and machining codes. It constructs a CNC punch press platform based on a PC and motion control card, demonstrating practicality and versatility for motion control card-based CNC systems. The system uses the DMC1410B motion control card to complete real-time tasks such as motion trajectory planning, linear and circular interpolation calculations, motion position control, and speed control. The PC provides a convenient and quick human-machine interface and system configuration, fully leveraging the rich hardware and software resources of the PC, shortening the development cycle, and reflecting the superiority of the CNC punch press system. With the motion control card as the core of the CNC system hardware platform, this CNC system allows other users to utilize new technologies and methods to further develop and expand it with new functional modules, making the system more complete, advanced, and powerful.

Read next

CATDOLL 102CM B04 TPE Doll with Anime Head

Height: 102cm Weight: 15.5kg Shoulder Width: 26cm Bust/Waist/Hip: 51/46/66cm Oral Depth: 3-5cm Vaginal Depth: 3-13cm An...

Articles 2026-02-22
CATDOLL Jo Soft Silicone Head

CATDOLL Jo Soft Silicone Head

Articles
2026-02-22
CATDOLL 115CM Alice TPE

CATDOLL 115CM Alice TPE

Articles
2026-02-22