Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Duet3D/RepRapFirmware.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Crocker <dcrocker@eschertech.com>2019-09-04 15:19:31 +0300
committerDavid Crocker <dcrocker@eschertech.com>2019-09-04 15:19:31 +0300
commit8c2493dfa96ad79b746dea22c3ca134533d892a8 (patch)
tree0b9c2fdfb56970e70a30e940cecf338590029b99 /src/Fans/Fan.h
parent103b92930887cc65787f75a435e0301dbfa1b847 (diff)
Remote fans now workig
Also implemented request message ID allocation and response checking
Diffstat (limited to 'src/Fans/Fan.h')
-rw-r--r--src/Fans/Fan.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/Fans/Fan.h b/src/Fans/Fan.h
index d5a8ec6f..ca592c0d 100644
--- a/src/Fans/Fan.h
+++ b/src/Fans/Fan.h
@@ -10,6 +10,7 @@
#include "RepRapFirmware.h"
#include "Hardware/IoPorts.h"
+#include "GCodes/GCodeResult.h"
class GCodeBuffer;
@@ -19,10 +20,10 @@ public:
Fan(unsigned int fanNum);
virtual bool Check() = 0; // update the fan PWM returning true if it is a thermostatic fan that is on
- virtual void SetPwmFrequency(PwmFrequency freq) = 0;
+ virtual GCodeResult SetPwmFrequency(PwmFrequency freq, const StringRef& reply) = 0;
virtual bool IsEnabled() const = 0;
virtual int32_t GetRPM() = 0;
- virtual void AppendPortDetails(const StringRef& str) const = 0;
+ virtual GCodeResult ReportPortDetails(const StringRef& str) const = 0;
virtual ~Fan() { }
// Set or report the parameters for this fan
@@ -35,7 +36,7 @@ public:
float GetConfiguredPwm() const { return val; } // returns the configured PWM. Actual PWM may be different, e.g. due to blipping or for thermostatic fans.
- void SetPwm(float speed);
+ GCodeResult SetPwm(float speed, const StringRef& reply);
bool HasMonitoredSensors() const { return sensorsMonitored != 0; }
const char *GetName() const { return name.c_str(); }
@@ -44,7 +45,7 @@ public:
#endif
protected:
- virtual void Refresh() = 0;
+ virtual GCodeResult Refresh(const StringRef& reply) = 0;
virtual bool UpdateFanConfiguration(const StringRef& reply) = 0;
unsigned int fanNumber;