|
|
@ -80,7 +80,7 @@ void GcodeSuite::G34() { |
|
|
|
const uint16_t target_current = parser.intval('S', GANTRY_CALIBRATION_CURRENT); |
|
|
|
const uint32_t previous_current = stepper.motor_current_setting[Z_AXIS]; |
|
|
|
stepper.set_digipot_current(1, target_current); |
|
|
|
#elif HAS_MOTOR_CURRENT_DAC |
|
|
|
#elif ENABLED(HAS_MOTOR_CURRENT_DAC) |
|
|
|
const float target_current = parser.floatval('S', GANTRY_CALIBRATION_CURRENT); |
|
|
|
const float previous_current = dac_amps(Z_AXIS, target_current); |
|
|
|
stepper_dac.set_current_value(Z_AXIS, target_current); |
|
|
@ -126,7 +126,7 @@ void GcodeSuite::G34() { |
|
|
|
stepper.set_digipot_current(Z_AXIS, previous_current); |
|
|
|
#elif HAS_MOTOR_CURRENT_PWM |
|
|
|
stepper.set_digipot_current(1, previous_current); |
|
|
|
#elif HAS_MOTOR_CURRENT_DAC |
|
|
|
#elif ENABLED(HAS_MOTOR_CURRENT_DAC) |
|
|
|
stepper_dac.set_current_value(Z_AXIS, previous_current); |
|
|
|
#elif ENABLED(HAS_MOTOR_CURRENT_I2C) |
|
|
|
digipot_i2c.set_current(Z_AXIS, previous_current) |
|
|
|