You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
94 lines
1.9 KiB
C++
94 lines
1.9 KiB
C++
#pragma once
|
|
|
|
#include "Input.h"
|
|
#include "Output.h"
|
|
#include "Motor.h"
|
|
|
|
#define MAX_MODULE 32
|
|
#define MAX_MODULE_INPUT 11 // 16
|
|
#define MAX_MODULE_OUTPUT 15
|
|
#define MAX_MODULE_MOTOR 16
|
|
|
|
struct stModule
|
|
{
|
|
stModule()
|
|
{
|
|
for (auto& mtr : Motor) {
|
|
mtr = nullptr;
|
|
}
|
|
}
|
|
|
|
stModule(std::string& _strName) : strName(_strName)
|
|
{
|
|
}
|
|
|
|
bool HasMotors()
|
|
{
|
|
return Motor.size() > 0;
|
|
}
|
|
|
|
std::string strName;
|
|
|
|
std::vector<CInputSetting> Input;
|
|
|
|
std::vector<COutputSetting> Output;
|
|
|
|
std::vector<std::unique_ptr<CMtrProfile>> Motor;
|
|
|
|
};
|
|
|
|
// input and output module data structure for Maintenance page
|
|
struct stMaintIoModule
|
|
{
|
|
std::string m_strModuleName; // store module name
|
|
std::vector<std::string> m_strIoName; // MAX_MODULE_INPUT]; // store input name
|
|
};
|
|
|
|
// Gary 21Dec10, V1.23.02 for multilanguage motor name and motor position name
|
|
// for Maintenance page
|
|
struct stMaintMotorModule
|
|
{
|
|
std::string m_strModuleName; // store module name
|
|
std::string m_strMtrName[MAX_MOTOR]; // store motor name
|
|
std::vector<std::string> m_vecMtrPos[MAX_MOTOR]; // store Motor Position Name
|
|
};
|
|
|
|
// user change accordingly to suit the machine requirement
|
|
struct stLotInfo
|
|
{
|
|
std::string strLotStarted;
|
|
std::string strLotName;
|
|
long lLotQty;
|
|
std::string strShiftID;
|
|
std::string strOperatorID;
|
|
std::string strLotStartTime;
|
|
std::string strRecipeName;
|
|
std::string strPackageName;
|
|
};
|
|
|
|
struct stRecipeInfo
|
|
{
|
|
std::string strRecipeName;
|
|
std::string strPackageName;
|
|
};
|
|
|
|
struct stPackageInfo
|
|
{
|
|
std::string strPackageName;
|
|
int nPackageID;
|
|
};
|
|
|
|
// Light Config
|
|
typedef struct _LIGHT_CONFIG {
|
|
int iRed{ 1 };
|
|
int iAmber{ 1 };
|
|
int iGreen{ 1 };
|
|
int iBuzzer{ 0 };
|
|
int iLightOnTime{ 500 };
|
|
int iLightOffTime{ 500 };
|
|
int iBuzzerOnTime{ 500 };
|
|
int iBuzzerOffTime{ 500 };
|
|
|
|
} LIGHT_CONFIG;
|
|
|