Prusa MINI Firmware overview
|
Go to the documentation of this file.
44 #include "../inc/MarlinConfig.h"
62 #define ISR_BASE_CYCLES 792UL
65 #if ENABLED(LIN_ADVANCE)
66 #define ISR_LA_BASE_CYCLES 64UL
68 #define ISR_LA_BASE_CYCLES 0UL
72 #if ENABLED(S_CURVE_ACCELERATION)
73 #define ISR_S_CURVE_CYCLES 40UL
75 #define ISR_S_CURVE_CYCLES 0UL
79 #define ISR_LOOP_BASE_CYCLES 4UL
82 #define ISR_START_STEPPER_CYCLES 13UL
85 #define ISR_STEPPER_CYCLES 16UL
90 #define ISR_BASE_CYCLES 752UL
93 #if ENABLED(LIN_ADVANCE)
94 #define ISR_LA_BASE_CYCLES 32UL
96 #define ISR_LA_BASE_CYCLES 0UL
100 #if ENABLED(S_CURVE_ACCELERATION)
101 #define ISR_S_CURVE_CYCLES 160UL
103 #define ISR_S_CURVE_CYCLES 0UL
107 #define ISR_LOOP_BASE_CYCLES 32UL
110 #define ISR_START_STEPPER_CYCLES 57UL
113 #define ISR_STEPPER_CYCLES 88UL
119 #define ISR_START_X_STEPPER_CYCLES ISR_START_STEPPER_CYCLES
120 #define ISR_X_STEPPER_CYCLES ISR_STEPPER_CYCLES
122 #define ISR_START_X_STEPPER_CYCLES 0UL
123 #define ISR_X_STEPPER_CYCLES 0UL
126 #define ISR_START_Y_STEPPER_CYCLES ISR_START_STEPPER_CYCLES
127 #define ISR_Y_STEPPER_CYCLES ISR_STEPPER_CYCLES
129 #define ISR_START_Y_STEPPER_CYCLES 0UL
130 #define ISR_Y_STEPPER_CYCLES 0UL
133 #define ISR_START_Z_STEPPER_CYCLES ISR_START_STEPPER_CYCLES
134 #define ISR_Z_STEPPER_CYCLES ISR_STEPPER_CYCLES
136 #define ISR_START_Z_STEPPER_CYCLES 0UL
137 #define ISR_Z_STEPPER_CYCLES 0UL
141 #define ISR_START_E_STEPPER_CYCLES ISR_START_STEPPER_CYCLES
142 #define ISR_E_STEPPER_CYCLES ISR_STEPPER_CYCLES
145 #if DISABLED(LIN_ADVANCE) && ENABLED(MIXING_EXTRUDER)
146 #define ISR_START_MIXING_STEPPER_CYCLES ((MIXING_STEPPERS) * (ISR_START_STEPPER_CYCLES))
147 #define ISR_MIXING_STEPPER_CYCLES ((MIXING_STEPPERS) * (ISR_STEPPER_CYCLES))
149 #define ISR_START_MIXING_STEPPER_CYCLES 0UL
150 #define ISR_MIXING_STEPPER_CYCLES 0UL
154 #define MIN_ISR_START_LOOP_CYCLES (ISR_START_X_STEPPER_CYCLES + ISR_START_Y_STEPPER_CYCLES + ISR_START_Z_STEPPER_CYCLES + ISR_START_E_STEPPER_CYCLES + ISR_START_MIXING_STEPPER_CYCLES)
157 #define MIN_ISR_LOOP_CYCLES (ISR_X_STEPPER_CYCLES + ISR_Y_STEPPER_CYCLES + ISR_Z_STEPPER_CYCLES + ISR_E_STEPPER_CYCLES + ISR_MIXING_STEPPER_CYCLES)
160 #define _MIN_STEPPER_PULSE_CYCLES(N) _MAX(uint32_t((F_CPU) / (MAXIMUM_STEPPER_RATE)), ((F_CPU) / 500000UL) * (N))
161 #if MINIMUM_STEPPER_PULSE
162 #define MIN_STEPPER_PULSE_CYCLES _MIN_STEPPER_PULSE_CYCLES(uint32_t(MINIMUM_STEPPER_PULSE))
163 #elif HAS_DRIVER(LV8729)
164 #define MIN_STEPPER_PULSE_CYCLES uint32_t((((F_CPU) - 1) / 2000000) + 1) // 0.5µs, aka 500ns
166 #define MIN_STEPPER_PULSE_CYCLES _MIN_STEPPER_PULSE_CYCLES(1UL)
173 #if HAS_DRIVER(LV8729) && MINIMUM_STEPPER_PULSE == 0
174 #define MIN_PULSE_TICKS ((((PULSE_TIMER_TICKS_PER_US) + 1) / 2) + ((MIN_ISR_START_LOOP_CYCLES) / uint32_t(PULSE_TIMER_PRESCALE)))
176 #define MIN_PULSE_TICKS (((PULSE_TIMER_TICKS_PER_US) * uint32_t(MINIMUM_STEPPER_PULSE)) + ((MIN_ISR_START_LOOP_CYCLES) / uint32_t(PULSE_TIMER_PRESCALE)))
180 #define ADDED_STEP_TICKS (((MIN_STEPPER_PULSE_CYCLES) / (PULSE_TIMER_PRESCALE)) - (MIN_PULSE_TICKS))
183 #define ISR_LOOP_CYCLES (ISR_LOOP_BASE_CYCLES + _MAX(MIN_STEPPER_PULSE_CYCLES, MIN_ISR_LOOP_CYCLES))
186 #if ENABLED(LIN_ADVANCE)
189 #if ENABLED(MIXING_EXTRUDER) // ToDo: ???
195 #define MIN_ISR_LA_LOOP_CYCLES ((MIXING_STEPPERS) * (ISR_STEPPER_CYCLES))
197 #define MIN_ISR_LA_LOOP_CYCLES ISR_STEPPER_CYCLES
201 #define ISR_LA_LOOP_CYCLES _MAX(MIN_STEPPER_PULSE_CYCLES, MIN_ISR_LA_LOOP_CYCLES)
204 #define ISR_LA_LOOP_CYCLES 0UL
208 #define ISR_EXECUTION_CYCLES(R) (((ISR_BASE_CYCLES + ISR_S_CURVE_CYCLES + (ISR_LOOP_CYCLES) * (R) + ISR_LA_BASE_CYCLES + ISR_LA_LOOP_CYCLES)) / (R))
211 #define MAX_STEP_ISR_FREQUENCY_128X ((F_CPU) / ISR_EXECUTION_CYCLES(128))
212 #define MAX_STEP_ISR_FREQUENCY_64X ((F_CPU) / ISR_EXECUTION_CYCLES(64))
213 #define MAX_STEP_ISR_FREQUENCY_32X ((F_CPU) / ISR_EXECUTION_CYCLES(32))
214 #define MAX_STEP_ISR_FREQUENCY_16X ((F_CPU) / ISR_EXECUTION_CYCLES(16))
215 #define MAX_STEP_ISR_FREQUENCY_8X ((F_CPU) / ISR_EXECUTION_CYCLES(8))
216 #define MAX_STEP_ISR_FREQUENCY_4X ((F_CPU) / ISR_EXECUTION_CYCLES(4))
217 #define MAX_STEP_ISR_FREQUENCY_2X ((F_CPU) / ISR_EXECUTION_CYCLES(2))
218 #define MAX_STEP_ISR_FREQUENCY_1X ((F_CPU) / ISR_EXECUTION_CYCLES(1))
221 #define MIN_STEP_ISR_FREQUENCY MAX_STEP_ISR_FREQUENCY_1X
230 #if HAS_EXTRA_ENDSTOPS || ENABLED(Z_STEPPER_AUTO_ALIGN)
234 #if HAS_MOTOR_CURRENT_PWM
235 #ifndef PWM_MOTOR_CURRENT
236 #define PWM_MOTOR_CURRENT DEFAULT_PWM_MOTOR_CURRENT
238 static uint32_t motor_current_setting[3];
239 static bool initialized;
246 static uint8_t last_direction_bits,
249 static bool abort_current_block;
253 static constexpr
uint8_t last_moved_extruder = 0;
254 #elif DISABLED(MIXING_EXTRUDER)
255 static uint8_t last_moved_extruder;
258 #if ENABLED(X_DUAL_ENDSTOPS)
259 static bool locked_X_motor, locked_X2_motor;
261 #if ENABLED(Y_DUAL_ENDSTOPS)
262 static bool locked_Y_motor, locked_Y2_motor;
264 #if Z_MULTI_ENDSTOPS || ENABLED(Z_STEPPER_AUTO_ALIGN)
265 static bool locked_Z_motor, locked_Z2_motor;
267 #if ENABLED(Z_TRIPLE_ENDSTOPS) || BOTH(Z_STEPPER_AUTO_ALIGN, Z_TRIPLE_STEPPER_DRIVERS)
268 static bool locked_Z3_motor;
271 static uint32_t acceleration_time, deceleration_time;
274 #if ENABLED(ADAPTIVE_STEP_SMOOTHING)
275 static uint8_t oversampling_factor;
277 static constexpr
uint8_t oversampling_factor = 0;
283 static uint32_t advance_divisor,
284 step_events_completed,
289 #if EXTRUDERS > 1 || ENABLED(MIXING_EXTRUDER)
290 static uint8_t stepper_extruder;
292 static constexpr
uint8_t stepper_extruder = 0;
295 #if ENABLED(S_CURVE_ACCELERATION)
296 static int32_t bezier_A,
299 static uint32_t bezier_F,
302 static bool A_negative;
304 static bool bezier_2nd_half;
307 static uint32_t nextMainISR;
308 #if ENABLED(LIN_ADVANCE)
309 static uint32_t nextAdvanceISR, LA_isr_rate;
310 static uint16_t LA_current_adv_steps, LA_final_adv_steps, LA_max_adv_steps;
311 static int8_t LA_steps;
312 static bool LA_use_advance_lead;
313 #endif // LIN_ADVANCE
315 static int32_t ticks_nominal;
316 #if DISABLED(S_CURVE_ACCELERATION)
317 static uint32_t acc_step_rate;
356 #if ENABLED(LIN_ADVANCE)
358 static uint32_t advance_isr();
387 + last_moved_extruder
398 #if HAS_DIGIPOTSS || HAS_MOTOR_CURRENT_PWM
404 static void microstep_ms(
const uint8_t driver,
const int8_t ms1,
const int8_t ms2,
const int8_t ms3);
409 #if HAS_EXTRA_ENDSTOPS || ENABLED(Z_STEPPER_AUTO_ALIGN)
412 #if ENABLED(X_DUAL_ENDSTOPS)
416 #if ENABLED(Y_DUAL_ENDSTOPS)
420 #if Z_MULTI_ENDSTOPS || (ENABLED(Z_STEPPER_AUTO_ALIGN) && Z_MULTI_STEPPER_DRIVERS)
424 #if ENABLED(Z_TRIPLE_ENDSTOPS) || BOTH(Z_STEPPER_AUTO_ALIGN, Z_TRIPLE_STEPPER_DRIVERS)
428 #if ENABLED(BABYSTEPPING)
432 #if HAS_MOTOR_CURRENT_PWM
433 static void refresh_motor_power();
437 static inline void set_position(
const int32_t &
a,
const int32_t &
b,
const int32_t &c,
const int32_t &e) {
441 _set_position(
a,
b, c, e);
456 count_position[
a] = v;
470 static void _set_position(
const int32_t &
a,
const int32_t &
b,
const int32_t &c,
const int32_t &e);
480 #if DISABLED(DISABLE_MULTI_STEPPING)
483 static const uint32_t limit[]
PROGMEM = {
496 while (idx < 7 && step_rate > (uint32_t)
pgm_read_dword(&limit[idx])) {
510 constexpr uint32_t min_step_rate =
F_CPU / 500000U;
511 NOLESS(step_rate, min_step_rate);
512 step_rate -= min_step_rate;
513 if (step_rate >= (8 * 256)) {
514 const uint8_t tmp_step_rate = (step_rate & 0x00FF);
515 const uint16_t table_address = (uint16_t)&speed_lookuptable_fast[(
uint8_t)(step_rate >> 8)][0],
521 uint16_t table_address = (uint16_t)&speed_lookuptable_slow[0][0];
522 table_address += ((step_rate) >> 1) & 0xFFFC;
533 #if ENABLED(S_CURVE_ACCELERATION)
534 static void _calc_bezier_curve_coeffs(
const int32_t v0,
const int32_t v1,
const uint32_t av);
535 static int32_t _eval_bezier_curve(
const uint32_t curr_step);
538 #if HAS_DIGIPOTSS || HAS_MOTOR_CURRENT_PWM
539 static void digipot_init();
543 static void microstep_init();
#define pgm_read_word(addr)
Definition: pgmspace.h:101
#define X2_DIR_INIT
Definition: indirection.h:109
#define WITHIN(N, L, H)
Definition: macros.h:195
T z
Definition: types.h:286
#define E3_DIR_INIT
Definition: indirection.h:241
#define Y_ENABLE_ON
Definition: Configuration_A3ides_2209_MINI.h:927
#define SERIAL_CHAR(x)
Definition: serial.h:69
static bool separate_multi_axis
Definition: stepper.h:231
#define MAX_STEP_ISR_FREQUENCY_4X
Definition: stepper.h:216
uint8_t direction
Definition: UsbCore.h:185
#define STEP_MULTIPLY(A, B)
Definition: stepper.cpp:1259
#define NOLESS(v, n)
Definition: macros.h:127
static FORCE_INLINE void discard_current_block()
Definition: planner.h:820
#define X_MS3_PIN
Definition: pins.h:559
#define E5_DIR_INIT
Definition: indirection.h:275
static void report_positions()
Definition: stepper.cpp:2276
T z
Definition: types.h:383
static void synchronize()
Definition: planner.cpp:1556
#define INVERT_Y_STEP_PIN
Definition: Configuration_A3ides_2209_MINI_adv.h:501
#define MIN_STEP_ISR_FREQUENCY
Definition: stepper.h:221
#define Z_ENABLE_INIT
Definition: indirection.h:86
volatile uint8_t flag
Definition: planner.h:97
#define MSG_COUNT_X
Definition: language.h:172
T x
Definition: types.h:286
#define X2_MS1_PIN
Definition: pins.h:989
static void isr()
Definition: stepper.cpp:1262
#define PULSE_TIMER_NUM
Definition: HAL.h:129
#define E3_MS2_PIN
Definition: pins.h:610
static job_recovery_info_t info
Definition: power_loss_recovery.h:111
#define X2_ENABLE_WRITE(STATE)
Definition: indirection.h:105
#define Z_ENABLE_WRITE(STATE)
Definition: indirection.h:87
#define E5_ENABLE_INIT
Definition: indirection.h:270
#define E5_MS1_PIN
Definition: pins.h:625
#define ADDED_STEP_TICKS
Definition: stepper.h:180
static volatile bool spi_abort
Definition: L6470_Marlin.h:44
static FORCE_INLINE bool axis_is_moving(const AxisEnum axis)
Definition: stepper.h:381
#define PROGMEM
Definition: pgmspace.h:29
#define E1_ENABLE_WRITE(STATE)
Definition: indirection.h:203
#define X2_STEP_INIT
Definition: indirection.h:113
Definition: L6470_Marlin.h:30
#define LOW
Definition: wiring_constants.h:70
#define INVERT_E_STEP_PIN
Definition: Configuration_A3ides_2209_MINI_adv.h:503
#define X_MS2_PIN
Definition: pins.h:556
#define PULSE_START(AXIS)
#define Y_DIR_INIT
Definition: indirection.h:74
#define MOTOR_CURRENT_PWM_E0_PIN
Definition: pins_ARCHIM1.h:136
#define MSG_COUNT_A
Definition: language.h:173
#define INVERT_X_DIR
Definition: Configuration_A3ides_2209_MINI.h:948
#define E4_DIR_INIT
Definition: indirection.h:258
Stepper stepper
Definition: stepper.cpp:82
#define E_ENABLE_ON
Definition: Configuration_A3ides_2209_MINI.h:929
#define MAX_STEP_ISR_FREQUENCY_2X
Definition: stepper.h:217
#define SERIAL_ECHOPAIR(V...)
Definition: serial.h:114
#define E0_MS1_PIN
Definition: pins.h:580
#define MOTOR_CURRENT_PWM_Y_PIN
Definition: pins_ARCHIM1.h:134
#define MAX_STEP_ISR_FREQUENCY_128X
Definition: stepper.h:211
Definition: L6470_Marlin.h:30
static FORCE_INLINE void set_z2_lock(const bool state)
Definition: stepper.h:422
static bool is_block_busy(const block_t *const block)
Definition: stepper.cpp:1967
bool boolean __attribute__((deprecated))
Definition: wiring_constants.h:110
HAL_STEP_TIMER_ISR()
Definition: stepper.cpp:1248
static FORCE_INLINE bool motor_direction(const AxisEnum axis)
Definition: stepper.h:378
T e
Definition: types.h:383
#define Z_MS2_PIN
Definition: pins.h:574
#define Z2_STEP_INIT
Definition: indirection.h:153
#define Z2_STEP_WRITE(STATE)
Definition: indirection.h:155
#define Z3_ENABLE_WRITE(STATE)
Definition: indirection.h:166
static void init()
Definition: stepper.cpp:1992
#define SET_PWM(IO)
Definition: fastio.h:103
uint8_t i
Definition: screen_test_graph.c:72
#define _MIN(V...)
Definition: macros.h:333
Definition: L6470_Marlin.h:30
Definition: stepper.h:226
#define X_ENABLE_INIT
Definition: indirection.h:52
static volatile fsensor_t state
Definition: filament_sensor.c:23
AxisEnum
Definition: types.h:36
static void wake_up()
Definition: stepper.cpp:342
static void endstop_triggered(const AxisEnum axis)
Definition: stepper.cpp:2237
#define Z2_ENABLE_INIT
Definition: indirection.h:144
#define enable_Z()
Definition: Marlin.h:142
#define SET_OUTPUT(IO)
Definition: fastio.h:101
#define X_MS1_PIN
Definition: pins.h:553
#define X_ENABLE_ON
Definition: Configuration_A3ides_2209_MINI.h:926
#define A(CODE)
Definition: macros.h:75
#define Z3_DIR_INIT
Definition: indirection.h:170
PrintJobRecovery recovery
static void setValue(const uint8_t channel, const uint8_t value)
#define SERIAL_ECHOLN(x)
Definition: serial.h:72
abce_ulong_t steps
Definition: planner.h:107
#define X_ENABLE_WRITE(STATE)
Definition: indirection.h:53
#define STEPPER_ISR_ENABLED()
Definition: HAL.h:143
#define Y_ENABLE_INIT
Definition: indirection.h:69
#define INVERT_Z_STEP_PIN
Definition: Configuration_A3ides_2209_MINI_adv.h:502
#define STEP_TIMER_NUM
Definition: HAL.h:127
FORCE_INLINE void HAL_timer_start(const uint8_t timer_num, const uint32_t)
Definition: HAL.h:149
#define DIGIPOT_MOTOR_CURRENT
Definition: pins_RAMBO.h:113
Stepper()
Definition: stepper.h:340
static uint8_t dir_commands[MAX_L6470]
Definition: L6470_Marlin.h:41
static void set_axis_position(const AxisEnum a, const int32_t &v)
Definition: stepper.h:446
#define E2_DIR_INIT
Definition: indirection.h:224
#define E0_ENABLE_INIT
Definition: indirection.h:185
SpindleLaser cutter
Definition: spindle_laser.cpp:33
#define E1_ENABLE_INIT
Definition: indirection.h:202
Definition: L6470_Marlin.h:30
Definition: L6470_Marlin.h:30
#define MOTOR_CURRENT_PWM_X_PIN
Definition: pins_ARCHIM1.h:133
#define NOMORE(v, n)
Definition: macros.h:133
#define X2_ENABLE_INIT
Definition: indirection.h:104
#define Y_MS1_PIN
Definition: pins.h:562
#define Z2_DIR_INIT
Definition: indirection.h:149
byte transfer(uint8_t _data, SPITransferMode _mode=SPI_LAST)
Definition: SPI.cpp:49
#define HAL_timer_isr_prologue(TIMER_NUM)
Definition: HAL.h:196
#define MOTOR_CURRENT_PWM_XY_PIN
Definition: pins_HJC2560C_REV2.h:73
static FORCE_INLINE uint8_t movement_extruder()
Definition: stepper.h:384
#define X_DIR_READ()
Definition: indirection.h:59
cutter_power_t cutter_power
Definition: planner.h:153
#define NORM_E_DIR(E)
Definition: indirection.h:396
#define DISABLE_ISRS()
Definition: HAL.h:53
#define E2_MS3_PIN
Definition: pins.h:604
#define E3_MS1_PIN
Definition: pins.h:607
static void block_completed(const block_t *const b)
Definition: runout.h:94
#define Z3_STEP_WRITE(STATE)
Definition: indirection.h:176
#define E5_MS2_PIN
Definition: pins.h:628
#define E1_MS1_PIN
Definition: pins.h:589
#define FORCE_INLINE
Definition: macros.h:40
T a
Definition: types.h:384
abce_long_t position
Definition: planner.h:108
volatile uint32_t sdpos
Definition: power_loss_recovery.h:97
T c
Definition: types.h:384
#define Z_MS1_PIN
Definition: pins.h:571
#define E5_ENABLE_WRITE(STATE)
Definition: indirection.h:271
#define Z3_ENABLE_INIT
Definition: indirection.h:165
static void digipot_current(const uint8_t driver, const int16_t current)
Definition: stepper.cpp:2495
#define MOTOR_CURRENT_PWM_E1_PIN
Definition: pins_ARCHIM1.h:137
#define Y_MS3_PIN
Definition: pins.h:568
#define COUNT(a)
Definition: macros.h:200
T b
Definition: types.h:384
#define E4_MS2_PIN
Definition: pins.h:619
#define E4_ENABLE_WRITE(STATE)
Definition: indirection.h:254
#define MOTOR_CURRENT_PWM_Z_PIN
Definition: pins_HJC2560C_REV2.h:74
#define E2_MS2_PIN
Definition: pins.h:601
#define INVERT_X_STEP_PIN
Definition: Configuration_A3ides_2209_MINI_adv.h:500
uint32_t acceleration_rate
Definition: planner.h:133
#define X_DIR_WRITE(STATE)
Definition: indirection.h:58
#define ENABLE_STEPPER_DRIVER_INTERRUPT()
Definition: HAL.h:141
static void set_directions()
Definition: stepper.cpp:354
#define LOOP_L_N(VAR, N)
Definition: types.h:58
#define X2_MS3_PIN
Definition: pins.h:995
#define MAX_STEP_ISR_FREQUENCY_64X
Definition: stepper.h:212
#define DISABLED(V...)
Definition: macros.h:178
uint32_t final_rate
Definition: planner.h:147
#define E2_MS1_PIN
Definition: pins.h:598
#define Z3_STEP_INIT
Definition: indirection.h:174
#define HAL_TIMER_TYPE_MAX
Definition: HAL.h:63
#define HAL_timer_get_count(timer)
Definition: HAL.h:188
#define XY
Definition: macros.h:28
static int32_t triggered_position(const AxisEnum axis)
Definition: stepper.cpp:2258
#define Y2_ENABLE_WRITE(STATE)
Definition: indirection.h:124
#define WRITE(IO, V)
Definition: fastio.h:96
static void microstep_ms(const uint8_t driver, const int8_t ms1, const int8_t ms2, const int8_t ms3)
Definition: stepper.cpp:2701
#define F_CPU
Definition: stm32_def.h:23
#define SERIAL_ECHOPGM(S)
Definition: serial.h:173
#define E2_ENABLE_INIT
Definition: indirection.h:219
#define E0_DIR_INIT
Definition: indirection.h:190
#define MINIMUM_STEPPER_PRE_DIR_DELAY
Definition: Conditionals_post.h:571
static void digitalPotWrite(const int16_t address, const int16_t value)
#define SERIAL_ECHOLNPAIR(V...)
Definition: serial.h:144
#define enable_X()
Definition: Marlin.h:76
#define E0_MS2_PIN
Definition: pins.h:583
list a
Definition: createSpeedLookupTable.py:29
static FORCE_INLINE void quick_stop()
Definition: stepper.h:375
#define enable_Y()
Definition: Marlin.h:103
#define X_DIR_INIT
Definition: indirection.h:57
static void apply_power(const cutter_power_t inpow)
Definition: spindle_laser.cpp:64
#define L(CODE)
Definition: macros.h:76
#define Y2_STEP_INIT
Definition: indirection.h:132
static FORCE_INLINE void set_separate_multi_axis(const bool state)
Definition: stepper.h:410
#define Z_MS3_PIN
Definition: pins.h:577
FI void set(const T px)
Definition: types.h:391
#define MIXER_STEPPER_LOOP(VAR)
Definition: mixing.h:68
#define MINIMUM_STEPPER_POST_DIR_DELAY
Definition: Conditionals_post.h:566
void begin(uint8_t _pin=CS_PIN_CONTROLLED_BY_USER)
Definition: SPI.cpp:43
#define Z_DIR_READ()
Definition: indirection.h:93
static FORCE_INLINE uint16_t MultiU16X8toH16(uint8_t charIn1, uint16_t intIn2)
Definition: math.h:92
#define Y2_DIR_INIT
Definition: indirection.h:128
const uint8_t[]
Definition: 404_html.c:3
UsbDeviceAddress address
Definition: address.h:202
static void stepper_pulse_phase_isr()
Definition: stepper.cpp:1397
uint8_t direction_bits
Definition: planner.h:136
#define DISABLE_STEPPER_DRIVER_INTERRUPT()
Definition: HAL.h:142
#define _BV(bit)
Definition: wiring_constants.h:99
#define INVERT_Y_DIR
Definition: Configuration_A3ides_2209_MINI.h:949
#define SET_CS5(V)
Definition: fastio.h:228
#define X2_MS2_PIN
Definition: pins.h:992
static bool spi_active
Definition: L6470_Marlin.h:45
T y
Definition: types.h:286
uint32_t initial_rate
Definition: planner.h:147
#define Z_DIR_INIT
Definition: indirection.h:91
#define MAX_STEP_ISR_FREQUENCY_1X
Definition: stepper.h:218
#define E5_MS3_PIN
Definition: pins.h:631
static void set_position(const xyze_long_t &abce)
Definition: stepper.h:444
#define X2_STEP_WRITE(STATE)
Definition: indirection.h:115
#define MOTOR_CURRENT_PWM_E_PIN
Definition: pins_HJC2560C_REV2.h:75
#define SERIAL_ERROR_MSG(S)
Definition: serial.h:184
#define E3_ENABLE_INIT
Definition: indirection.h:236
#define Y_MS2_PIN
Definition: pins.h:565
uint32_t step_event_count
Definition: planner.h:110
#define Z_STEP_WRITE(STATE)
Definition: indirection.h:97
#define E3_ENABLE_WRITE(STATE)
Definition: indirection.h:237
#define HAL_timer_isr_epilogue(TIMER_NUM)
Definition: HAL.h:197
#define REV_E_DIR(E)
Definition: indirection.h:397
#define E4_MS3_PIN
Definition: pins.h:622
#define STEPPER_TIMER_TICKS_PER_US
Definition: HAL.h:135
#define Y2_STEP_WRITE(STATE)
Definition: indirection.h:134
#define E2_ENABLE_WRITE(STATE)
Definition: indirection.h:220
#define EXTRUDERS
Definition: Configuration_A3ides_2209_MINI.h:148
#define E4_ENABLE_INIT
Definition: indirection.h:253
#define pgm_read_dword(addr)
Definition: pgmspace.h:105
static FORCE_INLINE uint8_t get_next_stepper()
Definition: mixing.h:248
#define E_STEP_WRITE(E, V)
Definition: indirection.h:395
static void microstep_mode(const uint8_t driver, const uint8_t stepping)
Definition: stepper.cpp:2863
#define HIGH
Definition: wiring_constants.h:71
#define E3_MS3_PIN
Definition: pins.h:613
uint32_t decelerate_after
Definition: planner.h:123
#define E4_MS1_PIN
Definition: pins.h:616
static FORCE_INLINE uint8_t get_stepper()
Definition: mixing.h:247
#define HAL_timer_set_compare(timer, compare)
Definition: HAL.h:186
SPIClass SPI
Definition: SPI.cpp:78
#define Y_STEP_WRITE(STATE)
Definition: indirection.h:80
#define E0_MS3_PIN
Definition: pins.h:586
static void microstep_readings()
Definition: stepper.cpp:2894
#define INVERT_Z_DIR
Definition: Configuration_A3ides_2209_MINI.h:950
uint32_t nominal_rate
Definition: planner.h:147
#define MIXER_STEPPER_SETUP()
Definition: mixing.h:73
#define TEST(n, b)
Definition: macros.h:81
#define HAS_DRIVER(T)
Definition: drivers.h:74
#define DIGIPOTSS_PIN
Definition: pins_RAMBO.h:110
#define Y_DIR_WRITE(STATE)
Definition: indirection.h:75
#define DELAY_NS(x)
Definition: Delay.h:172
static void update()
Definition: endstops.cpp:496
static int32_t position(const AxisEnum axis)
Definition: stepper.cpp:2214
#define Y2_ENABLE_INIT
Definition: indirection.h:123
#define hal_timer_t
Definition: timers.h:33
#define MAX_STEP_ISR_FREQUENCY_8X
Definition: stepper.h:215
#define Y_ENABLE_WRITE(STATE)
Definition: indirection.h:70
static block_t * get_current_block()
Definition: planner.h:769
#define Z_ENABLE_ON
Definition: Configuration_A3ides_2209_MINI.h:928
#define E0_ENABLE_WRITE(STATE)
Definition: indirection.h:186
#define Z2_ENABLE_WRITE(STATE)
Definition: indirection.h:145
#define Y_DIR_READ()
Definition: indirection.h:76
#define SBI(A, B)
Definition: macros.h:85
Stepper stepper
Definition: stepper.cpp:82
#define ENABLE_ISRS()
Definition: HAL.h:52
#define Z_DIR_WRITE(STATE)
Definition: indirection.h:92
Definition: L6470_Marlin.h:30
list b
Definition: createSpeedLookupTable.py:30
#define E1_MS2_PIN
Definition: pins.h:592
#define DIGIPOT_CHANNELS
Definition: pins_RAMBO.h:111
#define MAX_STEP_ISR_FREQUENCY_32X
Definition: stepper.h:213
#define READ(IO)
Definition: fastio.h:95
uint16_t hal_timer_t
Definition: HAL.h:62
uint32_t accelerate_until
Definition: planner.h:123
Endstops endstops
Definition: endstops.cpp:51
#define AXIS_INIT(AXIS, PIN)
static constexpr uint8_t extruder
Definition: planner.h:115
#define E1_DIR_INIT
Definition: indirection.h:207
static void set_position(const int32_t &a, const int32_t &b, const int32_t &c, const int32_t &e)
Definition: stepper.h:437
static FORCE_INLINE void set_z_lock(const bool state)
Definition: stepper.h:421
#define E1_MS3_PIN
Definition: pins.h:595
#define X_STEP_WRITE(STATE)
Definition: indirection.h:63
static uint32_t stepper_block_phase_isr()
Definition: stepper.cpp:1541
Planner planner
Definition: planner.cpp:111
#define MAX_STEP_ISR_FREQUENCY_16X
Definition: stepper.h:214
#define STEPPER_TIMER_RATE
Definition: HAL.h:133
#define MICROSTEP_MODES
Definition: Configuration_A3ides_2209_MINI_adv.h:656
#define MIN_PULSE_TICKS
Definition: stepper.h:176