sistemata mappa byte con nuovi valori x IOT_VAC_01..04 + fix modalità calcolo area memoria (non da bitNum ma da numero valore variabile)
This commit is contained in:
@@ -498,12 +498,21 @@ namespace MTC_Adapter
|
||||
}
|
||||
else if (mapIOT_Byte[i].varName.StartsWith("IOT_EXEC_A_"))
|
||||
{
|
||||
// salvo SOLO SE ha bit = 1..
|
||||
if (((StFlag8)currByte).HasFlag((StFlag8)Math.Pow(2, bitNum)))
|
||||
// recupero NUMERO
|
||||
try
|
||||
{
|
||||
// salvo area selezionata!
|
||||
progAreaSel = bitNum + 1;
|
||||
currProgName = vettMemArea[bitNum].mMemAreaProgName.Value.ToString();
|
||||
numero = Convert.ToInt32(mapIOT_Byte[i].varName.Replace("IOT_VAC_", ""));
|
||||
// salvo SOLO SE ha bit = 1..
|
||||
if (((StFlag8)currByte).HasFlag((StFlag8)Math.Pow(2, bitNum)))
|
||||
{
|
||||
// salvo area selezionata!
|
||||
progAreaSel = numero;
|
||||
currProgName = vettMemArea[numero - 1].mMemAreaProgName.Value.ToString();
|
||||
}
|
||||
}
|
||||
catch (Exception exc)
|
||||
{
|
||||
lg.Error(exc, "Errore in decodifica " + mapIOT_Byte[i].varName);
|
||||
}
|
||||
}
|
||||
else if (mapIOT_Byte[i].varName.StartsWith("IOT_VAC_"))
|
||||
|
||||
@@ -11,10 +11,10 @@
|
||||
1.1|IOT_EXEC_A_02 |BOOL
|
||||
1.2|IOT_EXEC_A_03 |BOOL
|
||||
1.3|IOT_EXEC_A_04 |BOOL
|
||||
1.4|libero |BOOL
|
||||
1.5|libero |BOOL
|
||||
1.6|libero |BOOL
|
||||
1.7|libero |BOOL
|
||||
1.4|IOT_VAC_01 |BOOL
|
||||
1.5|IOT_VAC_02 |BOOL
|
||||
1.6|IOT_VAC_03 |BOOL
|
||||
1.7|IOT_VAC_04 |BOOL
|
||||
002|libero |BYTE
|
||||
003|IOT_MODECN |BYTE
|
||||
004|IOT_OVRF |BYTE
|
||||
|
||||
Reference in New Issue
Block a user