Skip to content

Commit

Permalink
Read thermistors at least once at startup
Browse files Browse the repository at this point in the history
  • Loading branch information
Wetmelon committed Nov 3, 2020
1 parent 202d3d2 commit 9594c47
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
3 changes: 0 additions & 3 deletions Firmware/MotorControl/axis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,6 @@ bool Axis::do_checks() {
// Sub-components should use set_error which will propegate to this error_
motor_.effective_current_lim();
motor_.do_checks();
// encoder_.do_checks();
// sensorless_estimator_.do_checks();
// controller_.do_checks();

// Check for endstop presses
if (min_endstop_.config_.enabled && min_endstop_.rose() && !(current_state_ == AXIS_STATE_HOMING)) {
Expand Down
3 changes: 3 additions & 0 deletions Firmware/MotorControl/motor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ bool Motor::setup() {
return false;
}

fet_thermistor_.update();
motor_thermistor_.update();

// Solve for exact gain, then snap down to have equal or larger range as requested
// or largest possible range otherwise
constexpr float kMargin = 0.90f;
Expand Down

0 comments on commit 9594c47

Please sign in to comment.