diff options
author | David Crocker <dcrocker@eschertech.com> | 2021-01-24 18:10:05 +0300 |
---|---|---|
committer | David Crocker <dcrocker@eschertech.com> | 2021-01-24 18:10:05 +0300 |
commit | b75f3b14644b1dcc5aeb8170d1e1b6d4a9f8e52e (patch) | |
tree | bf4afa1f53eb91f2fc175283025fa14a99745e1e /src/Heating/LocalHeater.h | |
parent | fec7a47b928ab9bcd0c11ec4f9b6926f2e732401 (diff) |
More work on remote heater tuning
Diffstat (limited to 'src/Heating/LocalHeater.h')
-rw-r--r-- | src/Heating/LocalHeater.h | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/src/Heating/LocalHeater.h b/src/Heating/LocalHeater.h index 80afa0ad..02fde4f9 100644 --- a/src/Heating/LocalHeater.h +++ b/src/Heating/LocalHeater.h @@ -25,14 +25,6 @@ class LocalHeater : public Heater static const size_t NumPreviousTemperatures = 4; // How many samples we average the temperature derivative over public: - struct HeaterParameters - { - float heatingRate; - float coolingRate; - float deadTime; - unsigned int numCycles; - }; - LocalHeater(unsigned int heaterNum) noexcept; ~LocalHeater() noexcept; @@ -46,12 +38,12 @@ public: float GetTemperature() const noexcept override; // Get the latest temperature float GetAveragePWM() const noexcept override; // Return the running average PWM to the heater. Answer is a fraction in [0, 1]. float GetAccumulator() const noexcept override; // Return the integral accumulator - void GetAutoTuneStatus(const StringRef& reply) const noexcept override; // Get the auto tune status or last result void Suspend(bool sus) noexcept override; // Suspend the heater to conserve power or while doing Z probing - void PrintCoolingFanPwmChanged(float pwmChange) noexcept override; + void FeedForwardAdjustment(float fanPwmChange, float extrusionChange) noexcept override; #if SUPPORT_CAN_EXPANSION void UpdateRemoteStatus(CanAddress src, const CanHeaterReport& report) noexcept override { } + void UpdateHeaterTuning(CanAddress src, const CanMessageHeaterTuningReport& msg) noexcept override { } #endif protected: @@ -67,8 +59,6 @@ private: void SetHeater(float power) const noexcept; // Power is a fraction in [0,1] TemperatureError ReadTemperature() noexcept; // Read and store the temperature of this heater void DoTuningStep() noexcept; // Called on each temperature sample when auto tuning - void CalculateModel(HeaterParameters& params) noexcept; // Calculate G, td and tc from the accumulated readings - void SetAndReportModel(bool usingFans) noexcept; float GetExpectedHeatingRate() const noexcept; // Get the minimum heating rate we expect void RaiseHeaterFault(const char *format, ...) noexcept; |