Welcome! Log In Create A New Profile

Advanced

Is there a delay in marlin on timer 2 used by fan during startup?

Posted by Jmartens1114 
Is there a delay in marlin on timer 2 used by fan during startup?
November 27, 2022 06:18PM
Hi. I’ve been having problems etching with my laser and upon research I’ve come across a couple of sites claiming theres a delay applied to the fan to reduce the surge on the power? I use the fan output as the PWM signal for my diode laser.
I think this may be attributing to my lack of quality. Most of these articles are from 1 to 2 years past. I’m currently working with marlin 2.1. Is or has their been any updates addressing this or is there any official way of dealing with this timer)2) ? In the articles they say that the timer is shared with a temperature sensor and they claim to have to reassign this timer to timer (5). I’m extremely sorry if this is the wrong place to ask but I’m having trouble finding official marlin info being I’m still a newbie.
Thank you for your hard work and time!
Jerry

Edited 1 time(s). Last edit at 11/27/2022 06:22PM by Jmartens1114.
Re: Is there a delay in marlin on timer 2 used by fan during startup?
November 27, 2022 07:23PM
Hi for example here’s an example. Hopefully I’m not violating any rules!
taken from v1engeneers forum:

I will summarize the problem. The more recent versions of Marlin the code that updates the settings for the fan was changed. The change caused it to delay the fan updates. Since many of us use the fan to control our lasers that change causes the laser to turn on and off to early or too late. As you can see in your photo and in the photos in the other Thread BT pointed you to.

Here is the offending code. It is located in the Marlin.cpp file.

// Limit check_axes_activity frequency to 10Hz
static millis_t next_check_axes_ms = 0;
if (ELAPSED(ms, next_check_axes_ms)) {
planner.check_axes_activity();
next_check_axes_ms = ms + 100UL;
}

To fix the problem it needs to be changed to this.

// Limit check_axes_activity frequency to 10Hz
//static millis_t next_check_axes_ms = 0;
//if (ELAPSED(ms, next_check_axes_ms)) {
planner.check_axes_activity(); //< THIS IS THE ONLY LINE OF CODE YOU LEAVE UNCOMMENTED
// next_check_axes_ms = ms + 100UL;
//}

If others have similar issues in marlin you know why. Thanks
Re: Is there a delay in marlin on timer 2 used by fan during startup?
November 27, 2022 09:20PM
There is a FAN_KICKSTART_TIME setting in configuration_adv.h. You can try commenting that out to see if it makes a difference.
Re: Is there a delay in marlin on timer 2 used by fan during startup?
November 28, 2022 06:21AM
Hi thank you for the suggestion! I believe this is disabled in my configuration for the Creality v4.2.7 boards.
Re: Is there a delay in marlin on timer 2 used by fan during startup?
November 28, 2022 06:16PM
Can anybody help a fat old guy trying to just build stuff?
Sorry, only registered users may post in this forum.

Click here to login