New write call mockup 4 TCam
This commit is contained in:
@@ -685,17 +685,29 @@ namespace CMS_CORE_Library
|
||||
/// <returns></returns>
|
||||
public abstract CmsError PLC_WWarmerChSetpHmi(Dictionary<int, int> newData);
|
||||
/// <summary>
|
||||
/// Set current Warmers Channels ThermocamSetpoints (°C)
|
||||
/// Set current Warmers Channels Temperature Set as reference (°C)
|
||||
/// </summary>
|
||||
/// <param name="newData"></param>
|
||||
/// <returns></returns>
|
||||
public abstract CmsError PLC_WWarmerChTCamSetp(Dictionary<int, double> newData);
|
||||
public abstract CmsError PLC_WWarmerChTCamTempSet(Dictionary<int, double> newData);
|
||||
/// <summary>
|
||||
/// Set current Warmers Channels Thermocam read (actual) value (°C)
|
||||
/// Set current Warmers Channels Thermocam LAST READ value (°C)
|
||||
/// </summary>
|
||||
/// <param name="newData"></param>
|
||||
/// <returns></returns>
|
||||
public abstract CmsError PLC_WWarmerChTCamActual(Dictionary<int, double> newData);
|
||||
public abstract CmsError PLC_WWarmerChTCamTempAct(Dictionary<int, double> newData);
|
||||
/// <summary>
|
||||
/// Set current Warmers Channels as enabled/disabled for working with thermo camera data
|
||||
/// </summary>
|
||||
/// <param name="newData"></param>
|
||||
/// <returns></returns>
|
||||
public abstract CmsError PLC_WWarmerChTCamEnab(Dictionary<int, bool> newData);
|
||||
/// <summary>
|
||||
/// Set ThermoCamera mode
|
||||
/// </summary>
|
||||
/// <param name="enableTCam"></param>
|
||||
/// <returns></returns>
|
||||
public abstract CmsError PLC_WTCamMode(bool enableTCam);
|
||||
/// <summary>
|
||||
/// Set current Warmers Channels reflector's data
|
||||
/// </summary>
|
||||
|
||||
@@ -2373,7 +2373,7 @@ namespace CMS_CORE_Library.S7Net
|
||||
refreshRiscTermoCamTempAct();
|
||||
// refresh temp canale impostata x thermoCam | Write
|
||||
refreshRiscTermoCamTempSet();
|
||||
}
|
||||
}
|
||||
|
||||
// copio lista act in output
|
||||
currWarmerChannelList = ThermoWarmChannels;
|
||||
@@ -3129,7 +3129,7 @@ namespace CMS_CORE_Library.S7Net
|
||||
else
|
||||
{
|
||||
libraryError = S7_PLC_EMPTY_READ;
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// Refresh Canali Riscaldi: SetPoint HMI
|
||||
@@ -3355,7 +3355,7 @@ namespace CMS_CORE_Library.S7Net
|
||||
/// </summary>
|
||||
/// <param name="updtCh"></param>
|
||||
/// <returns></returns>
|
||||
public override CmsError PLC_WWarmerChTCamSetp(Dictionary<int, double> newData)
|
||||
public override CmsError PLC_WWarmerChTCamTempSet(Dictionary<int, double> newData)
|
||||
{
|
||||
// FIXME TODO serve nuova area termocamera
|
||||
#if false
|
||||
@@ -3390,7 +3390,7 @@ namespace CMS_CORE_Library.S7Net
|
||||
/// </summary>
|
||||
/// <param name="updtCh"></param>
|
||||
/// <returns></returns>
|
||||
public override CmsError PLC_WWarmerChTCamActual(Dictionary<int, double> newData)
|
||||
public override CmsError PLC_WWarmerChTCamTempAct(Dictionary<int, double> newData)
|
||||
{
|
||||
// FIXME TODO serve nuova area termocamera
|
||||
#if false
|
||||
@@ -3420,6 +3420,59 @@ namespace CMS_CORE_Library.S7Net
|
||||
|
||||
return NO_ERROR;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Set current Warmers Channels as enabled/disabled for working with thermo camera data
|
||||
/// </summary>
|
||||
/// <param name="newData"></param>
|
||||
/// <returns></returns>
|
||||
public override CmsError PLC_WWarmerChTCamEnab(Dictionary<int, bool> newData)
|
||||
{
|
||||
// FIXME TODO serve nuova area termocamera
|
||||
#if false
|
||||
// memory area
|
||||
byte[] newMem = new byte[newData.Count];
|
||||
List<byte> currMem = new List<byte>();
|
||||
|
||||
// read actual data on memory...
|
||||
CmsError libraryError = MEM_RWByteList(R, 0, RISC_CHP_DATA.MemType, RISC_CHP_DATA.Address, RISC_CHP_DATA.SubAddress, 0, RISC_CHP_DATA.Size, ref currMem);
|
||||
if (libraryError.IsError())
|
||||
return libraryError;
|
||||
|
||||
newMem = currMem.ToArray();
|
||||
|
||||
// update only given data...
|
||||
foreach (var item in newData)
|
||||
{
|
||||
newMem[item.Key - 1] = (byte)item.Value;
|
||||
}
|
||||
// return as list...
|
||||
currMem = newMem.ToList();
|
||||
// scrivo sul PLC array di byte...
|
||||
libraryError = MEM_RWByteList(W, 0, RISC_CHP_DATA.MemType, RISC_CHP_DATA.Address, RISC_CHP_DATA.SubAddress, 0, RISC_CHP_DATA.Size, ref currMem);
|
||||
if (libraryError.IsError())
|
||||
return libraryError;
|
||||
#endif
|
||||
|
||||
return NO_ERROR;
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Set ThermoCamera mode
|
||||
/// </summary>
|
||||
/// <param name="enableTCam"></param>
|
||||
/// <returns></returns>
|
||||
public override CmsError PLC_WTCamMode(bool enableTCam)
|
||||
{
|
||||
#if false
|
||||
|
||||
#endif
|
||||
|
||||
return NO_ERROR;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Set current Warmers Channels reflector's data
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user