
Tidied up axis homing tracking. When checking endstops, wait for move to complete before accepting further moves, otherwise subsequent moves use the wrong coordinates. Temperatures and Z probes are now monitored continuously using a tick interrupt to kick off ADC conversions. ADC is now run in 12-bit mode. Thermistor readings are passed through averaging filters. Thermistors are monitored for overheat conditions and bad readings in the tick ISR and the appropriate heater is turned off (useful because the main loop sometimes gets suspended while trying to do USB communication). Use watchdog timer to monitor the tick interrupt - needs patch to Arduino Due core library. Add facility to test watchdog timer (M111 S1001). Added an error status word to record that errors have occurred (e.g. over-temperature). M111 command changes so that S0 turns debug off, S1 turns debug on, S2 reports free memory - also now reports the type of the last restart and the error status word. Fixed problem whereby M111 debug reports were not sent to the web interface. Implemented M999 command, which resets the Duet. Removed an unused variable. Changed some more "char*" to "const char*". Changed extruder PID parameters and added more explanation for them.
66 lines
1.5 KiB
C++
66 lines
1.5 KiB
C++
/****************************************************************************************************
|
|
|
|
RepRapFirmware - Reprap
|
|
|
|
RepRap is a simple class that acts as a container for an instance of all the others.
|
|
|
|
-----------------------------------------------------------------------------------------------------
|
|
|
|
Version 0.1
|
|
|
|
21 May 2013
|
|
|
|
Adrian Bowyer
|
|
RepRap Professional Ltd
|
|
http://reprappro.com
|
|
|
|
Licence: GPL
|
|
|
|
****************************************************************************************************/
|
|
|
|
#ifndef REPRAP_H
|
|
#define REPRAP_H
|
|
|
|
class RepRap
|
|
{
|
|
public:
|
|
|
|
RepRap();
|
|
void EmergencyStop();
|
|
void Init();
|
|
void Spin();
|
|
void Exit();
|
|
void Interrupt();
|
|
void Diagnostics();
|
|
bool Debug() const;
|
|
void SetDebug(int d);
|
|
Platform* GetPlatform() const;
|
|
Move* GetMove() const;
|
|
Heat* GetHeat() const;
|
|
GCodes* GetGCodes() const;
|
|
Webserver* GetWebserver() const;
|
|
void Tick();
|
|
|
|
private:
|
|
|
|
Platform* platform;
|
|
bool active;
|
|
Move* move;
|
|
Heat* heat;
|
|
GCodes* gCodes;
|
|
Webserver* webserver;
|
|
bool debug;
|
|
};
|
|
|
|
inline Platform* RepRap::GetPlatform() const { return platform; }
|
|
inline Move* RepRap::GetMove() const { return move; }
|
|
inline Heat* RepRap::GetHeat() const { return heat; }
|
|
inline GCodes* RepRap::GetGCodes() const { return gCodes; }
|
|
inline Webserver* RepRap::GetWebserver() const { return webserver; }
|
|
inline bool RepRap::Debug() const { return debug; }
|
|
inline void RepRap::Interrupt() { move->Interrupt(); }
|
|
|
|
|
|
#endif
|
|
|
|
|