Fix MIN/MAX function collision with macros
This commit is contained in:
@ -1291,7 +1291,7 @@ void Stepper::isr() {
|
||||
|
||||
uint32_t interval =
|
||||
#if ENABLED(LIN_ADVANCE)
|
||||
MIN(nextAdvanceISR, nextMainISR) // Nearest time interval
|
||||
_MIN(nextAdvanceISR, nextMainISR) // Nearest time interval
|
||||
#else
|
||||
nextMainISR // Remaining stepper ISR time
|
||||
#endif
|
||||
@ -1404,7 +1404,7 @@ void Stepper::stepper_pulse_phase_isr() {
|
||||
|
||||
// Count of pending loops and events for this iteration
|
||||
const uint32_t pending_events = step_event_count - step_events_completed;
|
||||
uint8_t events_to_do = MIN(pending_events, steps_per_isr);
|
||||
uint8_t events_to_do = _MIN(pending_events, steps_per_isr);
|
||||
|
||||
// Just update the value we will get at the end of the loop
|
||||
step_events_completed += events_to_do;
|
||||
|
Reference in New Issue
Block a user