Commit 7fb4201e authored by Simone Primarosa's avatar Simone Primarosa

Update 4.1.5 dev

parent 9667bff1
### Version 4.1.5 ### Version 4.1.5
* Implemented FAN_SOFT_PWM also for other fan that can be added in configuration_adv file. * Implemented FAST_PWM_FAN and FAN_SOFT_PWM also for other fan that can be added in configuration_adv file.
* Added the ability to set a min speed to the fan that can be added in configuration_adv file. * Added the ability to set a min speed to the fan that can be added in configuration_adv file.
* General bugfix
### Version 4.1.4 ### Version 4.1.4
* Add support for Piggy Alligator board * Add support for Piggy Alligator board
......
...@@ -956,31 +956,47 @@ void tp_init() { ...@@ -956,31 +956,47 @@ void tp_init() {
ANALOG_SELECT(FILWIDTH_PIN); ANALOG_SELECT(FILWIDTH_PIN);
#endif #endif
#if HAS_CONTROLLERFAN
SET_OUTPUT(CONTROLLERFAN_PIN); //Set pin used for driver cooling fan
#if ENABLED(FAST_PWM_FAN)
setPwmFrequency(CONTROLLERFAN_PIN, 1); // No prescaling. Pwm frequency = F_CPU/256/8
#endif
#if ENABLED(FAN_SOFT_PWM)
soft_pwm_fan_controller = fanSpeedSoftPwm_controller / 2;
#endif
#endif
#if HAS_AUTO_FAN_0 #if HAS_AUTO_FAN_0
SET_OUTPUT(EXTRUDER_0_AUTO_FAN_PIN); SET_OUTPUT(EXTRUDER_0_AUTO_FAN_PIN);
#if ENABLED(FAST_PWM_FAN)
setPwmFrequency(EXTRUDER_0_AUTO_FAN_PIN, 1); // No prescaling. Pwm frequency = F_CPU/256/8
#endif
#endif #endif
#if HAS_AUTO_FAN_1 && (EXTRUDER_1_AUTO_FAN_PIN != EXTRUDER_0_AUTO_FAN_PIN) #if HAS_AUTO_FAN_1 && (EXTRUDER_1_AUTO_FAN_PIN != EXTRUDER_0_AUTO_FAN_PIN)
SET_OUTPUT(EXTRUDER_1_AUTO_FAN_PIN); SET_OUTPUT(EXTRUDER_1_AUTO_FAN_PIN);
#if ENABLED(FAST_PWM_FAN)
setPwmFrequency(EXTRUDER_1_AUTO_FAN_PIN, 1); // No prescaling. Pwm frequency = F_CPU/256/8
#endif
#endif #endif
#if HAS_AUTO_FAN_2 && (EXTRUDER_2_AUTO_FAN_PIN != EXTRUDER_0_AUTO_FAN_PIN) && (EXTRUDER_2_AUTO_FAN_PIN != EXTRUDER_1_AUTO_FAN_PIN) #if HAS_AUTO_FAN_2 && (EXTRUDER_2_AUTO_FAN_PIN != EXTRUDER_0_AUTO_FAN_PIN) && (EXTRUDER_2_AUTO_FAN_PIN != EXTRUDER_1_AUTO_FAN_PIN)
SET_OUTPUT(EXTRUDER_2_AUTO_FAN_PIN); SET_OUTPUT(EXTRUDER_2_AUTO_FAN_PIN);
#if ENABLED(FAST_PWM_FAN)
setPwmFrequency(EXTRUDER_2_AUTO_FAN_PIN, 1); // No prescaling. Pwm frequency = F_CPU/256/8
#endif
#endif #endif
#if HAS_AUTO_FAN_3 && (EXTRUDER_3_AUTO_FAN_PIN != EXTRUDER_0_AUTO_FAN_PIN) && (EXTRUDER_3_AUTO_FAN_PIN != EXTRUDER_1_AUTO_FAN_PIN) && (EXTRUDER_3_AUTO_FAN_PIN != EXTRUDER_2_AUTO_FAN_PIN) #if HAS_AUTO_FAN_3 && (EXTRUDER_3_AUTO_FAN_PIN != EXTRUDER_0_AUTO_FAN_PIN) && (EXTRUDER_3_AUTO_FAN_PIN != EXTRUDER_1_AUTO_FAN_PIN) && (EXTRUDER_3_AUTO_FAN_PIN != EXTRUDER_2_AUTO_FAN_PIN)
SET_OUTPUT(EXTRUDER_3_AUTO_FAN_PIN); SET_OUTPUT(EXTRUDER_3_AUTO_FAN_PIN);
#endif #if ENABLED(FAST_PWM_FAN)
setPwmFrequency(EXTRUDER_3_AUTO_FAN_PIN, 1); // No prescaling. Pwm frequency = F_CPU/256/8
#if HAS_CONTROLLERFAN #endif
SET_OUTPUT(CONTROLLERFAN_PIN); //Set pin used for driver cooling fan
#endif #endif
#if ENABLED(FAN_SOFT_PWM) #if ENABLED(FAN_SOFT_PWM)
#if HAS_CONTROLLERFAN
soft_pwm_fan_controller = fanSpeedSoftPwm_controller / 2;
#endif
#if HAS_AUTO_FAN #if HAS_AUTO_FAN
soft_pwm_fan_auto = fanSpeedSoftPwm_auto / 2; soft_pwm_fan_auto = fanSpeedSoftPwm_auto / 2;
#endif #endif
#endif #endif
#if HAS_POWER_CONSUMPTION_SENSOR #if HAS_POWER_CONSUMPTION_SENSOR
ANALOG_SELECT(POWER_CONSUMPTION_PIN); ANALOG_SELECT(POWER_CONSUMPTION_PIN);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment