42 lines
783 B
C++
42 lines
783 B
C++
#pragma once
|
|
|
|
#include "../log/AxisLog.h"
|
|
#include "BaseServoClient.h"
|
|
//#include "../PLC/Axis.h"
|
|
|
|
class ServoManager
|
|
{
|
|
public:
|
|
ServoManager(/*PLCAxis* axis*/);
|
|
virtual ~ServoManager();
|
|
void Startup();
|
|
void Shutdown();
|
|
void StartLog(long jid, size_t layerIndex, int ctype);
|
|
void StopLog();
|
|
void DrawServo();
|
|
bool IsServoRun() { return m_IsRun; }
|
|
void ResetLogServo();
|
|
private:
|
|
static DWORD WINAPI UpdateProc(ServoManager* _this);
|
|
void UpdateRun();
|
|
|
|
public:
|
|
bool m_IsShowServo;
|
|
|
|
private:
|
|
|
|
bool m_UpdateFlag;
|
|
HANDLE m_UpdateThread;
|
|
ServoStat m_MoldStat;
|
|
ServoStat m_LoadStat;
|
|
ServoStat m_ArmStat;
|
|
ServoStat m_SupplyStat;
|
|
CRITICAL_SECTION m_LogLoadCS;
|
|
CRITICAL_SECTION m_ShowLoadCS;
|
|
bool m_IsLogReady;
|
|
//PLCAxis* m_Axis;
|
|
AxisLog* m_AxisLog;
|
|
bool m_IsRun;
|
|
};
|
|
|