PDA

View Full Version : Problem customising post processors



ulexprecision
08-17-2013, 08:27 AM
Hi again,
I have tried to modify a post processor for my needs,but my understanding of the code has let me down.
The biggest issue is the numbers infront of M code and tool change (see sample)
The numbers trigger an error code on the Heidenhain 426 controller.
I don't need the feed in every line,but that happened when I tried to slow the feed down at the start of a plunge.
Some times I would like to slow the feed for a bit longer when the cutter plunges down in an ark.
It would be perfect to have the feedz until the cutter is down at z level and starts material removal.

The 2. problem is the drill cycle.The sample shows what the post prosessor produces and underneath is the hand edited version
how I would like to have it.

I hope there a ways around these things.Thank you for looking at this.
Cheers,
Dirk

Gregore
08-22-2013, 08:33 PM
Have you emailed Joakim at madcam yet? He is uasually very quick at responding to emails. I think he will have no problems finding a solution to your issue.

JOM
08-26-2013, 02:00 AM
Hello Dirk,

It's just to remove all line number "lnbr" commands in the *FIRST_MOVE* section.
Below is a new post processor without line numbers.

/Joakim

//MadCAM_POST_2013-08-26
*VERSION*
1.0_031210
*FILE_NAME*
Heidenhain-430
*FILE_EXTENSION*
h
*FILE_DEST*
c:\postfiles\
*FILTER*
0.005
*OUTPUT_WIDTH*
4
*OUTPUT_DECIMALS*
3
*SCALE_X*
1
*SCALE_Y*
1
*SCALE_Z*
1
*AXIS_1_CHAR*
X
*AXIS_2_CHAR*
Y
*AXIS_3_CHAR*
Z
*CUTTER_REFERENCE*
TIP
*FIRST_MOVE*
L "x""y"FMAX
L "z"FMAX
"coolant_on"
*END_SECTION*
*RAPID*
L "x" "y" "z" FMAX
*END_SECTION*
*RAPID_APPROACH*
L "x" "y" "z" F"feedz"
*END_SECTION*
*RAPID_RETRACT*
L "x" "y" "z" FMAX
*END_SECTION*
*APPROACH*
L "x" "y" "z" F"feedz"
*END_SECTION*
*FIRST_CUT*
L "x" "y" "z" F"feed"
*END_SECTION*
*CUT*
L "x" "y" "z" F
*END_SECTION*
*TOOL_CHANGE*
TOOL CALL "toolnr" Z S "speed" ;TOOL CHANGE ("toolname")
L M03
*END_SECTION*
*TOOLPATH_CHANGE*
;TOOL #"toolnr" CONTINUES
*END_SECTION*
*COOLANT_ON*
M8
*END_SECTION*
*COOLANT_OFF*
M9
*END_SECTION*
*TOOL_STOP*
M9
*END_SECTION*
*PROGRAM_START*
; Post Processor 3-axis
BEGIN PGM "pgmnr" MM
*END_SECTION*
*PROGRAM_END*
M30
END PGM "pgmnr" MM
*END_SECTION*
*LINE_START_NUMBER*
0

Dan B
08-26-2013, 11:05 AM
Hi Dirk,

Sorry I wasn't around to help. I can usually take care of post issues so Joakim can focus on programming. I was on vacation last week. It looks like your original issue is solved now. There is one slight correction I am going to suggest. You will have an issue with the *CUT* feedrate, as it seems the variable "feed" is missing:

*CUT*
L "x" "y" "z" F
*END_SECTION*

It should look like this:

*CUT*
L "x" "y" "z" F"feed"
*END_SECTION*

Or you could get rid of the F altogether as your controller should accept modal feedrates. (from the proceeding lines):

*CUT*
L "x" "y" "z"
*END_SECTION*

It depends on whether you would like to see the feed on every line or not. Personally, I don't.

Dan

ulexprecision
08-27-2013, 07:14 AM
Thank you for all the replies.
I have been on vacation too.
One more question :
I would like to erase the line *TOOLPATH_CHANGE*;TOOL#"toolnr"CONTINUES
It triggers an ERROR message in my controller with and without linenumber infront.
Do I just delete the line including *END_SECTION* ?
Is there still a problem with the drill cycle in MadCam? Something like that was mensioned in another thread before,
or did I do it wrong?
Kind Regards,
Dirk

Dan B
08-27-2013, 09:46 AM
You can delete that line, but it's probably just a character in that comment that is giving your controller problems. Try removing the hash (#) and see what happens.

As for drill cycles, they aren't yet supported in madCAM. Drilling will be "point to point".

Or did I misunderstand the question about drilling?

Dan

ulexprecision
08-27-2013, 10:20 AM
Hi Dan,
In my original request is a txt file with my spotdrilling attempt.
It is point to point but very weird movements were generated.

dirk

Dan B
08-27-2013, 10:25 AM
Sorry, I didn't look past those line numbers that you wanted gone. Can you attach you model that you used? I want to replicate your results with Joakim's post and see if it needs more tweaking.

Thanks,

Dan

ulexprecision
08-27-2013, 08:27 PM
Hi Dan,
Good Morning,now I have attached the model.

Dirk

Dan B
08-28-2013, 08:12 AM
Hi Dirk,

Try this one:

//MadCAM_POST_2013-08-26
*VERSION*
1.0_031210
*FILE_NAME*
Heidenhain-430
*FILE_EXTENSION*
h
*FILE_DEST*
c:\postfiles\
*FILTER*
0.001
*OUTPUT_WIDTH*
4
*OUTPUT_DECIMALS*
3
*SCALE_X*
1
*SCALE_Y*
1
*SCALE_Z*
1
*AXIS_1_CHAR*
X
*AXIS_2_CHAR*
Y
*AXIS_3_CHAR*
Z
*CUTTER_REFERENCE*
TIP
*END_SECTION*
*CUSTOM_VARIABLES*
Fixture offset;fixture_offset;0
*END_SECTION*
*FIRST_MOVE*
L "x""y"FMAX
L "z"FMAX "coolant_on"
*END_SECTION*
*RAPID*
L "x" "y" "z" FMAX
*END_SECTION*
*RAPID_APPROACH*
L "x" "y" "z" FMAX
*END_SECTION*
*RAPID_RETRACT*
L "x" "y" "z" FMAX
*END_SECTION*
*RAPID_FEED*
18000
*END_SECTION*
*TOOLCHANGE_TIME*
.3
*END_SECTION*
*APPROACH*
L "x" "y" "z" F"feedz"
*END_SECTION*
*FIRST_CUT*
L "x" "y" "z" F"feed"
*END_SECTION*
*CUT*
L "x" "y" "z"
*END_SECTION*
*TOOL_CHANGE*
TOOL CALL "toolnr" Z S "speed" ;TOOL CHANGE ("toolname")
L M03
*END_SECTION*
*TOOLPATH_CHANGE*
;TOOL "toolnr" CONTINUES
*END_SECTION*
*COOLANT_ON*
M8
*END_SECTION*
*COOLANT_OFF*
M9
*END_SECTION*
*TOOL_STOP*
M9
*END_SECTION*
*PROGRAM_START*
; Post Processor 3-axis
BEGIN PGM "pgmnr" MM
CYCL DEF 247 DATUM SETTING~
Q339="fixture_offset"
*END_SECTION*
*PROGRAM_END*
M30
END PGM "pgmnr" MM
*END_SECTION*
*LINE_START_NUMBER*
0

I added a few features, such as fixture offset, and some variables for reporting on the post-processor report. If your controller doesn't support CYCLE DEF 247 then just delete that section. You will need to adjust the RAPID speed I used, as it probably differs for your machine. Look in your manual and see what the FMAX speed really is, and use that. The TOOLCHANGE_TIME section represents how long a tool change takes. In my example I used .3 minutes which is 18 seconds. You will need to tweak that value to represent your tool change time. Neither of these will affect the code, they are strictly for reporting.

The biggest issue was that the *CUTTER REFERENCE* section wasn't terminated with an *END SECTION*. Once I added that, the code looked a lot better.

Let me know if this works for you.

Take care,

Dan

ulexprecision
08-28-2013, 09:26 AM
Hi Dan,
Thank you for picking the missing line in the post.I like your new post for the added feature of precise cycle times.
I will try it over the next few days and report results.
That Cycle247 is not supported on my system,I will delete it.
So far I do my datum with a manuell wobbler and manuell data enty.
The machine came with digitising touch probe,
but not enough houres in the day to experiment.
Sadly I have not met anybody with Heidenhain experience in my town
to share some info's. This means every advance takes twice as long.
Cheers,

Dirk

Dan B
08-28-2013, 09:52 AM
Most of our machines (7 Hermles and an Awea) have Heidenhain controllers, but a newer version (iTNC530). Even within that controller there is a range of functionality. For example, only the newer controllers support PLANE SPATIAL for 5-axis rotations, while the older ones use CYCLE 19. I'll try to help you with any Heidenhain questions, but you still may need to tweak the results.

Dan