Skip to content

Commit

Permalink
allow merge sooner
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed May 17, 2024
1 parent 551dfa2 commit 7c6daa7
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Marlin/src/module/planner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -797,6 +797,10 @@ void Planner::calculate_trapezoid_for_block(block_t * const block, const_float_t
uint32_t initial_rate = CEIL(block->nominal_rate * entry_factor),
final_rate = CEIL(block->nominal_rate * exit_factor); // (steps per second)

// Keep existing kludge against acceleration spikes until #27035
NOLESS(initial_rate, MIN(120, block->nominal_rate));
NOLESS(final_rate, MIN(120, block->nominal_rate));

// Limit minimal step rate (Otherwise the timer will overflow.)
NOLESS(initial_rate, MINIMAL_STEP_RATE);
NOLESS(final_rate, MINIMAL_STEP_RATE);
Expand Down

1 comment on commit 7c6daa7

@mh-dm
Copy link
Contributor

@mh-dm mh-dm commented on 7c6daa7 May 17, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was suggested before #27089 (pulled out from #27035) was merged.

Please sign in to comment.