completato fix area PATH semplificando file conf + caricamento e testing
This commit is contained in:
@@ -368,29 +368,29 @@ namespace MTC_Adapter
|
||||
|
||||
mPathAlias = new MTConnect.Message(string.Format("{0}_Alias", ident));
|
||||
mPathAlias.Value = alias;
|
||||
mPathFeed = new Sample(dataRefList[0].Key);
|
||||
mPathFeedOver = new Sample(dataRefList[1].Key);
|
||||
mPathRapidOver = new Sample(dataRefList[2].Key);
|
||||
mPathPosActX = new Sample(dataRefList[3].Key);
|
||||
mPathPosActY = new Sample(dataRefList[4].Key);
|
||||
mPathPosActZ = new Sample(dataRefList[5].Key);
|
||||
mPathPosActI = new Sample(dataRefList[6].Key);
|
||||
mPathPosActJ = new Sample(dataRefList[7].Key);
|
||||
mPathPosActK = new Sample(dataRefList[8].Key);
|
||||
mPathFeed = new Sample(string.Format("{0}_FeedRate", ident));
|
||||
mPathFeedOver = new Sample(string.Format("{0}_FeedOverr", ident));
|
||||
mPathRapidOver = new Sample(string.Format("{0}_RapidOverr", ident));
|
||||
mPathPosActX = new Sample(string.Format("{0}_PosActX", ident));
|
||||
mPathPosActY = new Sample(string.Format("{0}_PosActY", ident));
|
||||
mPathPosActZ = new Sample(string.Format("{0}_PosActZ", ident));
|
||||
mPathPosActI = new Sample(string.Format("{0}_PosActI", ident));
|
||||
mPathPosActJ = new Sample(string.Format("{0}_PosActJ", ident));
|
||||
mPathPosActK = new Sample(string.Format("{0}_PosActK", ident));
|
||||
// aggiunta x revisione 2016.05.05
|
||||
mPathType = new MTConnect.Message(dataRefList[9].Key);
|
||||
mPathPartId = new Event(dataRefList[10].Key);
|
||||
mPathPartCount = new Event(dataRefList[11].Key);
|
||||
mPathCodM = new MTConnect.Message(dataRefList[12].Key);
|
||||
mPathCodS = new MTConnect.Message(dataRefList[13].Key);
|
||||
mPathCodT = new MTConnect.Message(dataRefList[14].Key);
|
||||
mPathRunMode = new Event(dataRefList[15].Key);
|
||||
mPathExeMode = new Event(dataRefList[16].Key);
|
||||
mPathCurrProg = new Event(dataRefList[17].Key);
|
||||
mPathCurrProgRowNum = new Event(dataRefList[18].Key);
|
||||
mPathActiveAxes = new Event(dataRefList[19].Key);
|
||||
mPathCodG_Act = new MTConnect.Message(dataRefList[20].Key);
|
||||
mPathSubMode = new MTConnect.Message(dataRefList[21].Key);
|
||||
mPathType = new MTConnect.Message(string.Format("{0}_Type", ident));
|
||||
mPathPartId = new Event(string.Format("{0}_PartId", ident));
|
||||
mPathPartCount = new Event(string.Format("{0}_PZ_TOT", ident));
|
||||
mPathCodM = new MTConnect.Message(string.Format("{0}_Cod_M", ident));
|
||||
mPathCodS = new MTConnect.Message(string.Format("{0}_Cod_S", ident));
|
||||
mPathCodT = new MTConnect.Message(string.Format("{0}_Cod_T", ident));
|
||||
mPathRunMode = new Event(string.Format("{0}_RUN_MODE", ident));
|
||||
mPathExeMode = new Event(string.Format("{0}_EXE_MODE", ident));
|
||||
mPathCurrProg = new Event(string.Format("{0}_CurrProg", ident));
|
||||
mPathCurrProgRowNum = new Event(string.Format("{0}_CurrProg_RowNum", ident));
|
||||
mPathActiveAxes = new Event(string.Format("{0}_ActiveAxes", ident));
|
||||
mPathCodG_Act = new MTConnect.Message(string.Format("{0}_CodG_Act", ident));
|
||||
mPathSubMode = new MTConnect.Message(string.Format("{0}_SubMode", ident));
|
||||
mPathAlarmCNC = new Condition(string.Format("{0}_AlarmCNC", ident));
|
||||
mPathAlarmPLC = new Condition(string.Format("{0}_AlarmPLC", ident));
|
||||
}
|
||||
|
||||
@@ -183,97 +183,8 @@
|
||||
<element>
|
||||
<ident>Path_01</ident>
|
||||
<alias>Path num 1</alias>
|
||||
<fonte>Random</fonte>
|
||||
<dataRefList>
|
||||
<dataRef>
|
||||
<Key>Path_01_FeedRate</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_FeedOverr</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_RapidOverr</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActX</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActY</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActZ</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActI</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActJ</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActK</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Type</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PartId</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PZ_TOT</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Cod_M</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Cod_S</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Cod_T</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_RUN_MODE</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_EXE_MODE</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_CurrProg</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_CurrProg_RowNum</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_ActiveAxes</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_CodG_Act</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_SubMode</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
</dataRefList>
|
||||
<fonte>MemLoad</fonte>
|
||||
<dataRefList />
|
||||
</element>
|
||||
</Path>
|
||||
<UnOp>
|
||||
|
||||
@@ -183,97 +183,8 @@
|
||||
<element>
|
||||
<ident>Path_01</ident>
|
||||
<alias>Path num 1</alias>
|
||||
<fonte>Random</fonte>
|
||||
<dataRefList>
|
||||
<dataRef>
|
||||
<Key>Path_01_FeedRate</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_FeedOverr</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_RapidOverr</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActX</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActY</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActZ</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActI</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActJ</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PosActK</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Type</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PartId</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_PZ_TOT</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Cod_M</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Cod_S</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_Cod_T</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_RUN_MODE</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_EXE_MODE</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_CurrProg</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_CurrProg_RowNum</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_ActiveAxes</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_CodG_Act</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
<dataRef>
|
||||
<Key>Path_01_SubMode</Key>
|
||||
<Value>0</Value>
|
||||
</dataRef>
|
||||
</dataRefList>
|
||||
<fonte>MemLoad</fonte>
|
||||
<dataRefList />
|
||||
</element>
|
||||
</Path>
|
||||
<UnOp>
|
||||
|
||||
@@ -386,32 +386,7 @@ namespace MTC_Adapter
|
||||
{
|
||||
// inizializzo list x parametri
|
||||
listaDR = new List<DataRefItem<string, string>>();
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_FeedRate", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_FeedOverr", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_RapidOverr", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PosActX", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PosActY", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PosActZ", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PosActI", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PosActJ", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PosActK", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_Type", i + 1), "0"));
|
||||
// aggiunta x revisione 2016.05.05
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PartId", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_PZ_TOT", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_Cod_M", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_Cod_S", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_Cod_T", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_RUN_MODE", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_EXE_MODE", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_CurrProg", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_CurrProg_RowNum", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_ActiveAxes", i + 1), "0"));
|
||||
// aggiunto 2016.05.10
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_CodG_Act", i + 1), "0"));
|
||||
listaDR.Add(new DataRefItem<string, string>(string.Format("Path_{0:00}_SubMode", i + 1), "0"));
|
||||
|
||||
Path[i] = new element(string.Format("Path_{0:00}", i + 1), string.Format("Path num {0}", i + 1), fonteDati.Random, listaDR);
|
||||
Path[i] = new element(string.Format("Path_{0:00}", i + 1), string.Format("Path num {0}", i + 1), fonteDati.MemLoad, listaDR);
|
||||
}
|
||||
// salvo oggetto
|
||||
c.Path = Path;
|
||||
|
||||
Reference in New Issue
Block a user