Tapping in Cambam, is it possible ?
If so what do I need ?
I'm running a PCNC 1100 series II Tormach. Currently using turbocad, emachine shop (for simple things). I really like CB, but need a tapping op pretty bad...
Tapping in Cambam, is it possible ?
If so what do I need ?
I'm running a PCNC 1100 series II Tormach. Currently using turbocad, emachine shop (for simple things). I really like CB, but need a tapping op pretty bad...
[copied from reply on CamBam forum]
If your hardware supports it, you might be able to do this using a custom drill script and a G84 canned cycle.
So in the drilling machine operation, set the DrillingMethod=CustomScript,
Then in the CustomScript, enter something like
G84 X$x Y$y Z$z R$r
To get the right pitch, you need to calculate the correct feedrate and spindle speed manually.
For example, if your pitch is 20 tpi, for 1 turn of the spindle, you would need to feed 1/20".
So if your spindle speed is fixed at 300rpm, your plunge feedrate would be
300/20 ipm ie 15ipm.
So in the drill mop you would set SpindleSpeed=300 and PlungeFeedrate=15.
However, for this to work your machine needs to be able synchronise your spindle and feedrates which usually means some form of feedback from the spindle.
I should also point out, I haven't tried this myself, so if anyone else sees any flaws with the above, please shout out! ...erm, and wear protective helmets/trousers and practice on a piece of foam/mdf first. Roll Eyes
Another method planned is to use a thread cutting tool and mill the threads using a spiral toolpath, which shouldn't need spindle speed / feed synchronisation. The plan is to add this over the next couple of releases.
I hope this helps.
www.cambam.co.uk
Hi 10 Bulls,
Thank you for writing back, I've uploaded my code. I've got two different mops needed, 5mm tap and a 1/4" 20 tap
Is there anyway you or anyone here can show me how ? The thing that's got me confused is how to tell the machine to stop at Z -0.375", then reverse back out to Z 1.5"..... I noticed when using a hand drill and a vise the tap seems to guide itself, so this would be the same with the machine right ?
This is from the Tormach manual
http://www.tormach.com/machine_codes.html
Self-reversing Tapping Cycles
Details:
To use the Tormach Auto-reverse tapping heads program M871 P~ (or M872, M873, M874)
The P word specifies the depth to be threaded relative to the current Z position which will typically be just clear of the workpiece surface. The P word can be negative or positive with the same meaning.
Before use of these codes the size of tapping head to be used and the pitch of the thread must be defined in the appropriated place on the Settings screen. If the part program is running in Inch (G20) mode then the pitch is taken as a number of threads per inch. If it is metric (G21) then the pitch will be in millimeters. If the spindle speed is too high for the chosen pitch then an error message will be displayed and the cycle will not be performed.
The cycle operates as follows:
The currently set spindle speed and thread pitch are used to calculate the feed rate required to move the tap at the correct speed. The corresponding feedrate for the high speed retraction of the tap is also calculated. If this exceeds the available rapid rate then an error is displayed.
The tap is then fed downwards for the commanded depth (P word).
At the end of the down-feed the spindle is rapidly retracted by the appropriate distance for the size of the head in use. This engages the reverse drive.
The spindle is then retracted, at the higher reverse rate previously calculated, for a distance sufficient to ensure the tap springs clear of the hole.
The Z axis is then positioned at the original height above the work ready to move to another hole or another tool and operation.
Note:
• The above explanation is slightly simplified from the actual code used to aid understanding.
• For best results, especially for deep holes and blind tapping, the spindle speed chosen should be checked with a tachometer to ensure it is as near the commanded (S word) speed as possible.
My G-Code File
( This file was created automatically using CamBam )
( http://www.brusselsprout.org/CAMBAM )
( 4/21/2010 5:36:50 PM )
( T1 : 0.125 )
( T2 : 0.125 )
( T3 : 0.19685 )
( T4 : 0.125 )
G20
G90
G64
G00 Z2
( MOPDrill_2 )
( T1 : 0.125 )
M06 T1
M03
G83 X0.41426 Y0 Z-0.375 R2 F3 Q-0.125
G83 X0.20952 Z-0.375 R2 Q-0.125
G83 X0.00392 Z-0.375 R2 Q-0.125
G83 X-0.3 Z-0.375 R2 Q-0.125
( Pocket (2) )
( T2 : 0.125 )
G00 Z2
M06 T2
M03
G01 F5 X-0.28998
G01 F2 Z-0.05
G02 F5 X-0.30501 Y-0.008677 I-0.01002 J0
G02 Y0.008677 I0.00501 J0.008677
G02 X-0.28998 Y0 I0.00501 J-0.008677
G01 X-0.29498
G02 X-0.30251 Y-0.004347 I-0.00502 J0
G02 Y0.004347 I0.00251 J0.004347
G02 X-0.29498 Y0 I0.00251 J-0.004347
G01 X-0.24498
G02 X-0.32751 Y-0.047648 I-0.05502 J0
G02 Y0.047648 I0.02751 J0.047648
G02 X-0.24498 Y0 I0.02751 J-0.047648
G01 X-0.19498
G02 X-0.35251 Y-0.09095 I-0.10502 J0
G02 Y0.09095 I0.05251 J0.09095
G02 X-0.19498 Y0 I0.05251 J-0.09095
G01 X-0.28998
G01 F2 Z-0.1
G02 F5 X-0.30501 Y-0.008677 I-0.01002 J0
G02 Y0.008677 I0.00501 J0.008677
G02 X-0.28998 Y0 I0.00501 J-0.008677
G01 X-0.29498
G02 X-0.30251 Y-0.004347 I-0.00502 J0
G02 Y0.004347 I0.00251 J0.004347
G02 X-0.29498 Y0 I0.00251 J-0.004347
G01 X-0.24498
G02 X-0.32751 Y-0.047648 I-0.05502 J0
G02 Y0.047648 I0.02751 J0.047648
G02 X-0.24498 Y0 I0.02751 J-0.047648
G01 X-0.19498
G02 X-0.35251 Y-0.09095 I-0.10502 J0
G02 Y0.09095 I0.05251 J0.09095
G02 X-0.19498 Y0 I0.05251 J-0.09095
G01 X-0.28998
G01 F2 Z-0.15
G02 F5 X-0.30501 Y-0.008677 I-0.01002 J0
G02 Y0.008677 I0.00501 J0.008677
G02 X-0.28998 Y0 I0.00501 J-0.008677
G01 X-0.29498
G02 X-0.30251 Y-0.004347 I-0.00502 J0
G02 Y0.004347 I0.00251 J0.004347
G02 X-0.29498 Y0 I0.00251 J-0.004347
G01 X-0.24498
G02 X-0.32751 Y-0.047648 I-0.05502 J0
G02 Y0.047648 I0.02751 J0.047648
G02 X-0.24498 Y0 I0.02751 J-0.047648
G01 X-0.19498
G02 X-0.35251 Y-0.09095 I-0.10502 J0
G02 Y0.09095 I0.05251 J0.09095
G02 X-0.19498 Y0 I0.05251 J-0.09095
G01 X-0.28998
G01 F2 Z-0.195
G02 F5 X-0.30501 Y-0.008677 I-0.01002 J0
G02 Y0.008677 I0.00501 J0.008677
G02 X-0.28998 Y0 I0.00501 J-0.008677
G01 X-0.29498
G02 X-0.30251 Y-0.004347 I-0.00502 J0
G02 Y0.004347 I0.00251 J0.004347
G02 X-0.29498 Y0 I0.00251 J-0.004347
G01 X-0.24498
G02 X-0.32751 Y-0.047648 I-0.05502 J0
G02 Y0.047648 I0.02751 J0.047648
G02 X-0.24498 Y0 I0.02751 J-0.047648
G01 X-0.19498
G02 X-0.35251 Y-0.09095 I-0.10502 J0
G02 Y0.09095 I0.05251 J0.09095
G02 X-0.19498 Y0 I0.05251 J-0.09095
( Pocket (3) )
G01 X-0.279823
G01 F2 Z-0.244
G02 F5 X-0.310089 Y-0.017474 I-0.020177 J0
G02 Y0.017474 I0.010089 J0.017474
G02 X-0.279823 Y0 I0.010089 J-0.017474
G01 F2 Z-0.294
G02 F5 X-0.310089 Y-0.017474 I-0.020177 J0
G02 Y0.017474 I0.010089 J0.017474
G02 X-0.279823 Y0 I0.010089 J-0.017474
G01 F2 Z-0.344
G02 F5 X-0.310089 Y-0.017474 I-0.020177 J0
G02 Y0.017474 I0.010089 J0.017474
G02 X-0.279823 Y0 I0.010089 J-0.017474
G01 F2 Z-0.375
G02 F5 X-0.310089 Y-0.017474 I-0.020177 J0
G02 Y0.017474 I0.010089 J0.017474
G02 X-0.279823 Y0 I0.010089 J-0.017474
( Drill (Tap Insert) ) Here will be a 5mm / 0.19685 tap
( T3 : 0.19685 )
G00 Z0.2
M06 T3
M03
G81 X-0.3 Z-0.233 R3 F0
( MOPProfile_3 )
( T4 : 0.125 )
G00 Z3
M06 T4
M03
G00 Z0.5
G00 Y-0.3325
G01 F2 Z-0.05
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.1
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.15
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.2
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.25
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.3
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.35
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
G01 F2 Z-0.365
G01 F8 X-0.123597
G03 X-0.041097 Y-0.25 I0 J0.0825
G01 Y-0.248579
G01 X0.486863
G03 X0.548528 Y-0.220885 I0 J0.0825
G03 X0.546811 Y0.222801 I-0.248528 J0.220885
G03 X0.485572 Y0.25002 I-0.061239 J-0.055282
G01 X-0.041097
G03 X-0.123597 Y0.3325 I-0.0825 J-0.00002
G01 X-0.3
G03 Y-0.3325 I0 J-0.3325
( MOPProfile_4 )
G01 F5 Y-0.3125
G01 F2 Z-0.375
G01 F5 X-0.123597
G03 X-0.061097 Y-0.25 I0 J0.0625
G01 Y-0.228579
G01 X0.486863
G03 X0.533579 Y-0.207598 I0 J0.0625
G03 X0.531966 Y0.2094 I-0.233579 J0.207598
G03 X0.485572 Y0.23002 I-0.046393 J-0.04188
G01 X-0.061097
G01 Y0.25
G03 X-0.123597 Y0.3125 I-0.0625 J0
G01 X-0.3
G03 Y-0.3125 I0 J-0.3125
G00 Z0.5
M05
M30
Same thread here at CamBam and uploaded my .CB file.
http://www.cambam.co.uk/forum/index....sg5601#msg5601