fix x asse message/event + aggiunta descrizione e init relativa

This commit is contained in:
Samuele E. Locatelli
2018-01-17 11:01:06 +01:00
parent f448b3ca07
commit bbfe0b3af9
+12 -6
View File
@@ -471,18 +471,22 @@ namespace MTC_Adapter
/// </summary>
public class Axis : element
{
/// <summary>
/// Descrizione asse (nome assegnato)
/// </summary>
public Event mAxDescr;
/// <summary>
/// Processo di appartenenza
/// </summary>
public Message mAxMainProc;
public Event mAxMainProc;
/// <summary>
/// Bit se sia master (=1) o slave (=0)
/// </summary>
public Message mAxIsMaster;
public Event mAxIsMaster;
/// <summary>
/// ID del master
/// </summary>
public Message mAxMastId;
public Event mAxMastId;
/// <summary>
/// Gruppo di appartenenza dell'asse
/// </summary>
@@ -575,9 +579,10 @@ namespace MTC_Adapter
}
// valori standard
mAxMainProc = new Message(string.Format("{0}_MainProc", ident));
mAxIsMaster = new Message(string.Format("{0}_IsMast", ident));
mAxMastId = new Message(string.Format("{0}_MastId", ident));
mAxDescr = new Event(string.Format("{0}_Descr", ident));
mAxMainProc = new Event(string.Format("{0}_MainProc", ident));
mAxIsMaster = new Event(string.Format("{0}_IsMast", ident));
mAxMastId = new Event(string.Format("{0}_MastId", ident));
mAxDir = new Event(string.Format("{0}_Dir", ident));
mAxLoad = new Sample(string.Format("{0}_Load", ident));
mAxPosAct = new Sample(string.Format("{0}_PosAct", ident));
@@ -1310,6 +1315,7 @@ namespace MTC_Adapter
for (int i = 0; i < adpConf.nAxis; i++)
{
vettAxis[i] = new Axis(adpConf.Axis[i]);
mAdapter.AddDataItem(vettAxis[i].mAxDescr);
mAdapter.AddDataItem(vettAxis[i].mAxMainProc);
mAdapter.AddDataItem(vettAxis[i].mAxIsMaster);
mAdapter.AddDataItem(vettAxis[i].mAxMastId);