Gmoccapy Plasma - the plasma version of Gmoccapy
As with the main GUI, the plasma screen is designed to be used with a touch screen and is thus optimized for touch
It can however be used with keyboard and mouse
-
- 1. Requirements
-
- 2. Some background on Plasma operations
-
- 3. THC - Torch Height Control
-
-
- 3.1. What is THC
-
- 3.2. How does it work
-
- 3.3. THC methods
-
-
- 3.3.1. Gcode driven approach
-
3.4. HAL configuration files and components
-
- 3.5. HAL Component approach
-
4. Plasma GUI
-
-
- 4.1. Control functions
-
-
- 4.1.1. Signals
-
- 4.1.2. Control
-
- 4.1.3. Limits
-
- 4.1.4. Cutting
-
- 4.1.5. Piercing
-
- 4.1.6. Corner Lock
-
- 4.1.7. THC Voltage
-
5. INI file settings
-
1. Requirements
Please refer to the Gmoccapy page for detailed requirements.
[gmoccapy wiki page]
The plasma screen has been included in the latest master branch. It can be found under the sim directory.
You will be required to copy all the relevant files to your config. More on this later.
2. Some background on Plasma operations
Plasma operations on CNC machines is a bit of an orphan process.
When cutting metal with a flame, the uneven heating up of the metarial will cause the sheet to bend and buckle. To start with, most sheets of metal does not come out of the mill or press in a very even or flat state. Thick sheets (30mm plus) can be out of plane as much as 50mm to 100mm.
Most CNC gcode programs will start from a know reference or a piece of stock that has a know size and shape. Gcode is written to rough the excess of and finally cut the finished part.
With plasma the unknown state of the sheet makes it impossible to generate gcode that will cater for these variances in the material.For this reason the THC ( Torch Height Control ) concept was designed. More detail on THC later in the document.
The purpose of the THC function is to make sure that the torch remains at a certain height above the work piece. Not having gcode to do this, one has to interject somewhere in the control loop to get the Z axis to track the material height. By nature of this statement it is clear that plasma and THC does not adhere to the rules for normal CNC and has to be treated with caution.
Suffice to say that it is almost impossible to do decent production plasma cutting without a proper THC system implemented.
3. THC - Torch Height Control
3.1. What is THC
THC is a method devised to control the height of a plasma torch while cutting sheet metal under full control of a cnc system. Due to the fact that the metal constantly changes it shape while being cut, it is necessary to track the surface of the metal in order to get the best possible cut results.
3.2. How does it work
Several things has to happen in order for a THC system to have all the required information, input and output, to make things happen correctly. The plasma torch is lifted as high as possible and still make a good arc when we pierce. This is called pierce gap. Then the torch is dropped to a pre-set height in order to give the best possible cut results for the given material. This will save the consumables as there is a lot of molten metal that comes off the top of the material when piercing. Once this arc is established, the cutting can commence and at this point the normal cnc procedures take over and we track the material surface by means of measuring the Tip Voltage of the plasma cutter.
The process is as follows:
- Get to know where the material is located.
- Set the correct piercing height.
- Turn on the torch.
- Wait for a good arc
- Measure the arc voltage
- Commence Gcode move
- Look at Arc voltage level
- If the voltage is to low - lift the torch or if to high drop the torch
All of these things happen outside of the normal gcode arena. That means we will have some component that does all this work as well as create an interface to some hardware that will in turn interface with the plasma equipment. Well that is not all entirely true as it depends on how you implement your THC functionality. In the next section we will deal with the various methods of control.
3.3. THC methods
There are two approaches when it comes to THC. Both of these will involve external hardware to interface with the plasma equipment.
3.3.1. Gcode driven approach
When this method is applied the user generally has to ensure that the gcode program contains all the required sub routines to do material probing.
Typically something like this:
Example 1
o<touchoff> sub
(#1 pierce height, #2 pierce delay, #3 cut height, #4 switch offset)
F500
G38.2 Z-300 (Probe to find the surface)
G92 Z-30
G38.4 Z5
G91
G1 Z#4 (Raise up to Offset)
G90
G92 Z0 (Set Z0)
G1 Z#1
M3 S1
M66 P0 L3 Q5 (Wait for Arc OK from Torch)
G4 P#2 (Pause for pierce delay)
F500
Z#3 (goto cut height)
o<touchoff> endsub
M2
Example 2
o<touchoff> sub
(#1 pierce height, #2 pierce delay, #3 cut height)
#<arc-fails> = 0
F40
o100 do
G38.2 Z-1.25 (Probe to find the surface)
G91
G1 Z0.185 (Raise up to Z0)
G90
G92 Z0 (Set Z0)
G1 Z#1 (Raise to pierce height)
M3 S1 (Fire torch)
M66 P0 L1 Q2 (Wait 2 seconds for Arc OK from Torch)
o200 if [#5399 EQ -1] (Check to see if torch failed to fire)
(MSG, Arc Fail)
M5
#<arc-fails> = [#<arc-fails> + 1]
o300 if [#<arc-fails> GT 3.0000] (Check if torch has failed 4 times in a row)
Z2.0000 (raise torch high enough to change consumables)
#<arc-fails> = 0 (reset arc failure counter)
M1 (pause)
o300 endif
o200 endif
o100 while [[#5399 EQ -1]]
G4 P#2 (Pause for pierce delay)
F25
Z#3 (goto cut height)
o<touchoff> endsub
M2
This two pieces of code will probe the surface of the material and adjust the Z axis to the correct pierce height. It will start the torch and check for ARC_OK signal. If the ARC_OK fails, as in the case of the second piece of code, it will retry several times after which it will abort the operation.
These are examples and might contain errors. Please check them before using.
3.4. HAL configuration files and components
This method uses HAL configuration files and components to discretely connect and create a control system. There are several examples on the wiki and although they work mostly for the creators, it is not an easy way to start. These configurations are very complex and only the brightest of scientists seem to get them going. Although I would like to understand the implementation of some of these, I am afraid the time required to do is just not available.
3.5. HAL Component approach
With this method we write a HAL component that does all the controlling of the THC process. This is the preferred method as it can easily adapt to most THC hardware without much trouble.
4. Plasma GUI
The Gmoccapy_plasma GUI is written to accommodate most of the preferred implementations of THC and general plasma cutting. It does not require any of the plasma functions, with exception of the torch_on function, to operate normally.
You will notice from the screen above that some of the normal cnc functions are not present or are replaced with another functions. In the next couple of sections I will explain the function of every program group. I will try and expand on the application of each as well.
4.1. Control functions
The control functions are grouped in program or logical groups in order to make it simple to operate.
4.1.1. Signals
- FloatSw? - This LED indicated the condition of the float switch. The float switch is located on the Z axis. The torch mounting should be floating in the sense that the torch can be pushed upwards until a switch is reached. When the switched is closed the THC component will deduct the switch distance from the reading and calculate the material location in the Z plane. The switch distance or travel is a setting that is found in the INI file. It is obtained by letting the torch head hang free. The distance from the torch to table is measured as a reference. Now push the head upwards until the switch is made. Keep that position and measure the distance from the table again. The switch travel is calculated by deducting the reference measurement from the second measurement. Remember that answer and enter it in the INI file.
- Torch On - This signal will indicate when the TORCH_ON request has been given to the plasma equipment.
- Arc Ok - When the plasma has fired up and the conditions for the flame is correct, the plasma or THC equipment will pass a signal indicating that the arc is OK. The THC and other components will look at this signal to determine if they should function or not.
- Z Up - This is a signal that is passed on from the THC to tell the control component to lift the torch as it is to low.
- Z Down - This is a signal that is passed on from the THC to tell the control component to drop the torch as it is to high.
- Cnr Lock - This LED will show when the corner lock function has been activated. More about this later.
4.1.2. Control
4.1.3. Limits
4.1.4. Cutting
4.1.5. Piercing
4.1.6. Corner Lock
4.1.7. THC Voltage
5. INI file settings