Abstract : Based on the programmable multi-axis motion controller (PMAC), this paper proposes a technique for developing CNC system application software by combining Visual Basic and dynamic link libraries. Practice has proven that this technique is entirely feasible.
Keywords : Dynamic Link Library; CNC System; Windows; PMAC
I. Introduction
Microsoft Windows programs provide computer users with an intuitive and graphically rich working environment, laying the foundation for a highly user-friendly interface for CNC systems. Windows programs are generally written in C or C++, but Windows programming is relatively complex, and it is difficult for most DOS programmers to master. Microsoft's Visual Basic, released in 1991, simplified Windows program writing.
Visual Basic is a visual integrated development environment (IDE) that cleverly encapsulates the complexities of Windows programming, enabling programmers to create programs with all the advantages of Windows using an event-driven, structured programming approach, and generating Windows executable files. However, CNC systems require real-time programs with hardware input/output capabilities, while Visual Basic cannot directly manipulate hardware, posing a challenge to its application in CNC systems. Dynamic link libraries (DLLs) can directly implement I/O operations, and Visual Basic can achieve real-time control and hardware input/output operations by calling functions in DLLs. The following section will describe the techniques for developing CNC systems using DLLs and Visual Basic.
For details, please click: Development of CNC Systems Based on Dynamic Link Libraries in the Visual Basic Environment