CNC Fusion 360 Postprocessor
-
Latest update to my Post Processor:
0_1539947384124_reprapduet.cpsList of changes:
- Much more configurable without delving into its code - right in the Post Window of Fusion, you will get a list of options (my own are the default, but change them as you need and Fusion will remember them for you).
- Added more comments that can later be used when the firmware reads the file. I added: Generated By; Generated At (time); Settings Summary (selected material, stock size, number of sections/layers, Tool List); layer start comment before each section (currently this allows easier navigation and more details on the currently viewed file).
Configurable Options added:
- Probe Z Offset - this is the thickness of the probe + 5mm. G30 lifts the head by 5mm, which is where this 5mm comes from.
- Perform Probe - if this is true, a Probe will be performed after each tool change, using G30.
- Perform Manual Tool Change - if this is true, the machine will: go to a safe location, defined using other options; stop the spindle; Request you to change the tool to the defined tool; if set to probe, a probe will be performed; if set to manually set spindle speed, it will be allowed to be set, before continuing with the job.
- Manual Spindle Speed - if true, gives you time to set your spindle's speed to what was requested.
- Tool Change X Position - safe position where a tool change and probe can happen, relative to your job origin.
- Tool Change Y Position - same as for X.
- Spindle On Speed - used if manual spindle speed is true. When defining the spindle, one should define the speed at which it is fully on, not PWM - this is meant to be the same, useful for a relay.
- Makita Spindle - I use a Makita trimmer as my spindle, which have a dial of 1-6 speed settings; this adds the details of which setting to use for the requested speed (now I don't need the speeds table when figuring out what to use).
- Home Z Upwards - if true, it will Home Upwards for tool changes and other Safe retracts.
- Safe Z Height - if Home Z Upwards is false, this is used as a relative height (relative to your current origin).
-
Coincidentally I kind of did the same and also shared my post 5 days ago:
https://forum.duet3d.com/topic/7187/problem-with-setting-working-coordinate-systems/9
I run both of them on the same model and they produce very similar results. The only differences I found were the following (when the tool-probing is deactivated):
- Before the the first operation starts:
Jacotheron:
; layer 1
; (Slot1)
G28 Z
G0 X10 Y10
M291 P"Insert Tool #1 (Dia:10 )" R"Tool Change - Paused" S3 X1 Y1 Z1
M3 S17000
M291 P"28000 RPM (#5 ~26000-[27000]-29000)" R"Spindle Speed" S3 X1 Y1 Z1mine:
;SLOT1
M5 ;Makes sure the spindle is off before the tool change
T1 ;Call Tool 1
M3 S28000 ;Start Spindle at 28000RPM
G54 ;Set the working coordinate systemJacotheron homes the Z-aces first, not sure why. I think normally homing should not be part of a cnc-program. Further he added a tool-change position which can be defined in the fusion post parameters which makes a lot of sense. However I think it should be in absolute machine parameters i.e. something like G53 G0 X10 Y10. Further the max RPMs can be capped using a fusion post parameter which is also cool as well as the comments that are issued regarding the tool change. However I think adding M5 would not hurt as the spindle should be stopped before any tool-change. T1 is missing in my understanding as without calling it the tool-offsets are not set. This might be obsolete if you probe every during the tool change. However I prefer to measure all my tools in before starting machining using tool-offsets. And even when probing during the machining I think it would be more correct to set tool-offsets using M585. Finally I think the right WCS should be called as well.
- Before the second operation
Jacotheron:
; layer 2
; (2D Pocket1)
M3 S17000Mine:
;2D POCKET1The call of M3 S17000 is obsolete as the spindle is already running at the right speed from the first operation. However typically it also does not hurt.
-
Mine is rounding feeds to full numbers as Jacotheron is rounding to one decimal (F333 vs F333.3). Irrelevant...
-
At the end of the program:
Jacotheron :
;
G28 Z
G0 X0 Y0
M5
;%
Mine:
M5I don't understand why G28 Z and G0 X0 X0 should be called here. Adding a G0 X10 X10 (i.e. moving to the tool-change position) would make sense as the tool-change position typically moves the head to a safe place.
Looking at the post-code there are not too many differences as well. So merging the two posts together should not be to hard. I already have mine on github and would be open to do so...
Best regards,
Marc
- Before the the first operation starts:
-
Explaining a few of the differences found.
Homing Z:
For me this is to ensure that we are at a good location, should we need to change tools before the job starts.Using the tool change location as absolute parameters
This makes a lot of sense. I am very new to working coordinate systems and simply needed something that works. I figured using the position relative to where we probe, means it is close by for the manual tool change.Max RPMs being capped
Where do I find that setting in Fusion? In my setup, spindle speeds are simply meant as a guideline, and I have to manually set them. In the M453 command, parameter R is used to specify what speed should result in a full on spindle. I have set it at 17000, and to ensure that my relay does not get PWM when I need it to only be 10000, I have added that extra parameter, which will give the M3 command's S parameter as if it is at full speed, while letting me set it to what I really need.Wizard-style tool change
I might not always be the only person using my machine, so having the tool changes done as easy as possible and clear as to what needs to happen when was something I regarded as important.M5 before tool change
My code should have it in there. I believe it is only missing on the first section, since there is no need for the spindle to be on before that code is run. I like the spindle to only be on when it is actually about to do something.T1 being missing
I defined my tool as T0, which is called inside of the config.g setup file. It is always selected for me.Tool Offsets
Does your CNC have a tool pre-loader? It makes sense if it does. On mine, it is a simple Makita RT0700c trimmer everything is done manually and only a single tool at a time. For some of my jobs, I might have to ensure that the tool is sticking out longer than on other jobs (I know it is not optimal and one should try to get the tool as deep inside as possible, but sometimes I need that extra mm or 2).I still need to research the M585 and see how it changes how I do things now.
Right WCS being called as well
Before starting a job, I perform a full Home, then move the bit to the corner/edge that is used as reference point and set the WCS and XY origin using a macro. Then I start the job.M3 speed on each section
I decided it can't hurt. I have made it so that unless the requested speed is changed, or a new tool is installed, it won't pause the job and ask you to set the new speed.Roundings
This is simply code that was in the original post I started with. Should not really make any difference.Ending
That G0 should also have used the tool change position. For my machine, it homes Z upwards (Zmax), so homing it, ensures that we are safe and it should miss any and all fixtures that might otherwise be in its way.Merging the posts
You are welcome to merge my post into yours - as mentioned above, mine is simply open. Mine is simply my own attempt using my very limited knowledge and experience to get a post that I can use with good enough results. Before starting mine, I tried to find someone else's post to use, but did not find any, so I started learning how to do it. Now it works for me just fine, but if there is a better one, I will abandon mine for the better one. -
Thank you for working on this.
How has everything been working out, any issues with processor for fusion 360
-
@Adamfilip : The post is running very nicely for me for the last few month on various jobs (never had an unexpected behavior out of the post). I recently also put options in that can be selected from within the Fusion post menu for automatic or manual tool change, tool length measurement and re-homing between operations.
Just for completeness here again the link to the github repository:
https://github.com/mwinterm/fusion_post/tree/master/DuetCNC -
I have used this since posting it here, and it is working just fine for me. The issues I found were all user/operator error. If you get any issues, you are welcome to post about it and we can trouble shoot it.
To prevent unexpected behaviour, is the main reason why I explain exactly what I programmed it to do.
Just something to state again, this post does not do arcs (G2 and G3). While the latest firmware (at time of writing), allows one to configure the segments used for these arcs, I simply believe a computer is a lot faster and more precise in those calculations, and since the Duet can read extremely fast from the SD card, more G1 segments does not really affect its speed or quality negatively.
-
hi guys
I'm also develop Fusion 360 post processor. I had been designed for MPCNC and milling from SD card.
Initially it was for Marlin 2.0 only, later I had added Grbl 1.1.
So it's multi target now.
And now I have added RepRap Firrmware (based on Marlin target).
It supports:
manual spindle control or use M3/M5
manual tool changing + measuring the tool with G28 Z
laser mode with using M106/M107 or M3/M5 or M42
controlling of 2 channels of coolant
particular parts of gcode could be replaced by external files -
so if anyone interesting it is here
https://github.com/guffy1234/mpcnc_posts_processor -
@Guffy : nice work, thanks for sharing. Looks very clean, better than the Mach3 template I worked off from. I will eventually try to change to your PP....
-
hi guys
a step forward in the post processor.
i have decided to split the code of pp to 4 files
DIYCNC_Common.js – common code
DIYCNC_Grbl11.cps – code and properties specific to grbl
DIYCNC_Marlin20.cps – code and properties specific to marlin 20
DIYCNC_RepRapFW.cps – code and properties specific to reprap firmware
so now you will see 3 post processors in the Fusion drop down box instead of selecting target firmware in the properties.
as result there is much less messing of properties belong to different firmwares in the properties control -
I know this is an old thread, but just wanted to say THANKS!!! for the post processor. I just upgraded this machine from a mach3 controller and the first post processor I found scared the crap out of me. This ones behaves very nicely, thanks again.
Has anyone tried it with v-carve?
-
@Jacotheron if you save your macros to turn on and off the coolant and whatever as
/sys/M6.g
etc they will be executed as GCode commands. -
@oliof Awesome! Thanks again for the great work. I'm not a great coder so this saved me a ton of headache.
-
@dwak you may still want to peruse the documentation on metacommands so you get an idea how to enable your own codes with parameters
https://docs.duet3d.com/en/User_manual/Reference/Gcode_meta_commands