mirror of
https://github.com/MarlinFirmware/Marlin.git
synced 2024-11-27 22:08:02 +00:00
Fix broken direction signal of ADVANCED and LIN_ADVANCED
Remove a setting proccess of E direction in advance_isr()
This commit is contained in:
parent
ff38a3c3b1
commit
8692748ecd
@ -299,16 +299,14 @@ void Stepper::set_directions() {
|
||||
SET_STEP_DIR(Z); // C
|
||||
#endif
|
||||
|
||||
#if DISABLED(ADVANCE)
|
||||
if (motor_direction(E_AXIS)) {
|
||||
REV_E_DIR();
|
||||
count_direction[E_AXIS] = -1;
|
||||
}
|
||||
else {
|
||||
NORM_E_DIR();
|
||||
count_direction[E_AXIS] = 1;
|
||||
}
|
||||
#endif //!ADVANCE
|
||||
if (motor_direction(E_AXIS)) {
|
||||
REV_E_DIR();
|
||||
count_direction[E_AXIS] = -1;
|
||||
}
|
||||
else {
|
||||
NORM_E_DIR();
|
||||
count_direction[E_AXIS] = 1;
|
||||
}
|
||||
}
|
||||
|
||||
// "The Stepper Driver Interrupt" - This timer interrupt is the workhorse.
|
||||
@ -683,9 +681,6 @@ void Stepper::isr() {
|
||||
old_OCR0A += eISR_Rate;
|
||||
OCR0A = old_OCR0A;
|
||||
|
||||
#define SET_E_STEP_DIR(INDEX) \
|
||||
E## INDEX ##_DIR_WRITE(e_steps[INDEX] <= 0 ? INVERT_E## INDEX ##_DIR : !INVERT_E## INDEX ##_DIR)
|
||||
|
||||
#define START_E_PULSE(INDEX) \
|
||||
if (e_steps[INDEX]) E## INDEX ##_STEP_WRITE(INVERT_E_STEP_PIN)
|
||||
|
||||
@ -695,17 +690,6 @@ void Stepper::isr() {
|
||||
E## INDEX ##_STEP_WRITE(!INVERT_E_STEP_PIN); \
|
||||
}
|
||||
|
||||
SET_E_STEP_DIR(0);
|
||||
#if E_STEPPERS > 1
|
||||
SET_E_STEP_DIR(1);
|
||||
#if E_STEPPERS > 2
|
||||
SET_E_STEP_DIR(2);
|
||||
#if E_STEPPERS > 3
|
||||
SET_E_STEP_DIR(3);
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// Step all E steppers that have steps
|
||||
for (uint8_t i = 0; i < step_loops; i++) {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user