commit
a0193d0197
1 changed files with 6 additions and 1 deletions
|
@ -972,11 +972,16 @@ inline float Platform::DMix(int8_t heater) const
|
||||||
return dMix[heater];
|
return dMix[heater];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//Changed to be compatible with existing gcode norms
|
||||||
|
// M106 S0 = fully off M106 S255 = fully on
|
||||||
inline void Platform::CoolingFan(float speed)
|
inline void Platform::CoolingFan(float speed)
|
||||||
{
|
{
|
||||||
|
//byte p = (byte)(255.0*fmin(1.0, fmax(0.0, speed))); //this reverts to 0= off, 1 = on if uncommented
|
||||||
|
byte p = (byte)speed;
|
||||||
|
p = 255 - p; //duet v0.6
|
||||||
if(coolingFanPin < 0)
|
if(coolingFanPin < 0)
|
||||||
return;
|
return;
|
||||||
analogWrite(coolingFanPin, (uint8_t)(speed*255.0));
|
analogWriteNonDue(coolingFanPin, p);
|
||||||
}
|
}
|
||||||
|
|
||||||
//inline void Platform::SetHeatOn(int8_t ho)
|
//inline void Platform::SetHeatOn(int8_t ho)
|
||||||
|
|
Reference in a new issue