`ADJUST_M106` - A Comprehensive Part Cooling Modifier

If you have ever tried to save a print with too much or too little part cooling you may have tried the fan slider in Fluidd or Mainsail and been disappointed. Your changes wont stay for long because modern slicers are constantly adjusting part cooling. I had a long think about this, like 6 months, and wrote up 2 other versions of this before arriving here. I wanted something that was very easy to use, just like Extrusion Multiplier and Print Speed overrides. But I also wanted something that could complement the slicerā€™s dynamic fan control. So this is ADJUST_M106:

printer_data/config/part-cooling.cfg

What can ADJUST_M106 do?

  • It can change your fan output by a fixed percentage for the rest of the print: ADJUST_M106 ADJUST=20
  • It can map a range of fan values onto another range. So if you had the dynamic fan set at 50% to 80% you could turn that into 30% to 100%, resulting in more cooling for bridges but less cooling on large layers: ADJUST_M106 ADJUST=50->30|80->100
  • You could even map 0%-100% to a single value making the fan run at that speed only. ADJUST_M106 ADJUST=0->30|100->30
  • The min and max power of the fan can be adjusted on the fly.
  • It knows that 0% means fan off and wont change that behavior unless you ask it to. You can have the fan always off, always on (it understands off_below, always on will be on) or on/off controlled by the slicer.
  • Your tweaks can be disabled and enabled so they can stick around between prints.
  • Tweaks can be cleared with a macro call too.

The readme file has a cookbook section that covers some common part cooling scenarios and gives a sample command for each.

This is still pretty fresh/alpha so Iā€™m looking for feedback from those of you that want to use a tool like this. If there is enough interest Iā€™d like to have a UI for this in Fluidd or KlipperSreen. If you use this please let me know your experience! :beers:

4 Likes

Very good work we really should have more things like this and, less slicer other then toolpathing. never been a fan of things like this hijacking my controls leading to a cancel print.

1 Like

I really need to get around to making a Klipper Screen panel for this. I needed it yesterday but didnā€™t have a quick way to run itā€¦ stay tuned.

I donā€™t see the link to try this macro! Iā€™m struggling with Abs overhangs and bridging. If I run fan at 20 it help a little but 30 is better. Only problem is the print will start to pull up if itā€™s on the whole build. So I am constantly having to babysit the print and it sucks.

Sorry for the link rot :sweat:. The links are fixed now :grinning:

Wow!

This is great! it reminds me of the firmware retraction, but much more useful. Iā€™d really like it if this was implemented like you said.

1 Like

Hello,

I get that it sucks. I have had that happen to. I solved it by adjusting my bridging flow rate and bridge speed.

Hope this helps!
Blake

I have looked at the bridge settings but havenā€™t implemented them. I think itā€™s going to take some time to get right. Mind giving me some settings to start? The default might work but I am unsure

Hello!

I usually run 75mm/s for my bridging speed. 90% for my bridge flow ratio, and fan at 100%. (for bridging)

Usually the bridge flow ratio has the biggest effect. You want to ā€œpullā€ the filament as you bridge, and lowering your ā€œbridge flow ratioā€ setting is how you achieve that. These settings are what I use for PLA btw.

In prusa slicer (what I use) in the cooling section, you can set a general fan speed (the speed used for most of the print) and you can set a bridging speed. Just set your bridging fan speed at 40% (maybe? based on what you said) and for your main print, just run a fan speed that works for you. Something like 15% to 10% would work.

Hope this helps!
Blake

Hello!

btw I responded to your questions about the microswiss ng, sorry abt not responding sooner, I completely forgot about it as it got lost in the feed.

Yes thanks! I have really been looking at learning Super slicer or something other than Cura. Iā€™ll mess with the bridge settings with the flow tuned down. Iā€™ll run some tune prints to see what combinations work best.

Iā€™ll have to look. I thought I recognized your handle. You have been helpful thanks :pray:. What kind of printer are you running

Thanks for the reply. Iā€™m still learning gcode but you explained it well enough that I think I understand how to use it.

Cr-10 V2/V3 their the same thing really. I have a btt manta installed, and of course a microswiss ng.

Hey! Might be a dead thread but I recently tried using these macros but keep getting these errors:

Error evaluating ā€˜gcode_macro SHOW_M106:gcodeā€™: jinja2.exceptions.UndefinedError: ā€˜dict objectā€™ has no attribute ā€˜off_belowā€™

Any advice? Thanks!

Donā€™t piggyback onto an old thread.

Instead, start a new one under ā€œGeneral Discussionā€ and fill out ALL the requested information including your klippy.log.

2 Likes

Just looking at the code:

printer["configfile"]["config"][m106.print_fan].off_below

Its trying to get the off_below value from the config file. Its not a required value. But its also not on the fan object in the printer status.

Usually these fans have to have an off_below value define because they cant run at 1% power. Normally its something like 0.10, or 10%.

You can fix the error by adding the value to the config file:

##  Depending on your fan, you may need to increase this value
##  if your fan will not start.
off_below: 0.10

In the code I need to change this to default to 0.0:

{% set fan_off_below = (printer["configfile"]["config"][m106.print_fan].off_below | default(0.0)) * 100 %}
1 Like

Why not? This post is for one specific set of marcos and in my mind it wouldnā€™t make sense to go make a general post on someoneā€™s specific workā€¦

I see, how do you suggest a fix for this? Would off_below go in the part-cooling cfg or main cfg?

You can definitely link back to this thread but by starting a new one with all the requested information (ie klippy.log - which you will probably be asked for) the process will go much smoother.

1 Like