bigtreetech / SKR-2

193 stars 179 forks source link

heatbreak fan where to connect and program in Marlin? #19

Open Simsela opened 3 years ago

Simsela commented 3 years ago

Hello, Can't get any further with my SKR 2 board, this wasn't a problem with my SKR 1.4!

Will the fan on the SKR2 board also be connected to the HE1 and how can I get it controlled in Marlin? or do I have to connect it to a FAN port and how can I control it depending on the temperature?

can someone please help me?

Thanks in advance!

aabeuge commented 3 years ago

I'm not sure if HE1 can be used for a fan like ramps does but it looks like Fan0 or Fan1 is probably the one to use if you want control of it in marlin. All of the SKR-2 pins are defined (aliased) in /Marlin/src/pins/stm32f4/pins_BTT_SKR_V2_0.h which will show you the alias/pin name to look for in the configuration files (look at line numbers 209 through 214). With that you can then reference line numbers 458 through 560) in Configuration_adv.h which appears to be the section that corresponds to your questions. Fan0 is probably the part cooling fan by default so maybe Fan1 might be better for the heatbreak fan. I'm not very familiar yet with PWM controlled fans in Marlin as I'm just another user but hopefully this points you in the right direction.

Simsela commented 3 years ago

I'm not sure if HE1 can be used for a fan like ramps does but it looks like Fan0 or Fan1 is probably the one to use if you want control of it in marlin. All of the SKR-2 pins are defined (aliased) in /Marlin/src/pins/stm32f4/pins_BTT_SKR_V2_0.h which will show you the alias/pin name to look for in the configuration files (look at line numbers 209 through 214). With that you can then reference line numbers 458 through 560) in Configuration_adv.h which appears to be the section that corresponds to your questions. Fan0 is probably the part cooling fan by default so maybe Fan1 might be better for the heatbreak fan. I'm not very familiar yet with PWM controlled fans in Marlin as I'm just another user but hopefully this points you in the right direction.

Hello, Now I understand it and it worked! Many Thanks!

Mito73a commented 3 years ago

Hi, can you can explain to me? The fan for the material always goes to 100% and I cannot control it. Where did you connetted it? on fan0? and in marlin where did you comment? Thank's!!!!!

LTSpenny commented 3 years ago

Could you share how you set it up to work?

StArL0rd84 commented 3 years ago

I'm not sure if HE1 can be used for a fan like ramps does but it looks like Fan0 or Fan1 is probably the one to use if you want control of it in marlin. All of the SKR-2 pins are defined (aliased) in /Marlin/src/pins/stm32f4/pins_BTT_SKR_V2_0.h which will show you the alias/pin name to look for in the configuration files (look at line numbers 209 through 214). With that you can then reference line numbers 458 through 560) in Configuration_adv.h which appears to be the section that corresponds to your questions. Fan0 is probably the part cooling fan by default so maybe Fan1 might be better for the heatbreak fan. I'm not very familiar yet with PWM controlled fans in Marlin as I'm just another user but hopefully this points you in the right direction.

Hello, Now I understand it and it worked! Many Thanks!

Please help us understand exactly how you made it work. In Configuration_adv.h I've set E0_AUTO_FAN_PIN to PB6 (Fan1) and COOLER_AUTO_FAN_PIN to PB7 (Fan0). Preheated printer, But still, the pins refuse to activate. If i switch the pins around (PB6 Fan0) (PB7 Fan1) VsCode throws errors trying to build. Cannot further calibrate the printer untill this is reolved.

hoax78 commented 3 years ago

Found this, hope it's help a bit! https://3daddict.com/marlin-custom-fan-pins/

matthgyver commented 3 years ago

I've same problem. After lot of tests, there is my solution:

Into Marlin/src/pins/stm32f4/pins_BTT_SKR_V2_0.h file :

Into Marlin/Configuration_adv.h file: