6
New Software to Generate the CNC Code For Turning Operations R.T. CURTA, N. BÂLC, A. CAREAN Dept. of Manufacturing Engineering Technical University of Cluj-Napoca B-dul Muncii, 103-105, 400641 Cluj-Napoca ROMANIA [email protected] Abstract: - The paper presents a new computer aided manufacturing software, called PASCON. The PASCON software has been developed by using the AutoLISP software, which is one of the ” built-in” programming tools of the AutoCAD software. The CNC files can be obtained both for the partially geometrically/ constructively defined piece and for the finished piece for which the technological documentation is to be developed. A case study is presented, using the PASCON program, to test its compatibility with other CAM systems and with Lynx 220 CNC Turning Center, with Fanuc OI-TB controller. Key-Words: - CAD-CAM, CNC, turning, AutoLISP, AutoCAD. 1 Introduction Acknowledgement: This research was supported by the national research grant BIOMAPIM, PCCE - ID 101, contract nr. 5/2010. This paper presents a new method, which is an original software program for the assisted generation of the numerical conduct files for turning processing jobs. In the past few years, the so-called Low Cost CAD systems, where the software for generating CNC files which is to be presented in the following chapters also belongs, have thoroughly spread in the world technology. The main reason for the spread of these low cost programming packages is the fact that they allow the development of open information systems, which on their turn may be configured depending on the requirements, the needs and the facilities of the user. This is also one of the main reasons why the author has chosen the development of the PASCON System (Assisted Programming of the Lathes with Numerical Command). 2 PASCON Software Development The methodology for the development of the CNC files is based on a series of programs with very complex algorithms, both for the pieces that are in an intermediate constructive design state and for the finished pieces. The current PASCON software for generating CNC files is a very flexible one, and has been developed in such a manner so as to allow, when needed, for the implementation of the third axis of the numerical command machine. Currently, the software has been encoded depending on the Fanuc OITB postprocessor of the Lynx 220 turning centre, which belongs to the TCM department of the Machine Construction Faculty from Cluj-Napoca. 2.1 The algorithm for the PASCON software The simplified algorithm of the program for generating the numerical control files is showed in figure 1. Recent Advances in Manufacturing Engineering ISBN: 978-1-61804-031-2 315

New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

  • Upload
    lycong

  • View
    224

  • Download
    1

Embed Size (px)

Citation preview

Page 1: New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

New Software to Generate the CNC Code For Turning Operations

R.T. CURTA, N. BÂLC, A. CAREAN Dept. of Manufacturing Engineering Technical University of Cluj-Napoca

B-dul Muncii, 103-105, 400641 Cluj-Napoca ROMANIA

[email protected] Abstract: - The paper presents a new computer aided manufacturing software, called PASCON. The PASCON software has been developed by using the AutoLISP software, which is one of the ” built-in” programming tools of the AutoCAD software. The CNC files can be obtained both for the partially geometrically/ constructively defined piece and for the finished piece for which the technological documentation is to be developed. A case study is presented, using the PASCON program, to test its compatibility with other CAM systems and with Lynx 220 CNC Turning Center, with Fanuc OI-TB controller.

Key-Words: - CAD-CAM, CNC, turning, AutoLISP, AutoCAD.

1 Introduction Acknowledgement: This research was supported by the national research grant BIOMAPIM, PCCE - ID 101, contract nr. 5/2010. This paper presents a new method, which is an original software program for the assisted generation of the numerical conduct files for turning processing jobs. In the past few years, the so-called Low Cost CAD systems, where the software for generating CNC files which is to be presented in the following chapters also belongs, have thoroughly spread in the world technology. The main reason for the spread of these low cost programming packages is the fact that they allow the development of open information systems, which on their turn may be configured depending on the requirements, the needs and the facilities of the user. This is also one of the main reasons why the author has chosen the development of the PASCON System (Assisted Programming of the Lathes with Numerical Command).

2 PASCON Software Development The methodology for the development of the CNC files is based on a series of programs with very complex algorithms, both for the pieces that are in an intermediate constructive design state and for the finished pieces. The current PASCON software for generating CNC files is a very flexible one, and has been developed in such a manner so as to allow, when needed, for the implementation of the third axis of the numerical command machine. Currently, the software has been

encoded depending on the Fanuc OITB postprocessor of the Lynx 220 turning centre, which belongs to the TCM department of the Machine Construction Faculty from Cluj-Napoca. 2.1 The algorithm for the PASCON software

The simplified algorithm of the program for generating the numerical control files is showed in figure 1.

Recent Advances in Manufacturing Engineering

ISBN: 978-1-61804-031-2 315

Page 2: New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

Figure 1. Logic diagram of PASCON program CNC files generated by PASCON software are automatically written in the Notepad text editor, and will be saved in the “Programe CNC” folder.

2.2 The processing of the necessary data from

the CAD stage

Generally, it is required a series of information and exper-tise in order to develop the numerical control programs for the machines, and some of these are: • CNC equipment language; • Geometrical information in order to describe

the configuration of the piece; • Technological information, especially about

the parameters of the chipping rate: revolution/ cutting speed, feed, cutting depth, the type of the tool used, etc;

• Auxiliary information. The geometrical information of the piece, necessary for generating the CNC program with the help of the PASCON software, are detained as extended data attached to the lists stored in the database of the RFD program. If the 3D or the 2D drawing of the piece which is to be processed has been imported from another 3D modelling program (SolidWorks, Inventor, CATIA, etc ), the geometrical information that is needed will be accessed with the help of the PASCON program during the process of the actual generation of the CNC file of the machine. Regarding the technological data, important in developing the processing sequences, these will be detained during the ”interaction” between the user and the interface of the PASCON program, as it will be shown in the following chapters.

.

3 Using the PASCON Software. Case

study. 3.1 The loading of the PASCON program

In order to use the PASCON program, all the dcl, text and lisp type files must be copied in a separate folder, which we name PASCON. After loading the AutoCAD program, we will open the drawing of the piece we want to generate the CNC turning program for. After opening the drawing, so as to load the main program, you have to write in the prompter command of the AutoCAD the command: appload (command which accomplishes the loading of the applications), and then, by pressing the « Load » button, you will select all the LISP files you want to load from the PASCON folder (at first we will only load the CNC.1sp file). 3.2 Creating a new CNC code file

In order to create a new CNC file, you have to access a function defined by the author in the PASCON program, called <NEWFILE>, from the prompter command of the AutoCAD program. As it can be seen in figure 2, accessing the function makes a window show up with the message: ”Type in the name of the CNC program”. In the right side of the figure, you can notice the piece for which the CNC program is to be generated for.

Figure 2. CNC file creation

If we want to open a numerical command file that already exists, in order to add a processing sequence

Recent Advances in Manufacturing Engineering

ISBN: 978-1-61804-031-2 316

Page 3: New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

or to change the CNC programme of a piece, we will use the <ADDTOFILE> (Figure 3) command.

Figure 3. Adding/modifying an existent CNC file

3.2 The generation stage of the CNC program

In order to better explain the ways in which the numerical command programme is generated, we will take for example the processing of the piece in figure 4. The initial semi product has a diameter of Φ80 mm and a length of 100mm.

Figure 4. Workpiece

The yellow part of the piece in the figure is the one we will generate the CNC turning programme for. The next processing steps will follow:

- the first stage will be roughing the front of the piece;

- longitudinal roughing of the piece; - longitudinal finishing stage.

After loading the programme, we will create the new CNC file with the name ”sphere programme”. The next function we will access is called < STARTUP >. As it is well-known, there are some parts of a numeric command programme where several code lines are always the same. A good example is the beginning of the CNC turning programmes, when you access some functions every time, like the establishing of the coordinates system (G54), cancelling the radius correction of the machine (G40), limiting the revolutions (G50), or the movement in the point where the machine changes

and so on. Each type of process, where the changes are limited or non-existent, has been created and integrated into the PASCON software with the help of a LISP function. If we had more CNS lathes with different controllers, which would require another code, LISP functions could be created for each equipment separately.

Figure 5. CNC file after calling STARTUP function The CNC program resulted after accessing the STARTUP function, and the drawing of the piece are being shown in figure number 5. The lines in red are the only trajectories of the machine that we need in order to finish generating the CNC program. Following this, there is the procedure to change the machine tool, defined by a function called by the author <TOOLCHG>. You type in the name of the tool (Fig.6), and then you press ”Enter”. The same is done for the tool position and tool table, the same is done for the spindle speed and the feed. In figure number 11, you can notice the CNC program for the piece, generated until the changing of the tool, according to the values introduced, as it can be seen in figures 6-10.

Figure 6. TOOLCHG command: The name of the

tool

Figure 7. Tool position

Recent Advances in Manufacturing Engineering

ISBN: 978-1-61804-031-2 317

Page 4: New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

Figure 8. Tool table number

Figure 9. Spindle speed

Figure 10. Feed introduction

Figure 11. CNC file created in this stage

Roughing the front of the piece follows.

Figure 12. Necessary points to determine the tool

path As it can be seen in figure 12, in order to achieve this roughing, we need to close in to the piece with the tool, in rapid feed mode, in point 1 in the figure. The movement in point 1, with rapid feed, will be achieved by accessing the function named by the author <G0>. When accessing this function, the message ”Select the point” will shop up in the prompter of the AutoCAD, and attached to the mouse as well. We have to move from Point 1 to Point 2 in working progress, by accessing the linear interpolation

named <G1> and selecting point 2 on the screen with the mouse. The construction of function G1 resembles that of function G0, with the difference that the first, after the final point of the movement has been selected, writes the program line in the numeric command file, and then allows for the selecting of the next point needed to define the full path of the tool, not needing to access again the function through the command G1. We will do the same for Point 3 (command G1) and Point 4 (command G0). The PASCON program offers the possibility to use compatible processing cycles on the CNC turning centre Lynx 220 – FANUC 0i-TB. The required command in order to access the function that defines the longitudinal roughing cycle (G71) is < DEGROSARE > (Fig. 13 – 20).

Figure 13 The introduction of the cutting depth

Figure 14 Withdrawal size at 45° (X and Z axis)

Figure 15 No. of the first phrase of the contour

Figure 16 No. of the last phrase of the contour

Figure 17 Finishing cutting depth allowance (X

direction)

Figure 18. Finishing cutting depth allowance (Z

direction)

Recent Advances in Manufacturing Engineering

ISBN: 978-1-61804-031-2 318

Page 5: New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

Figure 19. Feed introduction

Figure 20. Cutting speed

After all the data required to generate the processing cycle has been introduced, which is shown in figures 13-20, the PASCON programme will transmit the generated CNC programme lines to the numeric command file. Now we have to select the outline of the piece which is to be processed, for the roughing stage, between Point 4 and Point 5 (Fig. 2.25) as it follows: � we will move in linear working progress

(command G1) up to point A, which is selected with the mouse;

� a circular interpolation anti-clockwise follows (the < G3 > command is used) until point B, which is the final point of the circular arc sector;

� a clockwise circular interpolation (command < G2 >) up to point C, which is selected after introducing the command, in the same way as it was for function G3;

� again an anti-clockwise circular interpolation (G3 command), and then point D is selected;

� a linear interpolation with G1 command until point E;

� the last movement of the machine will be made by simply selecting Point 5.

Figure 21. Setting the tool path at roughing

After selecting the full outline of the piece for the roughing stage, the PASCON program function called <NFINAL> will be accessed, which has the purpose of introducing into the CNC file the numbering of the final phrase of the cycle.

At this point, the longitudinal roughing stage of the piece is finished and we can move with the tool to its changing point, by using the G0 command. The finishing stage of the piece follows, and for this we will have to change the roughing tool with a finishing tool. We will access the < TOOLCHG > command and run in the parameters of the machine as it was shown in figures 6-10. We will move in rapid progress to Point 4 by using the G0 command, and then we will type into the prompter the command <FINISARE>, which accesses the function of the finishing processing cycle of the PASCON program. The only information that needs to be introduced when accessing this function are the number of the phrase where the finishing starts from, and the number of the phrase where the finishing ends (Fig. 22).

Figure 22. Finishing cycle

Because the finishing stage is the last one in the processing of the given piece, all that is left to do in order to finish the numeric command program and to send it into the CNC file, is to access the function <FINAL>, which sends the tool to its changing point, cancels the radius corrections, if these have been made, and closes the program. In order to change the generated CNC file, the command < CLOSEFILE > is introduced. The full CNC file of the processing is shown in figure 23.

Figure 23. Complete CNC file, generated with

PASCON software

Recent Advances in Manufacturing Engineering

ISBN: 978-1-61804-031-2 319

Page 6: New Software to Generate the CNC Code For Turning · PDF fileNew Software to Generate the CNC Code For Turning Operations ... which is one of the ” built-in” programming ... systems

Figure 24. Sequence during the finishing phase

4 Conclusions The Assisted Programming of the Lathes with Numerical Command Software (PASCON), developed by the author in the purpose of the assisted generation of the numeric conduct files for turning operations, together with the with technological featured designing program RFD (Răzvan Feature Design) make up a Low Cost CAD/CAM program package that has been configured according to the requirements, the needs and the facilities of a certain type of client. The current PASCON program is a very flexible one, easy to use, and has been developed in such a manner so as to allow, if needed, the implementation of the third axis of the numeric command machine. The working time for the designing of the CNC turning code has been cut down as compared to using other CAM softwares, and the resources of the PC do not need to be so high.

References:

[1] *** www.autolisp.com [2] *** Fanuc Oi-Tb, Manual.

Recent Advances in Manufacturing Engineering

ISBN: 978-1-61804-031-2 320