/// <summary> /// Determines the size of the table. /// </summary> /// <param name="table0">The Table 0 object for the current device.</param> /// <param name="table2409">The Table 61 object for the current device.</param> /// <returns>The size of the table in bytes.</returns> // Revision History // MM/DD/YY who Version Issue# Description // -------- --- ------- ------ --------------------------------------- // 12/06/11 RCG 2.53.14 N/A Created private static uint DetermineTableSize(CTable00 table0, OpenWayMFGTable2409 table2409) { uint uiTableSize = 0; LPSetActualLimits SetLimits; if (table0.IsTableUsed((ushort)MFGLPDataSet.Set1)) { SetLimits = table2409.Set1ActualLimits; uiTableSize += LPSetDataSelection.Size(SetLimits.NumberOfChannels, SetLimits.IncludeScalarDivisor, true); } if (table0.IsTableUsed((ushort)MFGLPDataSet.Set2)) { SetLimits = table2409.Set2ActualLimits; uiTableSize += LPSetDataSelection.Size(SetLimits.NumberOfChannels, SetLimits.IncludeScalarDivisor, true); } if (table0.IsTableUsed((ushort)MFGLPDataSet.Set3)) { SetLimits = table2409.Set3ActualLimits; uiTableSize += LPSetDataSelection.Size(SetLimits.NumberOfChannels, SetLimits.IncludeScalarDivisor, true); } if (table0.IsTableUsed((ushort)MFGLPDataSet.Set4)) { SetLimits = table2409.Set4ActualLimits; uiTableSize += LPSetDataSelection.Size(SetLimits.NumberOfChannels, SetLimits.IncludeScalarDivisor, true); } return(uiTableSize); }
/// <summary> /// Returns the size of table 2408 based on the values in table 0 /// </summary> /// <param name="Table0">The Table 0 object.</param> /// <returns>The size of table 2408.</returns> // Revision History // MM/DD/YY who Version Issue# Description // -------- --- ------- ------ --------------------------------------- // 12/06/11 RCG 2.53.14 N/A Created private static uint DetermineTableSize(CTable00 Table0) { uint uiTableSize = 0; if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set1) == true) { uiTableSize += LP_SET_STATUS_RECORD_SIZE; } if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set2) == true) { uiTableSize += LP_SET_STATUS_RECORD_SIZE; } if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set3) == true) { uiTableSize += LP_SET_STATUS_RECORD_SIZE; } if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set4) == true) { uiTableSize += LP_SET_STATUS_RECORD_SIZE; } return(uiTableSize); }
/// <summary> /// Returns the size of table 2408 based on the values in table 0 /// </summary> /// <param name="Table0">The Table 0 object.</param> /// <returns>The size of table 2408.</returns> // Revision History // MM/DD/YY who Version Issue# Description // -------- --- ------- ------ --------------------------------------- // 12/06/11 RCG 2.53.14 N/A Created private static uint DetermineTableSize(CTable00 Table0) { uint uiTableSize = TABLE_61_HEADER_SIZE + 1; if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set1) == true) { // Table Set 1 is used uiTableSize += TABLE_61_SET_INFO_SIZE; } if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set2) == true) { // Table Set 2 is used uiTableSize += TABLE_61_SET_INFO_SIZE; } if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set3) == true) { // Table Set 3 is used uiTableSize += TABLE_61_SET_INFO_SIZE; } if (Table0.IsTableUsed((ushort)MFGLPDataSet.Set4) == true) { // Table Set 4 is used uiTableSize += TABLE_61_SET_INFO_SIZE; } return(uiTableSize); }