Wait for Cooling Bed?

Hi All,

Is there a way to wait for the heat-bed to reach a cooler temperature?

I need to turn cooling fans on, then wait for the bed to reach 25C, then turn the fans off.

I have tried M190 and M116 but both only wait if the desired temperature is higher than the current temperature. If the desired temperature is lower then it returns immediately...

Any ideas?

Thank you,
Errol

Comments

  • Only idea is G4 to wait for the time needed. With some testing you should now how long it takes to cool down enough.

    Cooling down to 25 in summer could be an endless loop if it would work.
  • I was hoping to stay away from a fixed wait period. The parts unstick very rapidly blow 30C, but stick very well above 30C. I must be sure that the temp is low enough before the code continues, but I can build in enough leeway...

    I guess not waiting for a lower target temp is so that setting bed to 0C does not actually wait for the bed to freeze... :)

    Thank you,
    Errol

  • It is easy to modify M190. It's in commands.cpp and in 0.92 looks like this

        case 190: // M190 - Wait bed for heater to reach target.
    #if HAVE_HEATED_BED
            if(Printer::debugDryrun()) break;
            UI_STATUS_UPD(UI_TEXT_HEATING_BED);
            Commands::waitUntilEndOfAllMoves();
    #if HAVE_HEATED_BED
            if (com->hasS()) Extruder::setHeatedBedTemperature(com->S,com->hasF() && com->F > 0);
    #if defined(SKIP_M190_IF_WITHIN) && SKIP_M190_IF_WITHIN > 0
            if(abs(heatedBedController.currentTemperatureC - heatedBedController.targetTemperatureC) < SKIP_M190_IF_WITHIN) break;
            EVENT_WAITING_HEATER(-1);
            codenum = HAL::timeInMilliseconds();
            while(heatedBedController.currentTemperatureC + 0.5 < heatedBedController.targetTemperatureC && heatedBedController.targetTemperatureC > 25.0)
            {
                if( (HAL::timeInMilliseconds() - codenum) > 1000 )   //Print Temp Reading every 1 second while heating up.
                {
                    printTemperatures();
                    codenum = previousMillisCmd = HAL::timeInMilliseconds();
                }
                Commands::checkForPeriodicalActions(true);
            }
            EVENT_HEATING_FINISHED(-1);
            UI_CLEAR_STATUS;
            previousMillisCmd = HAL::timeInMilliseconds();
            break;

    All you need to change is the while condition which now exists when heater is over target temp. Simply add a special case 0 and lower bound as well.
  • Thanks, I would never have found that.

    Looks like I must also edit the SKIP_IF_WITHIN part.

    I can just copy the lower limit and convert it to an upper limit. There is already an exclusion for bed temps lower than 25C, so it will not stall on a set temp of 0C for turnoff.

    Thank you,
    Errol

Sign In or Register to comment.