Monitor bed heating?
-
Hi
there is a possibility to monitor the bed heating ?
I only want to run the fan for the Mosfet of the bed heater when the bed heater is switched on -
Set up a thermostatic fan linked to the bed heater at a specific temperature.
see: https://duet3d.dozuki.com/Wiki/Gcode#Section_M106_Fan_On
-
Hello bot
I know that.
But I would like a query whether the heating is ON or OFF -
void controllerfan_update() {
static millis_t lastMotorOn = 0, // Last time a motor was turned on
nextMotorCheck = 0; // Last time the state was checked
const millis_t ms = millis();
if (ELAPSED(ms, nextMotorCheck)) {
nextMotorCheck = ms + 2500UL; // Not a time critical function, so only check every 2.5sconst bool xory = X_ENABLE_READ() == X_ENABLE_ON || Y_ENABLE_READ() == Y_ENABLE_ON; // If any of the drivers or the bed are enabled... if (xory || Z_ENABLE_READ() == Z_ENABLE_ON #if HAS_HEATED_BED || thermalManager.temp_bed.soft_pwm_amount > 0 #endif #if HAS_X2_ENABLE || X2_ENABLE_READ() == X_ENABLE_ON #endif #if HAS_Y2_ENABLE || Y2_ENABLE_READ() == Y_ENABLE_ON #endif #if HAS_Z2_ENABLE || Z2_ENABLE_READ() == Z_ENABLE_ON #endif #if HAS_Z3_ENABLE || Z3_ENABLE_READ() == Z_ENABLE_ON #endif #if E_STEPPERS #define _OR_ENABLED_E(N) || E##N##_ENABLE_READ() == E_ENABLE_ON REPEAT(E_STEPPERS, _OR_ENABLED_E) #endif ) { lastMotorOn = ms; //... set time to NOW so the fan will turn on } // Fan off if no steppers have been enabled for CONTROLLERFAN_SECS seconds controllerfan_speed = (!lastMotorOn || ELAPSED(ms, lastMotorOn + (CONTROLLERFAN_SECS) * 1000UL)) ? 0 : ( #ifdef CONTROLLERFAN_SPEED_Z_ONLY xory ? CONTROLLERFAN_SPEED : CONTROLLERFAN_SPEED_Z_ONLY #else CONTROLLERFAN_SPEED #endif );
-
Just like in Marlin
-
Using RRF3 you could do that in the daemon.g file.
-
Maybe I don't understand the question well,
but when the SSR is enabled (ie the bed is heating) you can simply setup a thermostatic trigger to enable the fan like
M106 P1 T40 H0
(change P1 to your actual fan output) -
@dc42 : I don't find any docs for daemon.g except for this tweet of yours