Agregada funcion de analizar la matriz de exportacion de tags. Creada un submenu para cargar los ultimos directorios ustilizados. Cambiado intercambio de datos para los Motores simulados a DINT
This commit is contained in:
parent
5208ae54b3
commit
72256a214c
|
@ -394,6 +394,37 @@ namespace LibS7Adv
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public int? LeerTagDInt(string pTag)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
stopwatch.Restart();
|
||||||
|
int? result = Instance?.ReadInt32(pTag);
|
||||||
|
stopwatch.Stop();
|
||||||
|
Debug.WriteLine($" LeerTagDInt took {stopwatch.Elapsed.TotalMilliseconds} ms");
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
PlcData.LastError = pTag + ":" + ex.Message;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public void EscribirTagDInt(string pTag, int pValue)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
stopwatch.Restart();
|
||||||
|
Instance?.WriteInt32(pTag, pValue);
|
||||||
|
stopwatch.Stop();
|
||||||
|
Debug.WriteLine($" EscribirTagDInt took {stopwatch.Elapsed.TotalMilliseconds} ms");
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
PlcData.LastError = pTag + ":" + ex.Message;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public static TagAddress ParseTagAddress(string tag)
|
public static TagAddress ParseTagAddress(string tag)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue