diff --git a/MTC_Adapter/MTC_Adapter/AdapterESA.cs b/MTC_Adapter/MTC_Adapter/AdapterESA.cs
index 5782286..e700a48 100644
--- a/MTC_Adapter/MTC_Adapter/AdapterESA.cs
+++ b/MTC_Adapter/MTC_Adapter/AdapterESA.cs
@@ -820,50 +820,7 @@ namespace MTC_Adapter
public override void getGlobalData()
{
base.getGlobalData();
-
- // accodo dati path in DataMonitor......
- StringBuilder sb = new StringBuilder();
- if (connectionOk)
- {
- // leggo TUTTO il blocco di memoria
- inizio = DateTime.Now;
- ncDevice.ReadBuffer();
- if (utils.CRB("recTime")) TimingData.addResult(string.Format("R-PLC_FullMemoryRead", ncDevice.PLC_MemoryRead.Length), DateTime.Now.Subtract(inizio).Ticks);
- }
- else
- {
- lg.Error("Errore connessione mancante in getGlobalData");
- }
-
- // -------------------------------------------
- bool needSave = false;
-
- // per ESA calcolo a mano se ci sia stato impiego assi... salvo le istantanee mov precedenti...
- double precVal = 0;
- DateTime adesso = DateTime.Now;
- TimeSpan accumTime = adesso.Subtract(lastChekAccumTimeAxis);
-
- // salvo valore lastChekAccumTimeAxis
- lastChekAccumTimeAxis = adesso;
-
- needSave = procMovTotAssi(needSave);
- needSave = procAccTimeAssi(needSave);
- needSave = procProgrName(needSave);
- needSave = procPartId(needSave);
- needSave = procPzProd(needSave);
- needSave = procNumInvAssi(needSave);
- needSave = procVacPump(needSave);
- needSave = procVacAct(needSave);
- needSave = procLubro(needSave);
-
-
-
- // salvo se necessario!
- if (needSave) parentForm.persistData();
- // -------------------------------------------
- parentForm.dataMonitor = sb.ToString();
-
}
///
/// Path percorso file prod
diff --git a/MTC_Adapter/SCMCncLib/thdNcEsaGvKvara.cs b/MTC_Adapter/SCMCncLib/thdNcEsaGvKvara.cs
index 555e07f..efb3eb0 100644
--- a/MTC_Adapter/SCMCncLib/thdNcEsaGvKvara.cs
+++ b/MTC_Adapter/SCMCncLib/thdNcEsaGvKvara.cs
@@ -30,8 +30,6 @@ namespace SCMCncLib
///
public class thdNcEsaGvKvara : thdNcBase
{
- private UInt16 ReadNumber;
- private UInt16 WriteNumber;
private UInt16 IOT_ByteAreaByteSize;
private UInt16 IOT_WordAreaByteSize;
@@ -43,10 +41,7 @@ namespace SCMCncLib
private string DefCn = "";
private int iChannel;
private int iError;
-
- private string CommandsAddressName;
- private TS_REG CommandsAddress;
-
+
private string IOT_ByteAreaAddressName;
private TS_REG IOT_ByteAreaAddress;
@@ -64,15 +59,7 @@ namespace SCMCncLib
private TS_REG IOT_StringC_AreaAddress;
private string IOT_StringD_AreaAddressName;
private TS_REG IOT_StringD_AreaAddress;
-
- ///
- /// Memorie a 4 byte (32 bit)
- ///
- public UInt32[] PLC_MemoryRead;
- public UInt32[] PLC_MemoryWrite;
- #region memorie IOT NUOVE
-
///
/// Area IOT_Byte: memoria temp di UINT di 4 byte (32 bit)
///
@@ -106,8 +93,6 @@ namespace SCMCncLib
///
public Byte[,] PLC_MemoryAreaIOT_String;
- #endregion
-
// esa constants
#region ESA_PLC_CONSTANTS
private const UInt32 MAX_PATH = 256;
@@ -183,19 +168,13 @@ namespace SCMCncLib
defValue = fIni.ReadString("NC", "SysDefCn", "C:\\KVARA\\DISCOI");
ENVGetProfileString("SYS", "DEFCN", defValue, tempS, MAX_PATH);
DefCn = tempS.ToString() + "\\defcn";
- //StrCat(DefCn, "\\defcn");
-
- ReadNumber = 265;
- WriteNumber = 265;
-
+
// nuove aree: da init mi passa le dimensioni delle memorie
IOT_ByteAreaByteSize = Convert.ToUInt16(IAS_Byte);
IOT_WordAreaByteSize = Convert.ToUInt16(IAS_Word);
IOT_DWordAreaByteSize = Convert.ToUInt16(IAS_DWord);
IOT_String_AreaByteSize = Convert.ToUInt16(IAS_String);
- CommandsAddressName = fIni.ReadString("NC", "CommandsAddress", "SIMREAD[0]");
-
// indirizzo area IOT...
IOT_ByteAreaAddressName = fIni.ReadString("NC", "IOT_AreaAddressByte", "IOT.BYTE");
IOT_WordAreaAddressName = fIni.ReadString("NC", "IOT_AreaAddressWord", "IOT.WORD");
@@ -208,14 +187,6 @@ namespace SCMCncLib
/**************************************************
* Creazione buffers letture memoria
**************************************************/
-
- // create read buffer 32bit
- PLC_MemoryRead = new UInt32[ReadNumber];
- // create write buffer 32bit
- PLC_MemoryWrite = new UInt32[WriteNumber];
-
- // creazione buffers a 32bit
-
// creo array x aree memoria IOT...
PLC_MemoryAreaIOT_Byte_tmp = new UInt32[(int)Math.Ceiling((decimal)IOT_ByteAreaByteSize / 4)];
PLC_MemoryAreaIOT_Byte = new Byte[IOT_ByteAreaByteSize];
@@ -369,10 +340,7 @@ namespace SCMCncLib
// inizializzazione comunicazione
iError = init_board(DefCn, iChannel);
- // inizializzo i registri di lettura e scrittura
- if (iError == 0)
- iError = get_reg_by_name(CommandsAddressName, ref CommandsAddress);
-
+ // effetto le vere letture!
if (iError == 0)
iError = get_reg_by_name(IOT_ByteAreaAddressName, ref IOT_ByteAreaAddress);
if (iError == 0)