init
This commit is contained in:
132
Common/DTS.CommonCore/Enums/ApplicationStatusTypes.cs
Normal file
132
Common/DTS.CommonCore/Enums/ApplicationStatusTypes.cs
Normal file
@@ -0,0 +1,132 @@
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public enum ApplicationStatusTypes
|
||||
{
|
||||
IDLE,
|
||||
SettingConfiguration,
|
||||
ClearingFlash,
|
||||
Arm,
|
||||
AutoArmPrepare,
|
||||
WaitingForStart,
|
||||
WaitingForTrigger,
|
||||
WaitingForStartWithEvent,
|
||||
WaitingForTriggerCheck,
|
||||
WaitingForAutoArm,
|
||||
WaitingForStreaming,
|
||||
Passed,
|
||||
FailedStart,
|
||||
FailedTrigger,
|
||||
Done,
|
||||
FailedArm,
|
||||
FailedDisarm,
|
||||
InvalidSampleRate,
|
||||
InvalidEventLength,
|
||||
InvalidArmMode,
|
||||
UnimplementedArmMode,
|
||||
EventNumberTooLarge,
|
||||
MemoryFull,
|
||||
InvalidSliceCount,
|
||||
ShortedStartRecordInput,
|
||||
ShortedTriggerInput,
|
||||
InvalidPretriggerSamplesRequested,
|
||||
ShortedStartAndTrigger,
|
||||
EventUncompleted,
|
||||
SafeSwitchUnplugged,
|
||||
SquibResistanceFault,
|
||||
BatteryLowVoltage,
|
||||
Failed,
|
||||
ROIFailed,
|
||||
PreparingForArming,
|
||||
WaitingForArmSwitch,
|
||||
Arming,
|
||||
Armed,
|
||||
Disarmed,
|
||||
WaitingForFlashWrite,
|
||||
IdleWaitingForTrigger,
|
||||
IdleWaitingForStart,
|
||||
IdleWaitingForStartWithEvent,
|
||||
PostTestProcessing,
|
||||
ReadyForDownload,
|
||||
ReadyForDownloadFaulted,
|
||||
ReadyForDownloadNoneTriggered,
|
||||
ReadyForDownloadSomeTriggered,
|
||||
Faulted,
|
||||
Detached,
|
||||
FillingBuffer,
|
||||
Recording,
|
||||
NoChannelsInTest,
|
||||
Connecting,
|
||||
NotIncluded,
|
||||
SomeConnected,
|
||||
Validating,
|
||||
CheckingDAS,
|
||||
NoDataToDownload,
|
||||
NoUARTDataToDownload,
|
||||
Cancelled,
|
||||
CancelledPartial,
|
||||
UnexpectedFirmwareVersion,
|
||||
ExpiredCalDate,
|
||||
ChannelCountMismatch,
|
||||
CheckingForExistingData,
|
||||
CheckArmSwitch,
|
||||
CheckingArmSwitch,
|
||||
ExcitationWarmup,
|
||||
//UpdatingConfig,
|
||||
PreparingForDiagnostics,
|
||||
PerformingDiagnostics,
|
||||
NotImplemented,
|
||||
Finished,
|
||||
WaitingForOptions,
|
||||
Exporting,
|
||||
QueryEventData,
|
||||
Downloading,
|
||||
UARTDownloading,
|
||||
CleaningUp,
|
||||
Preparing,
|
||||
WaitingForDAS,
|
||||
UnexpectedMaxMemory,
|
||||
QueryConfiguration,
|
||||
FailBatteryLow,
|
||||
FailBatteryHigh,
|
||||
FailInputLow,
|
||||
FailInputHigh,
|
||||
FailInputInvalid,
|
||||
FailBatteryInvalid,
|
||||
GettingEventInfo,
|
||||
CheckingForData,
|
||||
NoDataCollected,
|
||||
NoDataCollectedSomeTriggered,
|
||||
NoDataCollectedNoneTriggered,
|
||||
Connected,
|
||||
Disconnected,
|
||||
LowPowerMode,
|
||||
DiagnosticsDone, //indicates that diagnostics is complete (maybe not all units have run though, so overall pass/fail is not available yet)
|
||||
FailedArmCheckListSetConfig,
|
||||
ReadingVoltages,
|
||||
FailedSetConfiguration,
|
||||
CreatingCalculatedChannels,
|
||||
NoDASConfigs,
|
||||
UserCanceled,
|
||||
ArmPrepareComplete,
|
||||
AutoDiscovery,
|
||||
LevelTriggered,
|
||||
CapturingAttributes,
|
||||
CheckingArmState,
|
||||
ActivelyStreaming,
|
||||
//14060 DataPRO should fail download ROI if channels are not included in at least one ROI.
|
||||
//this is a status when download ROI has finished all downloads however one or more data channels were not
|
||||
//included in any roi. This explictly excludes output only channels
|
||||
NotAllChannelsDownloaded,
|
||||
// FB15335: Move UART and ClockProfile sets to RunTest -> Hardware NavStep, add Reboot
|
||||
CheckingClockSources,
|
||||
SettingClockSources,
|
||||
CheckingUARTSettings,
|
||||
SettingUARTSettings,
|
||||
Rebooting,
|
||||
Rearming,
|
||||
WaitingForScheduleStartTime,
|
||||
WaitingForInterval,
|
||||
WaitingForMotion,
|
||||
AwakeWaitingForTrigger
|
||||
}
|
||||
}
|
||||
395
Common/DTS.CommonCore/Enums/AssemblyInfo.cs
Normal file
395
Common/DTS.CommonCore/Enums/AssemblyInfo.cs
Normal file
@@ -0,0 +1,395 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.ObjectModel;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Drawing;
|
||||
using System.Reflection;
|
||||
using System.Windows.Media.Imaging;
|
||||
// ReSharper disable InconsistentNaming
|
||||
|
||||
namespace DTS.Common
|
||||
{
|
||||
public static class AssemblyInfo
|
||||
{
|
||||
public static Dictionary<string, BitmapImage> AssemblyImage = new Dictionary<string, BitmapImage>();
|
||||
|
||||
public static BitmapImage GetImage(string asmName)
|
||||
{
|
||||
return LoadImages().Where(x => x.AssemblyName == asmName).Select(z => z.AssemblyImage).FirstOrDefault();
|
||||
}
|
||||
|
||||
private static List<AssemblyNameImage> LoadImages()
|
||||
{
|
||||
var tilesLocation = Properties.Settings.Default.TilesLocation;
|
||||
return new List<AssemblyNameImage>
|
||||
{
|
||||
new AssemblyNameImage(eAssemblyGroups.Hardware.ToString(), AssemblyNames.DataRecorders.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.DataRecorders + ".png", UriKind.Relative)),
|
||||
0),
|
||||
new AssemblyNameImage(eAssemblyGroups.Hardware.ToString(), AssemblyNames.SensorTemplates.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.SensorTemplates + ".png", UriKind.Relative)),
|
||||
0),
|
||||
new AssemblyNameImage(eAssemblyGroups.Hardware.ToString(), AssemblyNames.SensorDatabase.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.SensorDatabase + ".png", UriKind.Relative)),
|
||||
0),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.GroupTemplate.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.GroupTemplate + ".png", UriKind.Relative)),
|
||||
1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.Groups.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Groups + ".png", UriKind.Relative)), 1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.CustomerDetails.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.CustomerDetails + ".png", UriKind.Relative)),
|
||||
1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.EngineerDetails.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.EngineerDetails + ".png", UriKind.Relative)),
|
||||
1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.LabDetails.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.LabDetails + ".png", UriKind.Relative)), 1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.TestSetups.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.TestSetups + ".png", UriKind.Relative)), 1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Prepare.ToString(), AssemblyNames.CustomChannels.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.CustomChannels + ".png", UriKind.Relative)),
|
||||
1),
|
||||
new AssemblyNameImage(eAssemblyGroups.Diagnostics.ToString(), AssemblyNames.CheckChannels.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.CheckChannels + ".png", UriKind.Relative)),
|
||||
2),
|
||||
new AssemblyNameImage(eAssemblyGroups.Diagnostics.ToString(), AssemblyNames.CheckTrigger.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.CheckTrigger + ".png", UriKind.Relative)), 2),
|
||||
new AssemblyNameImage(eAssemblyGroups.Record.ToString(), AssemblyNames.RunTest.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.RunTest + ".png", UriKind.Relative)), 3),
|
||||
new AssemblyNameImage(eAssemblyGroups.Record.ToString(), AssemblyNames.DownloadData.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.DownloadData + ".png", UriKind.Relative)), 3),
|
||||
new AssemblyNameImage(eAssemblyGroups.Review.ToString(), AssemblyNames.ViewData.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.ViewData + ".png", UriKind.Relative)), 4),
|
||||
new AssemblyNameImage(eAssemblyGroups.Review.ToString(), AssemblyNames.ExportData.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.ExportData + ".png", UriKind.Relative)), 4),
|
||||
new AssemblyNameImage(eAssemblyGroups.Administrative.ToString(), AssemblyNames.ManageUsers.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.ManageUsers + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Administrative.ToString(),
|
||||
AssemblyNames.SystemSettings.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.SystemSettings + ".png", UriKind.Relative)),
|
||||
5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Administrative.ToString(), AssemblyNames.Networking.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Networking + ".png", UriKind.Relative)), 5),
|
||||
|
||||
//Not avaiable yet...
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Navigation.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Navigation + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Eu.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Eu + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Mv.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Mv + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Edc.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Edc + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Tests.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Tests + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Graphs.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Graphs + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Legend.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Legend + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Diag.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Diag + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Stats.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Stats + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Cursor.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Cursor + ".png", UriKind.Relative)), 5),
|
||||
new AssemblyNameImage(eAssemblyGroups.Viewer.ToString(), AssemblyNames.Property.ToString(),
|
||||
new BitmapImage(new Uri(tilesLocation + AssemblyNames.Property + ".png", UriKind.Relative)), 5),
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
public static Type ImageAttribute;
|
||||
}
|
||||
|
||||
public class AssemblyNameImage : INotifyPropertyChanged
|
||||
{
|
||||
public AssemblyNameImage()
|
||||
{
|
||||
}
|
||||
|
||||
public AssemblyNameImage(string group, string name, BitmapImage image, int sort)
|
||||
{
|
||||
_assemblyGroup = group;
|
||||
_assemblyName = name;
|
||||
_assemblyImage = image;
|
||||
_sortOrder = sort;
|
||||
OnPropertyChanged("AssemblyGroup");
|
||||
OnPropertyChanged("AssemblyName");
|
||||
OnPropertyChanged("AssemblyImage");
|
||||
}
|
||||
|
||||
private string _assemblyGroup = string.Empty;
|
||||
|
||||
public string AssemblyGroup
|
||||
{
|
||||
get => _assemblyGroup;
|
||||
set
|
||||
{
|
||||
_assemblyGroup = value;
|
||||
OnPropertyChanged("AssemblyGroup");
|
||||
}
|
||||
}
|
||||
|
||||
private string _assemblyName = string.Empty;
|
||||
|
||||
public string AssemblyName
|
||||
{
|
||||
get => _assemblyName;
|
||||
set
|
||||
{
|
||||
_assemblyName = value;
|
||||
OnPropertyChanged("AssemblyName");
|
||||
}
|
||||
}
|
||||
|
||||
private eAssemblyRegion _assemblyRegion = eAssemblyRegion.NotAssigned;
|
||||
|
||||
public eAssemblyRegion AssemblyRegion
|
||||
{
|
||||
get => _assemblyRegion;
|
||||
set
|
||||
{
|
||||
_assemblyRegion = value;
|
||||
OnPropertyChanged("AssemblyRegion");
|
||||
}
|
||||
}
|
||||
|
||||
BitmapImage _assemblyImage = new BitmapImage();
|
||||
|
||||
public BitmapImage AssemblyImage
|
||||
{
|
||||
get => _assemblyImage;
|
||||
set
|
||||
{
|
||||
_assemblyImage = value;
|
||||
OnPropertyChanged("AssemblyImage");
|
||||
}
|
||||
}
|
||||
|
||||
private int _sortOrder = 0;
|
||||
|
||||
public int SortOrder
|
||||
{
|
||||
get => _sortOrder;
|
||||
set
|
||||
{
|
||||
_sortOrder = value;
|
||||
OnPropertyChanged("SortOrder");
|
||||
}
|
||||
}
|
||||
|
||||
///<summary>
|
||||
///Occurs when a property value changes.
|
||||
///</summary>
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
private void OnPropertyChanged(string propertyName)
|
||||
{
|
||||
var eventHandler = PropertyChanged;
|
||||
if (eventHandler != null)
|
||||
{
|
||||
eventHandler(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public class AssemblyGroups : INotifyPropertyChanged
|
||||
{
|
||||
public AssemblyGroups()
|
||||
{
|
||||
}
|
||||
|
||||
private string _asemblyGroupName = string.Empty;
|
||||
|
||||
public string AssemblyGroupName
|
||||
{
|
||||
get => _asemblyGroupName;
|
||||
set
|
||||
{
|
||||
_asemblyGroupName = value;
|
||||
OnPropertyChanged("AssemblyGroupName");
|
||||
}
|
||||
}
|
||||
|
||||
private List<AssemblyNameImage> _assemblyList = new List<AssemblyNameImage>();
|
||||
|
||||
public List<AssemblyNameImage> AssemblyList
|
||||
{
|
||||
get => _assemblyList;
|
||||
set
|
||||
{
|
||||
_assemblyList = value;
|
||||
OnPropertyChanged("AssemblyList");
|
||||
}
|
||||
}
|
||||
|
||||
private int _sortOrder = 0;
|
||||
|
||||
public int SortOrder
|
||||
{
|
||||
get => _sortOrder;
|
||||
set
|
||||
{
|
||||
_sortOrder = value;
|
||||
OnPropertyChanged("SortOrder");
|
||||
}
|
||||
}
|
||||
|
||||
///<summary>
|
||||
///Occurs when a property value changes.
|
||||
///</summary>
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
private void OnPropertyChanged(string propertyName)
|
||||
{
|
||||
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
|
||||
public enum eAssemblyGroups
|
||||
{
|
||||
Hardware,
|
||||
Prepare,
|
||||
Diagnostics,
|
||||
Record,
|
||||
Review,
|
||||
Administrative,
|
||||
Viewer
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Assembly Names, aka Pluggable components, aka Modules.
|
||||
/// </summary>
|
||||
public enum AssemblyNames
|
||||
{
|
||||
CheckChannels,
|
||||
CheckTrigger,
|
||||
CustomChannels,
|
||||
CustomerDetails,
|
||||
DataRecorders,
|
||||
DownloadData,
|
||||
EngineerDetails,
|
||||
LabDetails,
|
||||
ExportData,
|
||||
Groups,
|
||||
GroupTemplate,
|
||||
ManageUsers,
|
||||
RunTest,
|
||||
SensorDatabase,
|
||||
SensorTemplates,
|
||||
SystemSettings,
|
||||
TestSetups,
|
||||
ViewData,
|
||||
Networking,
|
||||
IsoSettings,
|
||||
PowerAndBattery,
|
||||
RealtimeSettings,
|
||||
TablesSettings,
|
||||
TestSettings,
|
||||
QASettings,
|
||||
UISettings,
|
||||
DB,
|
||||
Navigation,
|
||||
Eu,
|
||||
Mv,
|
||||
Edc,
|
||||
Tests,
|
||||
Graphs,
|
||||
Legend,
|
||||
Diag,
|
||||
Stats,
|
||||
Cursor,
|
||||
Property,
|
||||
Graph,
|
||||
GraphList,
|
||||
CPU,
|
||||
GroupImport,
|
||||
TestSummaryList,
|
||||
Filter,
|
||||
ChartOptions,
|
||||
TestModification,
|
||||
AddCalculatedChannel,
|
||||
TTSImport,
|
||||
StatusAndProgressBar,
|
||||
SensorsList,
|
||||
HardwareList,
|
||||
GroupTemplateList,
|
||||
GroupList,
|
||||
TestSetupsList,
|
||||
CachedItemsList,
|
||||
RealtimeModule,
|
||||
TemplateChannelList,
|
||||
DatabaseServices,
|
||||
GroupChannelList,
|
||||
RegionOfInterestChannels,
|
||||
Diagnostics,
|
||||
ChannelCodes,
|
||||
ChannelCodeBuilder,
|
||||
SoftwareFilters,
|
||||
SensorSettingsModule,
|
||||
SquibsModule,
|
||||
ViewerSettings,
|
||||
HamburgerMenu,
|
||||
AddEditHardware,
|
||||
ExtraProperties,
|
||||
PSDReport,
|
||||
PSDReportResults,
|
||||
PSDReportSettings
|
||||
}
|
||||
|
||||
public enum eAssemblyRegion
|
||||
{
|
||||
NotAssigned,
|
||||
NavigationRegion,
|
||||
EuRegion,
|
||||
MvRegion,
|
||||
EdcRegion,
|
||||
TestsRegion,
|
||||
GraphsRegion,
|
||||
LegendRegion,
|
||||
DiagRegion,
|
||||
StatsRegion,
|
||||
CursorRegion,
|
||||
PropertyRegion,
|
||||
DisplayRegion,
|
||||
GraphRegion,
|
||||
GraphListRegion,
|
||||
TestSummaryRegion,
|
||||
FilterRegion,
|
||||
ChartOptionsRegion,
|
||||
TestModificationRegion,
|
||||
AddCalculatedChannelRegion,
|
||||
TTSImportRegion,
|
||||
StatusAndProgressBarRegion,
|
||||
SensorsListRegion,
|
||||
HardwareListRegion,
|
||||
GroupTemplateListRegion,
|
||||
GroupListRegion,
|
||||
TestSetupsListRegion,
|
||||
CachedItemsListRegion,
|
||||
RealtimeModuleRegion,
|
||||
TemplateChannelListRegion,
|
||||
DatabaseServicesRegion,
|
||||
CustomChannelsRegion,
|
||||
GroupChannelListRegion,
|
||||
RegionOfInterestChannelsRegion,
|
||||
DiagnosticsRegion,
|
||||
ChannelCodesRegion,
|
||||
ChannelCodeBuilderRegion,
|
||||
SoftwareFiltersRegion,
|
||||
SensorSettingsModuleRegion,
|
||||
SquibsModuleRegion,
|
||||
ViewerSettingsRegion,
|
||||
HamburgerMenuRegion,
|
||||
AddEditHardwareRegion,
|
||||
ExtraPropertiesRegion,
|
||||
PSDReportRegion,
|
||||
PSDReportResultsRegion,
|
||||
PSDReportSettingsRegion,
|
||||
}
|
||||
}
|
||||
165
Common/DTS.CommonCore/Enums/CFCFilter.cs
Normal file
165
Common/DTS.CommonCore/Enums/CFCFilter.cs
Normal file
@@ -0,0 +1,165 @@
|
||||
using System.ComponentModel;
|
||||
using System.Windows.Data;
|
||||
using DTS.Common.Base.Classes;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Enums.Sensors;
|
||||
using DTS.Common.Interface.Sensors.SoftwareFilters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
// ReSharper disable InconsistentNaming
|
||||
// ReSharper disable CheckNamespace
|
||||
|
||||
namespace DTS.Common
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum CFCFilter
|
||||
{
|
||||
[Description("None")]
|
||||
None = 0,
|
||||
[Description("Unfiltered")]
|
||||
Unfiltered = -2,
|
||||
[Description("CFC 10")]
|
||||
Class10 = 17,
|
||||
[Description("CFC 60")]
|
||||
Class60 = 100,
|
||||
[Description("CFC 180")]
|
||||
Class180 = 300,
|
||||
[Description("CFC 600")]
|
||||
Class600 = 1000,
|
||||
[Description("CFC 1000")]
|
||||
Class1000 = 1650
|
||||
}
|
||||
public class CFCFilterItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<CFCFilter>();
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// this class could be extended to become an IValueConverter, but for now it just serves as a mechanism for
|
||||
/// going from the serialized in DTS files form of CFC filter to enum and vice versa.
|
||||
/// </summary>
|
||||
public class CFCFilterDTSFileStringConverter
|
||||
{
|
||||
//returns a string representing the isocode field for software filter given a software filter
|
||||
//returns ? if filter is not known
|
||||
public static string GetIsoCodeFromString( string s, bool bUseZeroForUnfiltered = false)
|
||||
{
|
||||
var filter = GetFilterFromString(s);
|
||||
return CFCFilterToCFC(filter);
|
||||
}
|
||||
/// <summary>
|
||||
/// converts from a string (like in ITestChannel) to the CFC enum
|
||||
/// </summary>
|
||||
/// <param name="s"></param>
|
||||
/// <returns></returns>
|
||||
public static CFCFilter GetFilterFromString(string s)
|
||||
{
|
||||
if (string.IsNullOrEmpty(s)) return CFCFilter.Unfiltered;
|
||||
switch (s.ToLower())
|
||||
{
|
||||
case "cfc 10":
|
||||
//added because "CFC " is stripped off in some exports... (FTSS.TSV)
|
||||
case "10":
|
||||
return CFCFilter.Class10;
|
||||
case "cfc 60":
|
||||
case "60":
|
||||
return CFCFilter.Class60;
|
||||
case "cfc 180":
|
||||
case "180":
|
||||
return CFCFilter.Class180;
|
||||
case "cfc 600":
|
||||
case "600":
|
||||
return CFCFilter.Class600;
|
||||
case "cfc 1000":
|
||||
case "1000":
|
||||
return CFCFilter.Class1000;
|
||||
case "unfiltered":
|
||||
return CFCFilter.Unfiltered;
|
||||
case "none":
|
||||
return CFCFilter.None;
|
||||
default:
|
||||
return CFCFilter.Unfiltered;
|
||||
}
|
||||
}
|
||||
|
||||
//FB 13120 convert filter class to cfc filter string
|
||||
/// <summary>
|
||||
/// converts back to a string from IFilterClass [so that the ITestChannel can be updated]
|
||||
/// </summary>
|
||||
/// <param name="filter"></param>
|
||||
/// <returns></returns>
|
||||
public static string FilterClassToString(IFilterClass filter)
|
||||
{
|
||||
if (filter == null)
|
||||
return "Unfiltered";
|
||||
|
||||
switch (filter.FClass)
|
||||
{
|
||||
case FilterClassType.CFC10: return "CFC 10";
|
||||
case FilterClassType.CFC60: return "CFC 60";
|
||||
case FilterClassType.CFC180: return "CFC 180";
|
||||
case FilterClassType.CFC600: return "CFC 600";
|
||||
case FilterClassType.CFC1000: return "CFC 1000";
|
||||
case FilterClassType.AdHoc: return filter.Frequency.ToString();
|
||||
case FilterClassType.Unfiltered: return "Unfiltered";
|
||||
case FilterClassType.None: return "None";
|
||||
default:
|
||||
return "Unfiltered";
|
||||
}
|
||||
}
|
||||
|
||||
//FB 13120 convert filter class to cfc string
|
||||
/// <summary>
|
||||
/// converts back to a string from IFilterClass [so that the ITestChannel can be updated]
|
||||
/// </summary>
|
||||
/// <param name="filter"></param>
|
||||
/// <returns></returns>
|
||||
|
||||
public static string FilterClassToCFC(IFilterClass filter, bool bUseZeroForUnfiltered = false)
|
||||
{
|
||||
switch (filter.FClass)
|
||||
{
|
||||
case FilterClassType.Unfiltered:
|
||||
return bUseZeroForUnfiltered ? "0" : "P";
|
||||
case FilterClassType.None:
|
||||
return "P";
|
||||
case FilterClassType.CFC10:
|
||||
return "Q";
|
||||
case FilterClassType.CFC60:
|
||||
return "D";
|
||||
case FilterClassType.CFC180:
|
||||
return "C";
|
||||
case FilterClassType.CFC600:
|
||||
return "B";
|
||||
case FilterClassType.CFC1000:
|
||||
return "A";
|
||||
case FilterClassType.AdHoc:
|
||||
return "S";
|
||||
}
|
||||
return "S";
|
||||
}
|
||||
public static string CFCFilterToCFC(CFCFilter filter, bool bUseZeroForUnfiltered = false)
|
||||
{
|
||||
switch (filter)
|
||||
{
|
||||
case CFCFilter.Unfiltered:
|
||||
return bUseZeroForUnfiltered ? "0" : "P";
|
||||
case CFCFilter.None:
|
||||
return "P";
|
||||
case CFCFilter.Class10:
|
||||
return "Q";
|
||||
case CFCFilter.Class60:
|
||||
return "D";
|
||||
case CFCFilter.Class180:
|
||||
return "C";
|
||||
case CFCFilter.Class600:
|
||||
return "B";
|
||||
case CFCFilter.Class1000:
|
||||
return "A";
|
||||
}
|
||||
return "S";
|
||||
}
|
||||
}
|
||||
}
|
||||
16
Common/DTS.CommonCore/Enums/Channels/ChannelCodeType.cs
Normal file
16
Common/DTS.CommonCore/Enums/Channels/ChannelCodeType.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
namespace DTS.Common.Enums.Channels
|
||||
{
|
||||
public class ChannelEnumsAndConstants
|
||||
{
|
||||
public const string IsoCodeTypeString = "ISO 13499";
|
||||
public const string UserCodeTypeString = "User";
|
||||
public const int ISO_CODE_LENGTH = 16;
|
||||
public const int USER_CODE_LENGTH = 50;
|
||||
|
||||
public enum ChannelCodeType
|
||||
{
|
||||
ISO,
|
||||
User
|
||||
}
|
||||
}
|
||||
}
|
||||
173
Common/DTS.CommonCore/Enums/ClockSource.cs
Normal file
173
Common/DTS.CommonCore/Enums/ClockSource.cs
Normal file
@@ -0,0 +1,173 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
namespace DTS.Common
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum ClockSyncProfile : byte
|
||||
{
|
||||
[Description("ClockSyncProfile_None")]
|
||||
None = 0,
|
||||
[Description("ClockSyncProfile_Manual")]
|
||||
Manual,
|
||||
[Description("ClockSyncProfile_Slave_E2E")]
|
||||
Slave_E2E,
|
||||
[Description("ClockSyncProfile_Master_E2E")]
|
||||
Master_E2E,
|
||||
[Description("ClockSyncProfile_Auto_E2E")]
|
||||
Auto_E2E,
|
||||
[Description("ClockSyncProfile_Master_E2E_IRIG")]
|
||||
Master_E2E_IRIG,
|
||||
[Description("ClockSyncProfile_Master_E2E_IRIG_EXT_PPS")]
|
||||
Master_E2E_IRIG_EXT_PPS,
|
||||
[Description("ClockSyncProfile_Master_E2E_GPS")]
|
||||
Master_E2E_GPS,
|
||||
[Description("ClockSyncProfile_Master_E2E_GPS_EXT_PPS")]
|
||||
Master_E2E_GPS_EXT_PPS,
|
||||
[Description("ClockSyncProfile_Master_E2E_EXT_PPS")]
|
||||
Master_E2E_EXT_PPS,
|
||||
//[Description("ClockSyncProfile_Slave_P2P")]
|
||||
//Slave_P2P = 12,
|
||||
//[Description("ClockSyncProfile_Master_P2P")]
|
||||
//Master_P2P,
|
||||
//[Description("ClockSyncProfile_Auto_P2P")]
|
||||
//Auto_P2P,
|
||||
//[Description("ClockSyncProfile_Master_P2P_IRIG")]
|
||||
//Master_P2P_IRIG,
|
||||
//[Description("ClockSyncProfile_Master_P2P_IRIG_EXT_PPS")]
|
||||
//Master_P2P_IRIG_EXT_PPS,
|
||||
//[Description("ClockSyncProfile_Master_P2P_GPS")]
|
||||
//Master_P2P_GPS,
|
||||
//[Description("ClockSyncProfile_Master_P2P_GPS_EXT_PPS")]
|
||||
//Master_P2P_GPS_EXT_PPS,
|
||||
//[Description("ClockSyncProfile_Master_P2P_EXT_PPS")]
|
||||
//Master_P2P_EXT_PPS,
|
||||
[Description("ClockSyncProfile_IRIG")]
|
||||
IRIG = 21,
|
||||
[Description("ClockSyncProfile_IRIG_EXT_PPS")]
|
||||
IRIG_EXT_PPS,
|
||||
[Description("ClockSyncProfile_GPS")]
|
||||
GPS,
|
||||
[Description("ClockSyncProfile_GPS_EXT_PPS")]
|
||||
GPS_EXT_PPS,
|
||||
[Description("ClockSyncProfile_EXT_PPS")]
|
||||
EXT_PPS,
|
||||
//1PPS Out Profiles
|
||||
[Description("ClockSyncProfile_Slave_E2E_PPS_OUT")]
|
||||
Slave_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_Master_E2E_PPS_OUT")]
|
||||
Master_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_IRIG_Master_E2E_PPS_OUT")]
|
||||
IRIG_Master_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_IRIG_PPS_OUT")]
|
||||
IRIG_PPS_OUT = 32,
|
||||
//Combinations that are possible in UI, but no device supports
|
||||
[Description("ClockSyncProfile_PPS_OUT")]
|
||||
PPS_OUT = 245,
|
||||
[Description("ClockSyncProfile_GPS_PPS_OUT")]
|
||||
GPS_PPS_OUT,
|
||||
[Description("ClockSyncProfile_GPS_Master_E2E_PPS_OUT")]
|
||||
GPS_Master_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_GPS_EXT_PPS_PPS_OUT")]
|
||||
GPS_EXT_PPS_PPS_OUT,
|
||||
[Description("ClockSyncProfile_GPS_EXT_PPS_Master_E2E_PPS_OUT")]
|
||||
GPS_EXT_PPS_Master_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_EXT_PPS_PPS_OUT")]
|
||||
EXT_PPS_PPS_OUT,
|
||||
[Description("ClockSyncProfile_EXT_PPS_Master_E2E_PPS_OUT")]
|
||||
EXT_PPS_Master_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_IRIG_EXT_PPS_PPS_OUT")]
|
||||
IRIG_EXT_PPS_PPS_OUT,
|
||||
[Description("ClockSyncProfile_IRIG_EXT_PPS_Master_E2E_PPS_OUT")]
|
||||
IRIG_EXT_PPS_Master_E2E_PPS_OUT,
|
||||
[Description("ClockSyncProfile_Slave_E2E_Master_E2E_OUT")]
|
||||
Slave_E2E_Master_E2E_OUT,
|
||||
[Description("ClockSyncProfile_Slave_E2E_Master_E2E_PPS_OUT")]
|
||||
Slave_E2E_Master_E2E_PPS_OUT,
|
||||
}
|
||||
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum InputClockSource : byte
|
||||
{
|
||||
[Description("InputClockSource_None")]
|
||||
None = 0,
|
||||
[Description("InputClockSource_PTP")]
|
||||
PTP = (1 << 0),
|
||||
[Description("InputClockSource_IRIG")]
|
||||
IRIG = (1 << 1),
|
||||
[Description("InputClockSource_GPS")]
|
||||
GPS = (1 << 2),
|
||||
[Description("InputClockSource_1PPS")]
|
||||
OnePPS = (1 << 3),
|
||||
[Description("InputClockSource_PTP_1PPS")]
|
||||
PTP_OnePPS = (1 << 0) | (1 << 3),
|
||||
[Description("InputClockSource_IRIG_1PPS")]
|
||||
IRIG_OnePPS = (1 << 1) | (1 << 3),
|
||||
[Description("InputClockSource_GPS_1PPS")]
|
||||
GPS_OnePPS = (1 << 2) | (1 << 3),
|
||||
}
|
||||
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum OutputClockSource : byte
|
||||
{
|
||||
[Description("OutputClockSource_None")]
|
||||
None = 0,
|
||||
[Description("OutputClockSource_PTP")] // not a real setting. for UI purposes only.
|
||||
PTP = 255,
|
||||
[Description("OutputClockSource_PTP_OnePPS")] // not a real setting. for UI purposes only.
|
||||
PTP_OnePPS = 254,
|
||||
[Description("OutputClockSource_PTPMaster_E2E")]
|
||||
PTPMasterE2E = (1 << 0),
|
||||
[Description("OutputClockSource_PTPMaster_P2P")]
|
||||
PTPMasterP2P = (1 << 0) | (1 << 2),
|
||||
[Description("OutputClockSource_PTPBoundary_E2E")]
|
||||
PTPBoundaryE2E = (1 << 1),
|
||||
[Description("OutputClockSource_PTPBoundary_P2P")]
|
||||
PTPBoundaryP2P = (1 << 1) | (1 << 2),
|
||||
[Description("OutputClockSource_OnePPS")]
|
||||
OnePPS = (1 << 3),
|
||||
[Description("OutputClockSource_PTPMaster_E2E_OnePPS")]
|
||||
PTPMasterE2E_OnePPS = (1 << 0) | (1 << 3),
|
||||
[Description("OutputClockSource_PTPMaster_P2P_OnePPS")]
|
||||
PTPMasterP2P_OnePPS = (1 << 0) | (1 << 2) | (1 << 3),
|
||||
[Description("OutputClockSource_PTPBoundary_E2E_OnePPS")]
|
||||
PTPBoundaryE2E_OnePPS = (1 << 1) | (1 << 3),
|
||||
[Description("OutputClockSource_PTPBoundary_P2P_OnePPS")]
|
||||
PTPBoundaryP2P_OnePPS = (1 << 1) | (1 << 2) | (1 << 3)
|
||||
}
|
||||
|
||||
public class MasterClockSyncProfileItemsSource : ProfileSourceItemsSource
|
||||
{
|
||||
public override ItemCollection GetValues()
|
||||
{
|
||||
return FromProfiles(Constants.MasterProfiles);
|
||||
}
|
||||
}
|
||||
|
||||
public class SlaveClockSyncProfileItemsSource : ProfileSourceItemsSource
|
||||
{
|
||||
public override ItemCollection GetValues()
|
||||
{
|
||||
return FromProfiles(Constants.SlaveProfiles);
|
||||
}
|
||||
}
|
||||
|
||||
public abstract class ProfileSourceItemsSource : IItemsSource
|
||||
{
|
||||
protected ItemCollection FromProfiles(ClockSyncProfile[] profiles)
|
||||
{
|
||||
var values = new ItemCollection();
|
||||
foreach (var profile in profiles)
|
||||
{
|
||||
values.Add(profile, Strings.Strings.ResourceManager.GetString(profile.GetEnumDescription()));
|
||||
}
|
||||
return values;
|
||||
}
|
||||
public virtual ItemCollection GetValues()
|
||||
{
|
||||
return FromProfiles(new ClockSyncProfile[] {});
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
using DTS.Common.Interface.Communication;
|
||||
|
||||
namespace DTS.Common.Enums.Communication
|
||||
{
|
||||
public static class CommunicationConstantsAndEnums
|
||||
{
|
||||
public enum CommunicationResult
|
||||
{
|
||||
ConnectOK,
|
||||
ConnectFailed,
|
||||
ConnectTimeout,
|
||||
DisconnectOK,
|
||||
DisconnectFailed,
|
||||
DisconnectTimeout,
|
||||
SendOK,
|
||||
SendFailed,
|
||||
SendTimeout,
|
||||
ReceiveOK,
|
||||
ReceiveFailed,
|
||||
ReceiveTimeout,
|
||||
Canceled
|
||||
}
|
||||
public delegate bool CommunicationCallback(ICommunicationReport report);
|
||||
}
|
||||
}
|
||||
48
Common/DTS.CommonCore/Enums/DASFactory/ConstantsAndEnums.cs
Normal file
48
Common/DTS.CommonCore/Enums/DASFactory/ConstantsAndEnums.cs
Normal file
@@ -0,0 +1,48 @@
|
||||
namespace DTS.Common.Enums.DASFactory
|
||||
{
|
||||
public static class ConstantsAndEnums
|
||||
{
|
||||
/// <summary>
|
||||
/// This tells us what type of device it is
|
||||
/// </summary>
|
||||
public enum DASType
|
||||
{
|
||||
NONE,
|
||||
HID_SLICE,
|
||||
WINUSB_SLICE,
|
||||
G5,
|
||||
SIM,
|
||||
TOM,
|
||||
DIM,
|
||||
TSR,
|
||||
HEADS,
|
||||
MINIDAU,
|
||||
ETHERNET_SLICE,
|
||||
ETHERNET_RIBEYE,
|
||||
SLICE_DB,
|
||||
TSR2,
|
||||
ETHERNET_TDAS,
|
||||
CDCUSB_SLICE,
|
||||
ETHERNET_SLICE2,
|
||||
WINUSB_SLICE1_5,
|
||||
ETHERNET_SLICE1_5,
|
||||
ETHERNET_SLICE6,
|
||||
ETHERNET_SLICE6AIR,
|
||||
WINUSB_SLICE6,
|
||||
WINUSB_SLICE6AIR,
|
||||
ETHERNET_SLICE6DB,
|
||||
SERIAL_TDAS
|
||||
}
|
||||
public enum VoltageStatusColor
|
||||
{
|
||||
Green,
|
||||
Red,
|
||||
Yellow,
|
||||
Off
|
||||
}
|
||||
|
||||
public const int EVENT_NUMBER_PRETEST_DIAG = -1;
|
||||
public const int EVENT_NUMBER_POSTTEST_DIAG = -2;
|
||||
public const int EVENT_NUMBER_MEASURE_BRIDGE = -3;
|
||||
}
|
||||
}
|
||||
1273
Common/DTS.CommonCore/Enums/DASFactory/DFConstantsAndEnums.cs
Normal file
1273
Common/DTS.CommonCore/Enums/DASFactory/DFConstantsAndEnums.cs
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,34 @@
|
||||
namespace DTS.Common.Enums.DASFactory
|
||||
{
|
||||
public enum S6DBDiagnosticChannelList
|
||||
{
|
||||
//These match previous Base channels
|
||||
InputVoltage = 0,
|
||||
BackupVoltage = 1,
|
||||
TemperatureC = 2,
|
||||
BatterySoc = 3,
|
||||
|
||||
//These are the rest of the DB diag channels
|
||||
DiagInputVoltage = 100,
|
||||
DiagMcuTemperature = 101,
|
||||
DiagChargerPower = 102,
|
||||
DiagChargerInputCurrent = 103,
|
||||
//DiagChargerDischargeCurrent = 104,
|
||||
DiagEnv_1_Temperature = 104, //Internal
|
||||
DiagEnv_1_Humidity = 105, //Internal
|
||||
DiagEnv_2_Temperature = 106,
|
||||
DiagEnv_2_Humidity = 107,
|
||||
DiagEnv_3_Temperature = 108,
|
||||
DiagEnv_3_Humidity = 109,
|
||||
DiagEnv_4_Temperature = 110,
|
||||
DiagEnv_4_Humidity = 111,
|
||||
DiagEnv_5_Temperature = 112,
|
||||
DiagEnv_5_Humidity = 113,
|
||||
DiagBatterySoc = 114,
|
||||
DiagBatteryPackVoltage = 115,
|
||||
DiagBatteryPackCurrent = 116,
|
||||
DiagBatteryFgTemperature = 117,
|
||||
DiagBatteryThermistor1Temperature = 118,
|
||||
DiagBatteryThermistor2Temperature = 119,
|
||||
};
|
||||
}
|
||||
24
Common/DTS.CommonCore/Enums/DASFactory/UseCasesTSRAIR.cs
Normal file
24
Common/DTS.CommonCore/Enums/DASFactory/UseCasesTSRAIR.cs
Normal file
@@ -0,0 +1,24 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums.DASFactory
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum UseCasesTSRAIR : byte
|
||||
{
|
||||
[Description("Aerospace")]
|
||||
AEROSPACE,
|
||||
[Description("Aerospace with motion")]
|
||||
AEROSPACE_with_motion,
|
||||
[Description("Vibration")]
|
||||
VIBRATION,
|
||||
[Description("Scheduled")]
|
||||
SCHEDULED,
|
||||
[Description("Interval")]
|
||||
INTERVAL,
|
||||
[Description("Streaming")]
|
||||
STREAMING,
|
||||
[Description("Pretrigger test")]
|
||||
PRETRIGGER_TEST,
|
||||
}
|
||||
}
|
||||
13
Common/DTS.CommonCore/Enums/DASFactory/WakeupTriggers.cs
Normal file
13
Common/DTS.CommonCore/Enums/DASFactory/WakeupTriggers.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using DTS.Common.Base.Classes;
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.DASFactory
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum WakeupTriggers
|
||||
{
|
||||
[Description("WakeupTriggers_MotionDetect")]
|
||||
MotionDetect,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.MMEDirection
|
||||
/// </summary>
|
||||
public enum CustomDirectionFields
|
||||
{
|
||||
Direction,
|
||||
Expired,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Remarks,
|
||||
GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Version
|
||||
}
|
||||
}
|
||||
21
Common/DTS.CommonCore/Enums/DBExport/CustomFilterFields.cs
Normal file
21
Common/DTS.CommonCore/Enums/DBExport/CustomFilterFields.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.MME_FilterClass
|
||||
/// </summary>
|
||||
public enum CustomFilterFields
|
||||
{
|
||||
Date,
|
||||
Expired,
|
||||
Filter_Class,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Version,
|
||||
}
|
||||
}
|
||||
21
Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc1Fields.cs
Normal file
21
Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc1Fields.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.FineLocation1
|
||||
/// </summary>
|
||||
public enum CustomFinLoc1Fields
|
||||
{
|
||||
Date,
|
||||
Expired,
|
||||
Fine_Loc_1,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Version,
|
||||
}
|
||||
}
|
||||
21
Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc2Fields.cs
Normal file
21
Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc2Fields.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.FineLocation2
|
||||
/// </summary>
|
||||
public enum CustomFinLoc2Fields
|
||||
{
|
||||
Date,
|
||||
Expired,
|
||||
Fine_Loc_2,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Version,
|
||||
}
|
||||
}
|
||||
21
Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc3Fields.cs
Normal file
21
Common/DTS.CommonCore/Enums/DBExport/CustomFinLoc3Fields.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.MMEFineLocation3
|
||||
/// </summary>
|
||||
public enum CustomFinLoc3Fields
|
||||
{
|
||||
Date,
|
||||
Expired,
|
||||
Fine_Loc_3,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Version,
|
||||
}
|
||||
}
|
||||
23
Common/DTS.CommonCore/Enums/DBExport/MainLocationFields.cs
Normal file
23
Common/DTS.CommonCore/Enums/DBExport/MainLocationFields.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.MMETransducerMainLocation
|
||||
/// </summary>
|
||||
public enum MainLocationFields
|
||||
{
|
||||
Date,
|
||||
Expired,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Picture_ShortName,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Trans_Main_Loc,
|
||||
Type,
|
||||
Version
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.MMEPhysicalDimension
|
||||
/// </summary>
|
||||
public enum PhysicalDimensionFields
|
||||
{
|
||||
Amount_Of_Substance_EXP,
|
||||
Date,
|
||||
Default_Unit,
|
||||
Electric_Current_EXP,
|
||||
Expired,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Length_EXP,
|
||||
Luminous_Intensity_Exp,
|
||||
Mass_EXP,
|
||||
Physical_Dimension,
|
||||
RecordType,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Temperature_EXP,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Time_EXP,
|
||||
Version
|
||||
}
|
||||
}
|
||||
22
Common/DTS.CommonCore/Enums/DBExport/PositionFields.cs
Normal file
22
Common/DTS.CommonCore/Enums/DBExport/PositionFields.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// different tags for an ISODll.MMEPositions object
|
||||
/// </summary>
|
||||
public enum PositionFields
|
||||
{
|
||||
Date,
|
||||
Expired,
|
||||
History,
|
||||
Last_Change,
|
||||
Last_Change_Text,
|
||||
Position,
|
||||
RecordType,
|
||||
Remarks,
|
||||
S_GUID,
|
||||
SortKey,
|
||||
Text_L1,
|
||||
Text_L2,
|
||||
Version
|
||||
}
|
||||
}
|
||||
18
Common/DTS.CommonCore/Enums/DBExport/TestObjectFields.cs
Normal file
18
Common/DTS.CommonCore/Enums/DBExport/TestObjectFields.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
public enum TestObjectFields
|
||||
{
|
||||
s_GUID,
|
||||
TEST_OBJECT,
|
||||
TEXT_L1,
|
||||
TEXT_L2,
|
||||
VERSION,
|
||||
DATE,
|
||||
REMARKS,
|
||||
EXPIRED,
|
||||
SORTKEY,
|
||||
LAST_CHANGE,
|
||||
LAST_CHANGE_TEXT,
|
||||
HISTORY
|
||||
}
|
||||
}
|
||||
34
Common/DTS.CommonCore/Enums/DBExport/TopLevelFields.cs
Normal file
34
Common/DTS.CommonCore/Enums/DBExport/TopLevelFields.cs
Normal file
@@ -0,0 +1,34 @@
|
||||
namespace DTS.Common.Enums.DBExport
|
||||
{
|
||||
/// <summary>
|
||||
/// possible root tags in the xml
|
||||
/// </summary>
|
||||
public enum TopLevelFields
|
||||
{
|
||||
CustomerDetails,
|
||||
TestEngineerDetails,
|
||||
LabDetails,
|
||||
DASList,
|
||||
SensorModels,
|
||||
Sensors,
|
||||
Calibrations,
|
||||
CustomDirections,
|
||||
CustomFilterClasses,
|
||||
CustomTestObjects,
|
||||
CustomFinLoc1s,
|
||||
CustomFinLoc2s,
|
||||
CustomFinLoc3s,
|
||||
CustomMainLocs,
|
||||
CustomPhysicalDimensions,
|
||||
CustomPositions,
|
||||
CustomChannels,
|
||||
GroupTemplates,
|
||||
Groups,
|
||||
TestSetups,
|
||||
Users,
|
||||
GlobalSettings,
|
||||
//introduce in V7,
|
||||
//15390 Store the ZMO in EU in the DataPRO DB
|
||||
SensorChangeHistory
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
// ReSharper disable CheckNamespace
|
||||
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum ChartUnitTypeEnum
|
||||
{
|
||||
[Description("EU")]
|
||||
EU = 0,
|
||||
[Description("mV")]
|
||||
mV = 1,
|
||||
[Description("ADC")]
|
||||
ADC = 2,
|
||||
//6402 Implement ability to switch to FFT live in the Review
|
||||
[Description("FFT")]
|
||||
FFT = 3,
|
||||
// 25554 implement Power Spectral Density type
|
||||
[Description("PSD")]
|
||||
PSD = 4
|
||||
}
|
||||
public class ChartUnitTypeItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<ChartUnitTypeEnum>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
// ReSharper disable CheckNamespace
|
||||
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum FilterOptionEnum
|
||||
{
|
||||
[Description("Unfiltered")]
|
||||
Unfiltered = 0,
|
||||
[Description("Test Setup Default")]
|
||||
TestSetupDefault = 1,
|
||||
[Description("Custom")]
|
||||
Custom = 2
|
||||
}
|
||||
public class FilterOptionEnumItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<FilterOptionEnum>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,25 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
// ReSharper disable CheckNamespace
|
||||
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum TimeUnitTypeEnum
|
||||
{
|
||||
[Description("ms")]
|
||||
MS = 0,
|
||||
[Description("Seconds")]
|
||||
Seconds = 1,
|
||||
}
|
||||
public class TimeUnitTypeItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<TimeUnitTypeEnum>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,29 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
// ReSharper disable CheckNamespace
|
||||
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum WakeMethodTypeEnum
|
||||
{
|
||||
[Description("None")]
|
||||
None = 0,
|
||||
[Description("Motion detect")]
|
||||
MotionDetect = 1,
|
||||
[Description("Time session")]
|
||||
TimeSession = 2,
|
||||
[Description("Magnet")]
|
||||
Magnet = 3,
|
||||
}
|
||||
public class WakeMethodTypeItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<WakeMethodTypeEnum>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,30 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
// ReSharper disable CheckNamespace
|
||||
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum YRangeScaleEnum
|
||||
{
|
||||
[Description("Auto Range")]
|
||||
AutoRange = 0,
|
||||
[Description("% Full Scale")]
|
||||
FullScale = 1,
|
||||
[Description("Fixed")]
|
||||
Fixed = 2,
|
||||
[Description("Manual")]
|
||||
Manual = 3
|
||||
}
|
||||
public class YRangeScaleItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<YRangeScaleEnum>();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
// ReSharper disable CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum FilterEnum
|
||||
{
|
||||
Test,
|
||||
Graph
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Viewer.Reports
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum PassFilterType
|
||||
{
|
||||
[Description("Bessel")]
|
||||
Bessel,
|
||||
[Description("Butterworth")]
|
||||
Butterworth,
|
||||
[Description("Chebyshev")]
|
||||
Chebyshev,
|
||||
//[Description("Critical Damping")] // REMOVE THIS HACK / uncomment when implemented in exocortex
|
||||
//CriticalDamping,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Viewer.Reports
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum WindowAveragingType
|
||||
{
|
||||
[Description("Averaging")]
|
||||
Averaging,
|
||||
[Description("Peak Hold MAX")]
|
||||
PeakHoldMax,
|
||||
[Description("Peak Hold MIN")]
|
||||
PeakHoldMin,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Viewer.Reports
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum WindowType
|
||||
{
|
||||
[Description("Rectangle")]
|
||||
Rectangle,
|
||||
[Description("Hamming")]
|
||||
Hamming,
|
||||
[Description("Hanning")]
|
||||
Hanning,
|
||||
[Description("Blackman")]
|
||||
Blackman,
|
||||
[Description("Blackman-Harris")]
|
||||
BlackmanHarris,
|
||||
[Description("Flat Top")]
|
||||
FlatTop
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Viewer.Reports
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum WindowWidth
|
||||
{
|
||||
[Description("512")]
|
||||
FiveTwelve = 512,
|
||||
[Description("1024")]
|
||||
TenTwentyFour = 1024,
|
||||
[Description("2048")]
|
||||
TwentyFortyEight = 2048,
|
||||
[Description("4096")]
|
||||
FortyNinetySix = 4096,
|
||||
[Description("8192")]
|
||||
EightyOneNinetyTwo = 8192,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum ChannelGroups
|
||||
{
|
||||
Channel,
|
||||
Graph,
|
||||
CalculatedChannel,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,74 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum TestChannelFields
|
||||
{
|
||||
SerialNumber,
|
||||
ChannelId,
|
||||
Description,
|
||||
ChannelGroupName,
|
||||
ChannelType,
|
||||
Number,
|
||||
DigitalMultiplier,
|
||||
DigitalMode,
|
||||
Start,
|
||||
Bridge,
|
||||
BridgeResistanceOhms,
|
||||
ZeroPoint,
|
||||
ChannelDescriptionString,
|
||||
ChannelName2,
|
||||
HardwareChannelName,
|
||||
DesiredRange,
|
||||
Sensitivity,
|
||||
SoftwareFilter,
|
||||
ProportionalToExcitation,
|
||||
IsInverted,
|
||||
LinearizationFormula,
|
||||
IsSubsampled,
|
||||
AbsoluteDisplayOrder,
|
||||
LastCalibrationDate,
|
||||
SensorId,
|
||||
OffsetToleranceLowMv,
|
||||
OffsetToleranceHighMv,
|
||||
DataFlag,
|
||||
ExcitationVoltage,
|
||||
Eu,
|
||||
CalSignalEnabled,
|
||||
ShuntEnabled,
|
||||
VoltageInsertionCheckEnabled,
|
||||
RemoveOffset,
|
||||
ZeroMethod,
|
||||
ZeroAverageWindowBegin,
|
||||
ZeroAverageWindowEnd,
|
||||
InitialEu,
|
||||
InitialOffset,
|
||||
UnsubsampledSampleRateHz,
|
||||
MeasuredShuntDeflectionMv,
|
||||
TargetShuntDeflectionMv,
|
||||
MeasuredExcitationVoltage,
|
||||
FactoryExcitationVoltage,
|
||||
TimeOfFirstSample,
|
||||
Multiplier,
|
||||
UserOffsetEU,
|
||||
UnitConversion,
|
||||
AtCapacity,
|
||||
CapacityOutputIsBasedOn,
|
||||
SensitivityUnits,
|
||||
SensorCapacity,
|
||||
SourceChannelNumber,
|
||||
SourceModuleNumber,
|
||||
SourceModuleSerialNumber,
|
||||
Calculation,
|
||||
SampleRateHz,
|
||||
IsoCode,
|
||||
IsoChannelName,
|
||||
UserCode,
|
||||
UserChannelName,
|
||||
SensorPolarity,
|
||||
HIC,
|
||||
UseEUScaler,
|
||||
ScaleFactorEU,
|
||||
T1,
|
||||
T2
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum TestGraphsFields
|
||||
{
|
||||
Name,
|
||||
HardwareChannelName,
|
||||
Channels,
|
||||
Channel,
|
||||
ChannelId
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,42 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum TestModuleFields
|
||||
{
|
||||
SerialNumber,
|
||||
BaseSerialNumber,
|
||||
AaFilterRateHz,
|
||||
Number,
|
||||
NumberOfSamples,
|
||||
UnsubsampledNumberOfSamples,
|
||||
RequestedPostTriggerSeconds,
|
||||
RequestedPreTriggerSeconds,
|
||||
PostTriggerSeconds,
|
||||
PreTriggerSeconds,
|
||||
RecordingMode,
|
||||
SampleRateHz,
|
||||
StartRecordSampleNumber,
|
||||
NumberOfChannels,
|
||||
InlineSerializedData,
|
||||
StartRecordTimestampSec,
|
||||
StartRecordTimestampNanoSec,
|
||||
TriggerTimestampSec,
|
||||
TriggerTimestampNanoSec,
|
||||
TriggerSampleNumbers,
|
||||
PTPMasterSync,
|
||||
TiltSensorAxisXDegreesPre,
|
||||
TiltSensorAxisYDegreesPre,
|
||||
TiltSensorAxisZDegreesPre,
|
||||
TiltSensorAxisXDegreesPost,
|
||||
TiltSensorAxisYDegreesPost,
|
||||
TiltSensorAxisZDegreesPost,
|
||||
TemperatureLocation1Pre,
|
||||
TemperatureLocation2Pre,
|
||||
TemperatureLocation3Pre,
|
||||
TemperatureLocation4Pre,
|
||||
TemperatureLocation1Post,
|
||||
TemperatureLocation2Post,
|
||||
TemperatureLocation3Post,
|
||||
TemperatureLocation4Post
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,22 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum TestRunMetadataFields
|
||||
{
|
||||
Id,
|
||||
Description,
|
||||
InlineSerializedData,
|
||||
Guid,
|
||||
FaultFlags,
|
||||
Software,
|
||||
SoftwareVersion,
|
||||
DataType,
|
||||
FileDate,
|
||||
FilePath,
|
||||
Modules,
|
||||
Module,
|
||||
Channels,
|
||||
CalculatedChannels,
|
||||
CalculatedChannel
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// ReSharper disable once CheckNamespace
|
||||
namespace DTS.Common.Enums.Viewer
|
||||
{
|
||||
public enum TestSetupMetadataFields
|
||||
{
|
||||
Name,
|
||||
DateOfTheTest,
|
||||
Graphs,
|
||||
Timestamp,
|
||||
CalibrationBehavior
|
||||
}
|
||||
}
|
||||
35
Common/DTS.CommonCore/Enums/DataFlag.cs
Normal file
35
Common/DTS.CommonCore/Enums/DataFlag.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
// ReSharper disable ConvertToAutoProperty
|
||||
// ReSharper disable once CheckNamespace
|
||||
|
||||
namespace DTS.Common
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum DataFlag
|
||||
{
|
||||
[Description("None")]
|
||||
None = 0,
|
||||
[Description("Normal")]
|
||||
Normal = 1,
|
||||
[Description("Saturated")]
|
||||
Saturated = 2,
|
||||
[Description("Zero Crossing Error")]
|
||||
ZeroCrossing = 3,
|
||||
[Description("Broken Wire")]
|
||||
BrokenWire = 4,
|
||||
[Description("Other")]
|
||||
Other = -1
|
||||
}
|
||||
|
||||
public class DataFlagItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<DataFlag>();
|
||||
}
|
||||
}
|
||||
}
|
||||
9
Common/DTS.CommonCore/Enums/Database/DbType.cs
Normal file
9
Common/DTS.CommonCore/Enums/Database/DbType.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace DTS.Common.Enums.Database
|
||||
{
|
||||
public enum DbType
|
||||
{
|
||||
RemoteOnly = 0,
|
||||
LocalOnly = 1,
|
||||
RemoteLocalHybrid = 2
|
||||
}
|
||||
}
|
||||
23
Common/DTS.CommonCore/Enums/DigitalInputs.cs
Normal file
23
Common/DTS.CommonCore/Enums/DigitalInputs.cs
Normal file
@@ -0,0 +1,23 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Base.Classes;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
/// <summary>
|
||||
/// these are the different input modes for the data
|
||||
/// </summary>
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum DigitalInputModes
|
||||
{
|
||||
NONE = 1 << 0, //DI's input mode not set
|
||||
[DescriptionResource("DigitalInputMode_TLH")]
|
||||
TLH = 1 << 1, //Transition Low to High
|
||||
[DescriptionResource("DigitalInputMode_THL")]
|
||||
THL = 1 << 2, //Transition High to Low
|
||||
[DescriptionResource("DigitalInputMode_CCNO")]
|
||||
CCNO = 1 << 3, //set to contact closure normally open
|
||||
[DescriptionResource("DigitalInputMode_CCNC")]
|
||||
CCNC = 1 << 4 //set to contact closure normally closed
|
||||
}
|
||||
}
|
||||
21
Common/DTS.CommonCore/Enums/DigitalOutputs.cs
Normal file
21
Common/DTS.CommonCore/Enums/DigitalOutputs.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Base.Classes;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum DigitalOutputModes
|
||||
{
|
||||
[Description("Off")]
|
||||
NONE = 0, //digital channel's mode not set
|
||||
[DescriptionResource("DigitalOutputMode_FVLH")]
|
||||
FVLH = 1 << 0, //set for 5 volt, low-to-high transition
|
||||
[DescriptionResource("DigitalOutputMode_FVHL")]
|
||||
FVHL = 1 << 1, //set for 5 volt, high-to-low transition
|
||||
[DescriptionResource("DigitalOutputMode_CCNO")]
|
||||
CCNO = 1 << 2, //set to contact closure normally open
|
||||
[DescriptionResource("DigitalOutputMode_CCNC")]
|
||||
CCNC = 1 << 3 //set to contact closure normally closed
|
||||
}
|
||||
}
|
||||
54
Common/DTS.CommonCore/Enums/EnumBindingSourceExtension.cs
Normal file
54
Common/DTS.CommonCore/Enums/EnumBindingSourceExtension.cs
Normal file
@@ -0,0 +1,54 @@
|
||||
using System;
|
||||
using System.Windows.Markup;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public class EnumBindingSourceExtension : MarkupExtension
|
||||
{
|
||||
private Type _enumType;
|
||||
public Type EnumType
|
||||
{
|
||||
get => _enumType;
|
||||
set
|
||||
{
|
||||
if (value == _enumType) { return; }
|
||||
if (null != value)
|
||||
{
|
||||
var enumType = Nullable.GetUnderlyingType(value) ?? value;
|
||||
if (!enumType.IsEnum)
|
||||
{
|
||||
throw new ArgumentException("Type must be for an Enum.");
|
||||
}
|
||||
}
|
||||
_enumType = value;
|
||||
}
|
||||
}
|
||||
|
||||
public EnumBindingSourceExtension() { }
|
||||
|
||||
public EnumBindingSourceExtension(Type enumType)
|
||||
{
|
||||
EnumType = enumType;
|
||||
}
|
||||
|
||||
public override object ProvideValue(IServiceProvider serviceProvider)
|
||||
{
|
||||
if (null == _enumType)
|
||||
{
|
||||
throw new InvalidOperationException("The EnumType must be specified.");
|
||||
}
|
||||
|
||||
var actualEnumType = Nullable.GetUnderlyingType(_enumType) ?? _enumType;
|
||||
var enumValues = Enum.GetValues(actualEnumType);
|
||||
|
||||
if (actualEnumType == _enumType)
|
||||
{
|
||||
return enumValues;
|
||||
}
|
||||
|
||||
var tempArray = Array.CreateInstance(actualEnumType, enumValues.Length + 1);
|
||||
enumValues.CopyTo(tempArray, 1);
|
||||
return tempArray;
|
||||
}
|
||||
}
|
||||
}
|
||||
99
Common/DTS.CommonCore/Enums/ExcitationVoltageOptions.cs
Normal file
99
Common/DTS.CommonCore/Enums/ExcitationVoltageOptions.cs
Normal file
@@ -0,0 +1,99 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using DTS.Common.Utilities;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public class ExcitationVoltageOptions
|
||||
{
|
||||
/// <summary>
|
||||
/// All available excitation voltages.
|
||||
/// </summary>
|
||||
public enum ExcitationVoltageOption
|
||||
{
|
||||
/// <summary>
|
||||
/// undefined excitation voltage
|
||||
/// </summary>
|
||||
[VoltageMagnitude(0.0)]
|
||||
[Description("Undefined")]
|
||||
Undefined = 1,
|
||||
/// <summary>
|
||||
/// 2V
|
||||
/// </summary>
|
||||
[VoltageMagnitude(2.0)]
|
||||
[Description("2.0")]
|
||||
Volt2 = 2,
|
||||
/// <summary>
|
||||
/// 2.5V
|
||||
/// </summary>
|
||||
[VoltageMagnitude(2.5)]
|
||||
[Description("2.5")]
|
||||
Volt2_5 = 4,
|
||||
/// <summary>
|
||||
/// 3.0V
|
||||
/// </summary>
|
||||
[VoltageMagnitude(3.0)]
|
||||
[Description("3.0")]
|
||||
Volt3 = 8,
|
||||
/// <summary>
|
||||
/// 5V
|
||||
/// </summary>
|
||||
[VoltageMagnitude(5.0)]
|
||||
[Description("5.0")]
|
||||
Volt5 = 16,
|
||||
/// <summary>
|
||||
/// 10V
|
||||
/// </summary>
|
||||
[VoltageMagnitude(10.0)]
|
||||
[Description("10.0")]
|
||||
Volt10 = 32,
|
||||
/// <summary>
|
||||
/// 1V
|
||||
/// </summary>
|
||||
[VoltageMagnitude(1.0)]
|
||||
[Description("1.0")]
|
||||
Volt1 = 64
|
||||
}
|
||||
/// <summary>
|
||||
/// Attribute for specifying the numerical magnitude of the attached field's
|
||||
/// "representation". Intended to be used with enumerations whose members represent
|
||||
/// voltage magnitude options so that the enum item can have a corresponding numerical
|
||||
/// value that can be extracted and used in calculations.
|
||||
/// </summary>
|
||||
[AttributeUsage(AttributeTargets.Field)]
|
||||
public class VoltageMagnitudeAttribute : Attribute
|
||||
{
|
||||
/// <summary>
|
||||
/// returns voltage magnitude
|
||||
/// </summary>
|
||||
public double Value { get; }
|
||||
|
||||
/// <summary>
|
||||
/// constructs a <see cref="ExcitationVoltageOptions.VoltageMagnitudeAttribute" />
|
||||
/// with a given value
|
||||
/// </summary>
|
||||
/// <param name="value"></param>
|
||||
public VoltageMagnitudeAttribute(double value) { Value = value; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Object for manipulating voltage option enumeration-attached
|
||||
/// <see cref="double"/> magnitude values.
|
||||
/// </summary>
|
||||
public class VoltageMagnitudeAttributeCoder
|
||||
: AttributeCoder<ExcitationVoltageOptions.ExcitationVoltageOption, VoltageMagnitudeAttribute, double>
|
||||
{
|
||||
/// <summary>
|
||||
/// Initializes a <see cref="ExcitationVoltageOptions.VoltageMagnitudeAttributeCoder"/> object.
|
||||
/// </summary>
|
||||
public VoltageMagnitudeAttributeCoder()
|
||||
: base(attribute => attribute.Value, null)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
157
Common/DTS.CommonCore/Enums/ExportHeaderLine.cs
Normal file
157
Common/DTS.CommonCore/Enums/ExportHeaderLine.cs
Normal file
@@ -0,0 +1,157 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
using System.Reflection;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public static class HeaderLineExtension
|
||||
{
|
||||
public static string GetDescription(this Enum genericEnum)
|
||||
{
|
||||
Type genericEnumType = genericEnum.GetType();
|
||||
MemberInfo[] memberInfo = genericEnumType.GetMember(genericEnum.ToString());
|
||||
if ((memberInfo != null && memberInfo.Length > 0))
|
||||
{
|
||||
var attribs = memberInfo[0].GetCustomAttributes(typeof(DescriptionAttribute), false);
|
||||
if (attribs != null && attribs.Any())
|
||||
{
|
||||
return ((DescriptionAttribute)attribs.ElementAt(0)).Description;
|
||||
}
|
||||
}
|
||||
return genericEnum.ToString();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The various header lines (and associated text) that appear in CSV file format.
|
||||
/// </summary>
|
||||
public enum FtssHeaderLine
|
||||
{
|
||||
[Description("Headers")] Headers = 0,
|
||||
|
||||
[Description("Test Date")] TestDate,
|
||||
|
||||
[Description("Test Time")] TestTime,
|
||||
|
||||
[Description("Test ID")] TestId,
|
||||
|
||||
[Description("Test Description")] TestDescription,
|
||||
|
||||
[Description("Sample Rate (Hz)")] SampleRate,
|
||||
|
||||
[Description("Hardware AA Filter (-3dB)")]
|
||||
HardwareAntiAliasFilter,
|
||||
|
||||
[Description("Data Channel Number")] DataChannelNumber,
|
||||
|
||||
[Description("ISO Channel Code")] IsoCode,
|
||||
|
||||
[Description("User Channel Code")] UserCode,
|
||||
|
||||
[Description("Channel Description")] ChannelDescription,
|
||||
|
||||
[Description("Channel Location")] ChannelLocation,
|
||||
|
||||
[Description("Sensor S/N")] SensorSerialNumber,
|
||||
|
||||
[Description("Sensor Calibration Date")] SensorCalDate, //17651: include sensor cal date in CSV exports
|
||||
|
||||
[Description("Software Filter (SAE Class)")]
|
||||
SoftwareFilter,
|
||||
|
||||
[Description("Software Filter (-3dB)")]
|
||||
SoftwareFilterDb,
|
||||
|
||||
[Description("Engineering Unit")] EngineeringUnits,
|
||||
|
||||
[Description("User Comment")] UserComment,
|
||||
|
||||
[Description("Number of Pre-Zero Data Pts")]
|
||||
PreZero,
|
||||
|
||||
[Description("Number of Post-Zero Data Pts")]
|
||||
PostZero,
|
||||
|
||||
[Description("Data Zero (CNTS)")] DataZero,
|
||||
|
||||
[Description("Scale Factor (EU/CNT)")] ScaleEu,
|
||||
|
||||
[Description("Scale Factor (mV/CNT)")] ScaleMv,
|
||||
|
||||
[Description("Channel Name")] ChannelName,
|
||||
|
||||
[Description("Display Name")] DisplayName,
|
||||
|
||||
[Description("DAS Serial Number")]
|
||||
HardwareLine,
|
||||
|
||||
[Description("Zero Method")] ZeroMethod,
|
||||
|
||||
[Description("Remove Offset")] RemoveOffset,
|
||||
|
||||
[Description("Group Name")] GroupName,
|
||||
|
||||
[Description("Time of T0 (UTC)")] Timestamp, // FB15333: Add PTP/RTC timestamp column for CSV exports
|
||||
|
||||
[Description("Data Starts Here")] DataStart,
|
||||
|
||||
[Description("Time")] Labels,
|
||||
}
|
||||
/// <summary>
|
||||
/// The various header lines (and associated text) that appear in XLSX file format.
|
||||
/// </summary>
|
||||
public enum XLSXExportHeaderLine
|
||||
{
|
||||
[Description("Headers")] Headers = 0,
|
||||
|
||||
[Description("Test Date")] TestDate,
|
||||
|
||||
[Description("Test Time")] TestTime,
|
||||
|
||||
[Description("Test ID")] TestId,
|
||||
|
||||
[Description("Test Description")] TestDescription,
|
||||
|
||||
[Description("Sample Rate (Hz)")] SampleRate,
|
||||
|
||||
[Description("Hardware AA Filter (-3dB)")]
|
||||
HardwareAntiAliasFilter,
|
||||
|
||||
[Description("Data Channel Number")] DataChannelNumber,
|
||||
|
||||
[Description("ISO Channel Code")] IsoCode,
|
||||
|
||||
[Description("Channel Description")] ChannelDescription,
|
||||
|
||||
[Description("Channel Location")] ChannelLocation,
|
||||
|
||||
[Description("Sensor S/N")] SensorSerialNumber,
|
||||
|
||||
[Description("Software Filter (SAE Class)")]
|
||||
SoftwareFilter,
|
||||
|
||||
[Description("Software Filter (-3dB)")]
|
||||
SoftwareFilterDb,
|
||||
|
||||
[Description("Engineering Unit")] EngineeringUnits,
|
||||
|
||||
[Description("User Comment")] UserComment,
|
||||
|
||||
[Description("Number of Pre-Zero Data Pts")]
|
||||
PreZero,
|
||||
|
||||
[Description("Number of Post-Zero Data Pts")]
|
||||
PostZero,
|
||||
|
||||
[Description("Data Zero (CNTS)")] DataZero,
|
||||
|
||||
[Description("Scale Factor (EU/CNT)")] ScaleEu,
|
||||
|
||||
[Description("Scale Factor (mV/CNT)")] ScaleMv,
|
||||
|
||||
[Description("Data Starts Here")] DataStart,
|
||||
|
||||
[Description("Time")] Labels,
|
||||
}
|
||||
}
|
||||
8
Common/DTS.CommonCore/Enums/GPSSentenceTypes.cs
Normal file
8
Common/DTS.CommonCore/Enums/GPSSentenceTypes.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public enum GPSSentenceTypes
|
||||
{
|
||||
GPGGA,
|
||||
GPRMC
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
|
||||
namespace DTS.Common.Enums.GroupTemplates
|
||||
{
|
||||
public enum GroupTemplateChannelFields
|
||||
{
|
||||
Required,
|
||||
Name,
|
||||
ISOCode,
|
||||
Custom,
|
||||
DisplayOrder
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
|
||||
|
||||
namespace DTS.Common.Enums.GroupTemplates
|
||||
{
|
||||
public enum GroupTemplateFields
|
||||
{
|
||||
Name,
|
||||
Description,
|
||||
Channels,
|
||||
LastModifiedBy,
|
||||
LastModified,
|
||||
AssociatedGroups
|
||||
}
|
||||
}
|
||||
12
Common/DTS.CommonCore/Enums/Groups/GroupImport.cs
Normal file
12
Common/DTS.CommonCore/Enums/Groups/GroupImport.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
namespace DTS.Common.Enums.Groups
|
||||
{
|
||||
public abstract class GroupImportEnums
|
||||
{
|
||||
public enum Steps
|
||||
{
|
||||
Options,
|
||||
Preview,
|
||||
Import
|
||||
}
|
||||
}
|
||||
}
|
||||
26
Common/DTS.CommonCore/Enums/Groups/GroupList/GroupFields.cs
Normal file
26
Common/DTS.CommonCore/Enums/Groups/GroupList/GroupFields.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
|
||||
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Groups.GroupList
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum GroupFields
|
||||
{
|
||||
[Description("GroupField_Name")]
|
||||
Name,
|
||||
[Description("GroupField_DisplayName")]
|
||||
DisplayName,
|
||||
[Description("GroupField_Description")]
|
||||
Description,
|
||||
[Description("GroupField_ChannelCount")]
|
||||
ChannelCount,
|
||||
[Description("GroupField_LastModified")]
|
||||
LastModified,
|
||||
[Description("GroupField_LastModifiedBy")]
|
||||
LastModifiedBy,
|
||||
[Description("GroupField_AssociatedTestSetups")]
|
||||
AssociatedTestSetups
|
||||
}
|
||||
}
|
||||
17
Common/DTS.CommonCore/Enums/Hardware/HardwareListTags.cs
Normal file
17
Common/DTS.CommonCore/Enums/Hardware/HardwareListTags.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
namespace DTS.Common.Enums.Hardware
|
||||
{
|
||||
public enum HardwareListTags
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
HardwareType,
|
||||
ChannelCount,
|
||||
Firmware,
|
||||
MaxSampleRate,
|
||||
TestSampleRate,
|
||||
CalDate,
|
||||
CalDueDate,
|
||||
IPAddress,
|
||||
FirstUseDate
|
||||
}
|
||||
}
|
||||
496
Common/DTS.CommonCore/Enums/Hardware/HardwareTypes.cs
Normal file
496
Common/DTS.CommonCore/Enums/Hardware/HardwareTypes.cs
Normal file
@@ -0,0 +1,496 @@
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Enums.DASFactory;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Constant.DASSpecific;
|
||||
using System.Windows.Media;
|
||||
using DTS.Common.Interface.DataRecorders;
|
||||
|
||||
namespace DTS.Common.Enums.Hardware
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum HardwareTypes
|
||||
{
|
||||
SLICE_Base = 0,
|
||||
SLICE_Bridge = 1,
|
||||
[Description("SLICE_Distributor_Description")]
|
||||
SLICE_Distributor = 2,
|
||||
[Description("TDAS_Pro_Rack_Description")]
|
||||
TDAS_Pro_Rack = 3,
|
||||
SLICE2_IEPE_Hi = 4,
|
||||
SLICE2_IEPE_Lo = 5,
|
||||
SLICE2_Bridge_Hi = 6,
|
||||
SLICE2_Bridge_Lo = 7,
|
||||
SLICE2_Base = 8,
|
||||
TOM = 9,
|
||||
SIM = 10,
|
||||
DIM = 11,
|
||||
[Description("G5_VDS_Description")]
|
||||
G5VDS = 12,
|
||||
Ribeye = 13,
|
||||
RibeyeLED = 14,
|
||||
SLICE_IEPE = 15,
|
||||
[Description("SLICE1_5Nano_Description")]
|
||||
SLICE1_5_Nano_Base = 16,
|
||||
[Description("SLICE_Micro_Description")]
|
||||
SLICE_Micro_Base = 17,
|
||||
[Description("SLICE_Nano_Description")]
|
||||
SLICE_NANO_Base = 18,
|
||||
[Description("SLICE2_SIM_Description")]
|
||||
SLICE2_SIM = 19,
|
||||
[Description("SLICE2_DIM_Description")]
|
||||
SLICE2_DIM = 20,
|
||||
[Description("SLICE2_TOM_Description")]
|
||||
SLICE2_TOM = 21,
|
||||
//G5IPORT=22,
|
||||
[Description("G5InDummy_Description")]
|
||||
G5INDUMMY = 23,
|
||||
[Description("SLICE_EthernetController_Description")]
|
||||
SLICE_EthernetController = 24,
|
||||
[Description("SLICE_15Micro_Description")]
|
||||
SLICE1_5_Micro_Base = 25,
|
||||
[Description("SLICE_Lab_Ethernet_Description")]
|
||||
SLICE_LabEthernet = 26,
|
||||
[Description("SLICE2_SLS_Description")]
|
||||
SLICE2_SLS = 27,
|
||||
[Description("SLICE1_G5Stack_Description")]
|
||||
SLICE1_G5Stack = 28,
|
||||
[Description("SLICE2_SLT_Description")]
|
||||
SLICE2_SLT = 29,
|
||||
[Description("SLICE2_SLD_Description")]
|
||||
SLICE2_SLD = 30,
|
||||
[Description("TDAS_LabRack_Description")]
|
||||
TDAS_LabRack = 31,
|
||||
[Description("SLICE6_Base_Description")]
|
||||
SLICE6_Base = 32,
|
||||
[Description("SLICE6_DB_Description")]
|
||||
SLICE6DB = 33,
|
||||
[Description("SLICE6_DBInDummy_Description")]
|
||||
SLICE6DB_InDummy = 34,
|
||||
//doesn't exist
|
||||
//[Description("SLICE6_DBAir_Description")]
|
||||
//SLICE6DB_AIR = 35,
|
||||
[Description("SLICE6_AIR_Description")]
|
||||
SLICE6_AIR = 36,
|
||||
[Description("PowerPRO_Description")]
|
||||
PowerPro = 37,
|
||||
[Description("HardwareType_EMPTY")]
|
||||
UNDEFINED = 38,
|
||||
[Description("SLICE_Mini_Distributor_Description")]
|
||||
SLICE_Mini_Distributor = 39,
|
||||
[Description("TSR_AIR_Description")]
|
||||
TSR_AIR = 40, // TSR Air "Rev A"
|
||||
[Description("TSR_AIR_RevB_Description")]
|
||||
TSR_AIR_RevB = 41, // TSR Air "Rev B"
|
||||
[Description("DKR_Description")]
|
||||
DKR = 42, // NGTSR - NASA SBIR
|
||||
[Description("DIR_Description")]
|
||||
DIR = 43, // NGTSR - USAF SBIR
|
||||
[Description("Embedded_LowG_Module_Description")]
|
||||
EMB_LIN_ACC_LO = 44,
|
||||
[Description("Embedded_HighG_Module_Description")]
|
||||
EMB_LIN_ACC_HI = 45,
|
||||
[Description("Embedded_Angular_Module_Description")]
|
||||
EMB_ANG_ACC = 46,
|
||||
[Description("Embedded_ARS_Module_Description")]
|
||||
EMB_ANG_ARS = 47,
|
||||
[Description("Embedded_Atmosphere_Module_Description")]
|
||||
EMB_ATM = 48,
|
||||
[Description("Embedded_Magnetometer_Module_Description")]
|
||||
EMB_MAG = 49,
|
||||
[Description("Embedded_MagnetSwitch_Module_Description")]
|
||||
EMB_MAG_SWITCH = 50,
|
||||
[Description("Embedded_Microphone_Module_Description")]
|
||||
EMB_MIC = 51,
|
||||
[Description("Embedded_Optical_Module_Description")]
|
||||
EMB_OPT = 52,
|
||||
[Description("Embedded_Clock_Seconds_Module_Description")]
|
||||
EMB_RTC_S_MARK = 53,
|
||||
[Description("Embedded_Clock_Nanos_Module_Description")]
|
||||
EMB_RTC_NS_PAD = 54,
|
||||
[Description("SLICE6DB3_Description")]
|
||||
SLICE6DB3 = 55,
|
||||
[Description("SLICE6ER_Description")]
|
||||
S6A_EthernetRecorder = 56,
|
||||
//(25460 Placeholder)
|
||||
[Description("SLICE_Pro_Distributor_Description")]
|
||||
SLICE_Pro_Distributor = 57,
|
||||
//28283 SLICE6AIR-BR (falcon-id) infrastructure
|
||||
[Description("SLICE6_AIR_BR_Description")]
|
||||
SLICE6_AIR_BR = 58,
|
||||
}
|
||||
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum SLICEBridgeTypes
|
||||
{
|
||||
[Description("BRIDGETYPE_BRIDGE_DESCRIPTION")]
|
||||
Bridge,
|
||||
[Description("BRIDGETYPE_IEPE_DESCRIPTION")]
|
||||
IEPE,
|
||||
[Description("BRIDGETYPE_ARS_DESCRIPTION")]
|
||||
ARS,
|
||||
[Description("BRIDGETYPE_ACC_DESCRIPTION")]
|
||||
ACC,
|
||||
[Description("BRIDGETYPE_RTC_DESCRIPTION")]
|
||||
RTC,
|
||||
[Description("BRIDGETYPE_UART_DESCRIPTION")]
|
||||
UART,
|
||||
[Description("BRIDGETYPE_STREAM_OUT_DESCRIPTION")]
|
||||
StreamOut
|
||||
}
|
||||
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum RackSizes
|
||||
{
|
||||
[Description("RACK_SIZE_4M")]
|
||||
FOUR,
|
||||
[Description("RACK_SIZE_8M")]
|
||||
EIGHT
|
||||
}
|
||||
|
||||
public abstract class HardwareConstants
|
||||
{
|
||||
public static SolidColorBrush GetBrushForVoltageStatus(DFConstantsAndEnums.VoltageStatusColor status)
|
||||
{
|
||||
switch (status)
|
||||
{
|
||||
case DFConstantsAndEnums.VoltageStatusColor.Green:
|
||||
return BrushesAndColors.BrushApplicationStatusPowerGreen;
|
||||
case DFConstantsAndEnums.VoltageStatusColor.Red:
|
||||
return BrushesAndColors.BrushApplicationStatusPowerRed;
|
||||
case DFConstantsAndEnums.VoltageStatusColor.Yellow:
|
||||
return BrushesAndColors.BrushApplicationStatusPowerYellow;
|
||||
case DFConstantsAndEnums.VoltageStatusColor.Off:
|
||||
default:
|
||||
return BrushesAndColors.BrushApplicationStatusPowerClear;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// returns whether the device supports trigger inversion or not
|
||||
/// currently only SLICE1, SLICE1.5, SLICE2 support it and only when connected via USB?
|
||||
/// protocol version could be a deciding factor for whether a device supports trigger inversion
|
||||
/// </summary>
|
||||
/// <param name="type">type of DAS</param>
|
||||
/// <param name="protocolVersion">protocol version of das</param>
|
||||
/// <returns>true if the device supports trigger inversion, false otherwise</returns>
|
||||
public static bool SupportsTriggerInversion(HardwareTypes type, int protocolVersion)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case HardwareTypes.SLICE1_5_Micro_Base:
|
||||
case HardwareTypes.SLICE_Base:
|
||||
case HardwareTypes.SLICE2_Base:
|
||||
case HardwareTypes.SLICE_IEPE:
|
||||
case HardwareTypes.SLICE1_5_Nano_Base:
|
||||
case HardwareTypes.SLICE_Micro_Base:
|
||||
case HardwareTypes.SLICE_NANO_Base:
|
||||
case HardwareTypes.SLICE2_SIM:
|
||||
case HardwareTypes.SLICE2_DIM:
|
||||
case HardwareTypes.SLICE2_TOM:
|
||||
case HardwareTypes.SLICE2_SLS:
|
||||
case HardwareTypes.SLICE1_G5Stack:
|
||||
case HardwareTypes.SLICE2_SLT:
|
||||
case HardwareTypes.SLICE2_SLD:
|
||||
return true;
|
||||
default: return false;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// returns whether the device supports start inversion or not
|
||||
/// currently only SLICE1, SLICE1.5, SLICE2 support it and only when connected via USB?
|
||||
/// protocol version could be a deciding factor for whether a device supports start inversion
|
||||
/// </summary>
|
||||
/// <param name="type">type of DAS</param>
|
||||
/// <param name="protocolVersion">protocol version of das</param>
|
||||
/// <returns>true if the device supports start inversion, false otherwise</returns>
|
||||
public static bool SupportsStartInversion(HardwareTypes type, int protocolVersion)
|
||||
{
|
||||
switch (type)
|
||||
{
|
||||
case HardwareTypes.SLICE1_5_Micro_Base:
|
||||
case HardwareTypes.SLICE_Base:
|
||||
case HardwareTypes.SLICE2_Base:
|
||||
case HardwareTypes.SLICE_IEPE:
|
||||
case HardwareTypes.SLICE1_5_Nano_Base:
|
||||
case HardwareTypes.SLICE_Micro_Base:
|
||||
case HardwareTypes.SLICE_NANO_Base:
|
||||
case HardwareTypes.SLICE2_SIM:
|
||||
case HardwareTypes.SLICE2_DIM:
|
||||
case HardwareTypes.SLICE2_TOM:
|
||||
case HardwareTypes.SLICE2_SLS:
|
||||
case HardwareTypes.SLICE1_G5Stack:
|
||||
case HardwareTypes.SLICE2_SLT:
|
||||
case HardwareTypes.SLICE2_SLD:
|
||||
case HardwareTypes.SLICE6_AIR:
|
||||
return true;
|
||||
default: return false;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// returns true if the hardware type is a type of ethernet recorder
|
||||
/// </summary>
|
||||
/// <param name="type"></param>
|
||||
/// <returns></returns>
|
||||
public static bool IsEthernetRecorder(HardwareTypes type)
|
||||
{
|
||||
return type == HardwareTypes.S6A_EthernetRecorder;
|
||||
}
|
||||
public const int INVALID_IDASCOMMUNICATION_RECORD_ID = -1;
|
||||
/// <summary>
|
||||
/// this is just a global variable for whether to allow soft disconnects or not
|
||||
/// and provide access to the variable across modules
|
||||
/// must be set by the application.
|
||||
/// </summary>
|
||||
public static bool AllowSoftDisconnects { get; set; } = false;
|
||||
public const int DEFAULTMEMORYSIZE_PRO = 16000000;
|
||||
public const int DEFAULTMEMORYSIZE_DIM = 2000000;
|
||||
public const int DEFAULTMEMORYSIZE_TOM = 2000000;
|
||||
/// <summary>
|
||||
/// returns true if the hardware in question uses embedded sensors
|
||||
/// </summary>
|
||||
/// <param name="hardware"></param>
|
||||
/// <returns></returns>
|
||||
public static bool HasEmbeddedSensors(HardwareTypes hardware)
|
||||
{
|
||||
switch (hardware)
|
||||
{
|
||||
case HardwareTypes.EMB_ANG_ACC:
|
||||
case HardwareTypes.EMB_ANG_ARS:
|
||||
case HardwareTypes.EMB_ATM:
|
||||
case HardwareTypes.EMB_LIN_ACC_HI:
|
||||
case HardwareTypes.EMB_LIN_ACC_LO:
|
||||
case HardwareTypes.EMB_MAG:
|
||||
case HardwareTypes.EMB_MAG_SWITCH:
|
||||
case HardwareTypes.EMB_MIC:
|
||||
case HardwareTypes.EMB_OPT:
|
||||
case HardwareTypes.EMB_RTC_NS_PAD:
|
||||
case HardwareTypes.EMB_RTC_S_MARK:
|
||||
case HardwareTypes.TSR_AIR:
|
||||
case HardwareTypes.TSR_AIR_RevB:
|
||||
case HardwareTypes.DIR:
|
||||
case HardwareTypes.DKR:
|
||||
return true;
|
||||
default: return false;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// returns whether the given channel type is supported by the given das for TSR AIR variants
|
||||
/// 18284 DKR device should only populate channels that are embedded in the device
|
||||
/// </summary>
|
||||
/// <param name="hardware"></param>
|
||||
/// <param name="channelType"></param>
|
||||
/// <returns></returns>
|
||||
public static bool HasEmbeddedChannelType(HardwareTypes hardware, string channelType)
|
||||
{
|
||||
if( hardware == HardwareTypes.TSR_AIR || hardware == HardwareTypes.TSR_AIR_RevB) { return true; }
|
||||
switch (channelType)
|
||||
{
|
||||
case DFConstantsAndEnums.LOWG_SERIAL_APPEND: return true;
|
||||
case DFConstantsAndEnums.HIGHG_SERIAL_APPEND: return hardware == HardwareTypes.DIR;
|
||||
case DFConstantsAndEnums.ARS_SERIAL_APPEND: return false;
|
||||
case DFConstantsAndEnums.ANGACCEL_SERIAL_APPEND: return true;
|
||||
case DFConstantsAndEnums.ATMOSPHERIC_SERIAL_APPEND: return false;
|
||||
case DFConstantsAndEnums.OPTICAL_SERIAL_APPEND: return false;
|
||||
case DFConstantsAndEnums.MAGNETIC_SERIAL_APPEND: return false;
|
||||
case DFConstantsAndEnums.MAGNETICSWITCH_SERIAL_APPEND: return false;
|
||||
case DFConstantsAndEnums.MICROPHONE_SERIAL_APPEND: return hardware != HardwareTypes.DKR;
|
||||
case DFConstantsAndEnums.RTCSECONDANDMARKER_SERIAL_APPEND:
|
||||
case DFConstantsAndEnums.RTCCLOCKNANOPAD_SERIAL_APPEND:
|
||||
return false;
|
||||
default: return false;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// returns true if the recording mode is supported on the given hardware and protocol version
|
||||
/// </summary>
|
||||
/// <param name="mode">recording mode to check</param>
|
||||
/// <param name="dasType">hardware type</param>
|
||||
/// <param name="protocolVersion">protocol version of hardware</param>
|
||||
/// <param name="includeNativeSupportOnly">Use false (default) to find out if hardware supports given recording mode
|
||||
/// or an equivalent recording mode (example Circ Buffer, Circ Buffer + UART, use true to only consider the recording
|
||||
/// mode explicitly and not any related modes</param>
|
||||
/// <returns>true if the mode is supported, false otherwise</returns>
|
||||
public static bool IsRecordingModeSupported(RecordingModes mode, HardwareTypes dasType,
|
||||
int protocolVersion, bool includeNativeSupportOnly = false)
|
||||
{
|
||||
if (dasType != HardwareTypes.TSR_AIR && dasType != HardwareTypes.TSR_AIR_RevB)
|
||||
{
|
||||
//TODO: REMOVE THIS HACK if/when TSRAIR supports them
|
||||
switch (mode)
|
||||
{
|
||||
//All non-TSRAIR DAS support Recorder and CircularBuffer
|
||||
case RecordingModes.CircularBuffer:
|
||||
case RecordingModes.Recorder:
|
||||
return true;
|
||||
case RecordingModes.CircularBufferPlusUART:
|
||||
case RecordingModes.RecorderPlusUART:
|
||||
if (!includeNativeSupportOnly)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (dasType == HardwareTypes.SLICE6DB_InDummy || dasType == HardwareTypes.SLICE6DB3 || dasType == HardwareTypes.SLICE6DB)
|
||||
{
|
||||
if (mode == RecordingModes.RAMActive || mode == RecordingModes.MultipleEventRAMActive)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
bool result;
|
||||
switch (dasType)
|
||||
{
|
||||
case HardwareTypes.SLICE1_5_Micro_Base:
|
||||
case HardwareTypes.SLICE1_5_Nano_Base:
|
||||
result = SLICE1_5.IsRecordingModeSupported(mode, protocolVersion);
|
||||
break;
|
||||
|
||||
case HardwareTypes.SLICE6_Base:
|
||||
result = SLICE6.IsRecordingModeSupported(mode, protocolVersion);
|
||||
break;
|
||||
|
||||
case HardwareTypes.SLICE6_AIR:
|
||||
result = SLICE6AIR.IsRecordingModeSupported(mode, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE6_AIR_BR:
|
||||
result = SLICE6AIRBR.IsRecordingModeSupported(mode, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE2_TOM:
|
||||
result = SLICE2_TOM.IsRecordingModeSupported(mode, protocolVersion);
|
||||
break;
|
||||
|
||||
case HardwareTypes.TSR_AIR:
|
||||
case HardwareTypes.TSR_AIR_RevB:
|
||||
result = TSRAIR.IsRecordingModeSupported(mode, protocolVersion);
|
||||
break;
|
||||
|
||||
//TDAS hardware only supports Recorder and CircularBuffer, so if we get here the mode is not supported
|
||||
case HardwareTypes.DIM:
|
||||
case HardwareTypes.G5INDUMMY:
|
||||
case HardwareTypes.G5VDS:
|
||||
case HardwareTypes.Ribeye:
|
||||
case HardwareTypes.RibeyeLED:
|
||||
case HardwareTypes.SIM:
|
||||
case HardwareTypes.TDAS_Pro_Rack:
|
||||
case HardwareTypes.TDAS_LabRack:
|
||||
case HardwareTypes.TOM:
|
||||
result = false;
|
||||
break;
|
||||
|
||||
//All other hardware types support the same modes
|
||||
default:
|
||||
switch (mode)
|
||||
{
|
||||
case RecordingModes.MultipleEventCircularBuffer:
|
||||
case RecordingModes.MultipleEventRecorder:
|
||||
case RecordingModes.HybridRecorder:
|
||||
case RecordingModes.ContinuousRecorder:
|
||||
result = true;
|
||||
break;
|
||||
default:
|
||||
result = false;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
/// <summary>
|
||||
/// Gets the Maximum sample rate for a particular recording mode, first implemented because the maximum sample rate
|
||||
/// can vary depending on model and the baud rate set for UART recording (39151)
|
||||
/// </summary>
|
||||
/// <param name="h"></param>
|
||||
/// <param name="mode"></param>
|
||||
/// <param name="protocolVersion"></param>
|
||||
/// <param name="baudRate"></param>
|
||||
/// <returns></returns>
|
||||
public static double MaxSampleRateForRecordingMode(IDASHardware h, RecordingModes mode, int protocolVersion = 1, uint baudRate = 9600)
|
||||
{
|
||||
switch(h.DASTypeEnum)
|
||||
{
|
||||
case HardwareTypes.SLICE6_AIR:
|
||||
return SLICE6AIR.MaxSampleRateHzForRecordingMode(mode, false, protocolVersion, baudRate);
|
||||
case HardwareTypes.S6A_EthernetRecorder:
|
||||
return SLICE6AIR.MaxSampleRateHz_OBRDDR;
|
||||
default:
|
||||
return h.GetMaxSampleRateDouble();
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// returns true if the streaming profile is supported on the given hardware and protocol version
|
||||
/// </summary>
|
||||
/// <param name="profile">streaming profile to check</param>
|
||||
/// <param name="dasType">hardware type</param>
|
||||
/// <param name="protocolVersion">protocol version of hardware</param>
|
||||
/// <returns>true if the profile is supported, false otherwise</returns>
|
||||
public static bool IsStreamingProfileSupported(UDPStreamProfile profile, HardwareTypes dasType,
|
||||
int protocolVersion, bool includeNativeSupportOnly = false)
|
||||
{
|
||||
bool result;
|
||||
switch (dasType)
|
||||
{
|
||||
case HardwareTypes.SLICE6_Base:
|
||||
result = SLICE6.IsStreamingProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE6_AIR:
|
||||
result = SLICE6AIR.IsStreamingProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE6_AIR_BR:
|
||||
result = SLICE6AIRBR.IsStreamingProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.TSR_AIR:
|
||||
case HardwareTypes.TSR_AIR_RevB:
|
||||
result = TSRAIR.IsStreamingProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
//All other hardware types can't stream out
|
||||
default:
|
||||
result = false;
|
||||
break;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// returns true if the clock sync profile is supported on the given hardware and protocol version
|
||||
/// </summary>
|
||||
/// <param name="profile">clock sync profile to check</param>
|
||||
/// <param name="dasType">hardware type</param>
|
||||
/// <param name="protocolVersion">protocol version of hardware</param>
|
||||
/// <returns>true if the profile is supported, false otherwise</returns>
|
||||
public static bool IsClockSyncProfileSupported(ClockSyncProfile profile, HardwareTypes dasType,
|
||||
int protocolVersion, bool includeNativeSupportOnly, bool master)
|
||||
{
|
||||
bool result;
|
||||
switch (dasType)
|
||||
{
|
||||
case HardwareTypes.SLICE6_Base:
|
||||
result = SLICE6.IsClockSyncProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE6_AIR:
|
||||
result = SLICE6AIR.IsClockSyncProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE6_AIR_BR:
|
||||
result = SLICE6AIRBR.IsClockSyncProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.SLICE6DB:
|
||||
case HardwareTypes.SLICE6DB_InDummy:
|
||||
result = SLICE6DB.IsClockSyncProfileSupported(profile, protocolVersion);
|
||||
break;
|
||||
case HardwareTypes.TSR_AIR:
|
||||
case HardwareTypes.TSR_AIR_RevB:
|
||||
result = TSRAIR.IsClockSyncProfileSupported(profile, protocolVersion, master);
|
||||
break;
|
||||
//All other hardware types can't sync
|
||||
default:
|
||||
result = false;
|
||||
break;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
||||
18
Common/DTS.CommonCore/Enums/Hardware/SLICEConfigurations.cs
Normal file
18
Common/DTS.CommonCore/Enums/Hardware/SLICEConfigurations.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Hardware
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum SLICEConfigurations
|
||||
{
|
||||
[Description("SLICE_CONFIGURATION_MEGA")]
|
||||
MEGA,
|
||||
[Description("SLICE_CONFIGURATION_800K")]
|
||||
EIGHT_HUNDRED,
|
||||
[Description("SLICE_CONFIGURATION_700K")]
|
||||
SEVEN_HUNDRED,
|
||||
[Description("SLICE_CONFIGURATION_600K")]
|
||||
SIX_HUNDRED
|
||||
}
|
||||
}
|
||||
21
Common/DTS.CommonCore/Enums/ImportFormats.cs
Normal file
21
Common/DTS.CommonCore/Enums/ImportFormats.cs
Normal file
@@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Import.Enums
|
||||
{
|
||||
public enum ImportFormats
|
||||
{
|
||||
NOT_SPECIFIED = 1,
|
||||
DTS_XML = 2,
|
||||
ISF = 3,
|
||||
TSF = 4,
|
||||
DTS_CSV = 5,
|
||||
TTS_XML = 6,
|
||||
CrashDesigner_XML = 7,
|
||||
E2X = 8,
|
||||
TTS_CSV = 9,
|
||||
}
|
||||
}
|
||||
35
Common/DTS.CommonCore/Enums/ImportStatus.cs
Normal file
35
Common/DTS.CommonCore/Enums/ImportStatus.cs
Normal file
@@ -0,0 +1,35 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Import.Enums
|
||||
{
|
||||
public enum ImportExtraStatus
|
||||
{
|
||||
None,
|
||||
NormalizingIds,
|
||||
ReadingCalibrations,
|
||||
ReadingChannels,
|
||||
ReadingCustomerDetails,
|
||||
ReadingEngineerDetails,
|
||||
ReadingGroups,
|
||||
ReadingHardware,
|
||||
ReadingLabDetails,
|
||||
ReadingSensors,
|
||||
ReadingTestSetups,
|
||||
ReadingUsers,
|
||||
ReadingXML
|
||||
}
|
||||
|
||||
public enum PossibleStatus
|
||||
{
|
||||
Waiting,
|
||||
Working,
|
||||
Done,
|
||||
Failed,
|
||||
Reading,
|
||||
Importing
|
||||
}
|
||||
}
|
||||
22
Common/DTS.CommonCore/Enums/IncludeOverwriteName.cs
Normal file
22
Common/DTS.CommonCore/Enums/IncludeOverwriteName.cs
Normal file
@@ -0,0 +1,22 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum IncludeOverwriteName
|
||||
{
|
||||
IncludedCheckBox,
|
||||
OverwriteCheckBox,
|
||||
ImportingTestSetupName
|
||||
}
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum ExportChoices
|
||||
{
|
||||
ExportType,
|
||||
UnfilteredEUCheckBox,
|
||||
FilteredEUCheckBox,
|
||||
MVCheckBox,
|
||||
ADCCheckBox
|
||||
}
|
||||
}
|
||||
13
Common/DTS.CommonCore/Enums/InitializationTypes.cs
Normal file
13
Common/DTS.CommonCore/Enums/InitializationTypes.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum InitializationTypes
|
||||
{
|
||||
Aero,
|
||||
Crash,
|
||||
TSRAIR
|
||||
}
|
||||
}
|
||||
6
Common/DTS.CommonCore/Enums/IsoRestrictionLevels.cs
Normal file
6
Common/DTS.CommonCore/Enums/IsoRestrictionLevels.cs
Normal file
@@ -0,0 +1,6 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
}
|
||||
16
Common/DTS.CommonCore/Enums/IsoSupportLevels.cs
Normal file
16
Common/DTS.CommonCore/Enums/IsoSupportLevels.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum IsoSupportLevels
|
||||
{
|
||||
[Description("ISO 13499")]
|
||||
ISO_ONLY,
|
||||
[Description("User specified channel codes")]
|
||||
TRANSITORY,
|
||||
[Description("No ISO")]
|
||||
NO_ISO
|
||||
}
|
||||
}
|
||||
28
Common/DTS.CommonCore/Enums/IsoViewMode.cs
Normal file
28
Common/DTS.CommonCore/Enums/IsoViewMode.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum IsoViewMode
|
||||
{
|
||||
[Description("ISOOnly")]
|
||||
ISOOnly,
|
||||
[Description("ISOAndUserCode")]
|
||||
ISOAndUserCode,
|
||||
[Description("UserCodeOnly")]
|
||||
UserCodeOnly,
|
||||
[Description("ChannelNameOnly")]
|
||||
ChannelNameOnly
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// provides access to the iso view mode across modules
|
||||
/// note that it doesn't retrieve the value, just holds it,
|
||||
/// the db value must be retrieved and set separately
|
||||
/// </summary>
|
||||
public abstract class IsoViewModeStatic
|
||||
{
|
||||
public static IsoViewMode ViewMode { get; set; }
|
||||
}
|
||||
}
|
||||
13
Common/DTS.CommonCore/Enums/MigrationResult.cs
Normal file
13
Common/DTS.CommonCore/Enums/MigrationResult.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum MigrationResult
|
||||
{
|
||||
OK,
|
||||
ExceptionThrown,
|
||||
WarningAllowStreamingModesWasNotMigrated
|
||||
}
|
||||
}
|
||||
9
Common/DTS.CommonCore/Enums/NetworkSelection.cs
Normal file
9
Common/DTS.CommonCore/Enums/NetworkSelection.cs
Normal file
@@ -0,0 +1,9 @@
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public enum NetworkSelection
|
||||
{
|
||||
Default,
|
||||
NetworkId,
|
||||
NetworkDesc
|
||||
}
|
||||
}
|
||||
26
Common/DTS.CommonCore/Enums/PopupWindowImage.cs
Normal file
26
Common/DTS.CommonCore/Enums/PopupWindowImage.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
/// <summary>
|
||||
/// Specifies constants defining which information to display.
|
||||
/// </summary>
|
||||
public enum PopupWindowImage
|
||||
{
|
||||
// The popup window contains a symbol consisting of an exclamation point in a triangle with a yellow background.
|
||||
Warning = 0,
|
||||
|
||||
// The popup window contains a symbol consisting of white X in a circle with a red background.
|
||||
Error = 1,
|
||||
|
||||
// The popup window contains a symbol consisting of a question mark in a circle.
|
||||
Question = 2,
|
||||
|
||||
// The popup window contains a symbol consisting of a lowercase letter i in a circle.
|
||||
Information = 3
|
||||
}
|
||||
}
|
||||
97
Common/DTS.CommonCore/Enums/RecordingModes.cs
Normal file
97
Common/DTS.CommonCore/Enums/RecordingModes.cs
Normal file
@@ -0,0 +1,97 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Enums.DASFactory;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum RecordingModes
|
||||
{
|
||||
[Description("RecordingModes_CircularBuffer")]
|
||||
CircularBuffer,
|
||||
[Description("RecordingModes_Recorder")]
|
||||
Recorder,
|
||||
[Description("RecordingModes_HybridRecorder")]
|
||||
HybridRecorder,
|
||||
[Description("RecordingModes_S6A_DeviceStreamingOnly")]
|
||||
S6A_DeviceStreamingOnly,
|
||||
[Description("RecordingModes_CircularBufferPlusUART")]
|
||||
CircularBufferPlusUART,
|
||||
[Description("RecordingModes_RecorderPlusUART")]
|
||||
RecorderPlusUART,
|
||||
[Description("RecordingModes_MultipleEventCircularBuffer")]
|
||||
MultipleEventCircularBuffer,
|
||||
[Description("RecordingModes_MultipleEventRecorder")]
|
||||
MultipleEventRecorder,
|
||||
[Description("RecordingModes_ContinuousRecorder")]
|
||||
ContinuousRecorder,
|
||||
[Description("RecordingModes_RecorderAndStreamSubSample")]
|
||||
RecorderAndStreamSubSample,
|
||||
[Description("RecordingModes_CircularBufferAndStreamSubSample")]
|
||||
CircularBufferAndStreamSubSample,
|
||||
[Description("RecordingModes_Active")]
|
||||
Active,
|
||||
[Description("RecordingModes_MultipleEventActive")]
|
||||
MultipleEventActive,
|
||||
[Description("RecordingModes_MultipleEventHybridRecorder")]
|
||||
MultipleEventHybridRecorder,
|
||||
[Description("RecordingModes_Streaming")]
|
||||
Streaming,
|
||||
[Description("RecordingModes_Scheduled")]
|
||||
Scheduled,
|
||||
[Description("RecordingModes_Interval")]
|
||||
Interval,
|
||||
[Description("RecordingModes_MultipleEventCircularBufferPlusUART")]
|
||||
MultipleEventCircularBufferPlusUART,
|
||||
[Description("RecordingModes_MultipleEventRecorderPlusUART")]
|
||||
MultipleEventRecorderPlusUART,
|
||||
[Description("RecordingModes_ContinuousRecorderPlusUART")]
|
||||
ContinuousRecorderPlusUART,
|
||||
[Description("RecordingModes_RAMActive")]
|
||||
RAMActive,
|
||||
[Description("RecordingModes_MultipleEventRAMActive")]
|
||||
MultipleEventRAMActive,
|
||||
[Description("RecordingModes_RecordOnBoot")]
|
||||
RecordOnBoot,
|
||||
[Description("RecordingModes_RecordOnBootPlusUART")]
|
||||
RecordOnBootPlusUART,
|
||||
[Description("RecordingModes_MultipleEventHybridAndStream")]
|
||||
MultipleEventHybridAndStream,
|
||||
[Description("RecordingModes_HybridAndStream")]
|
||||
HybridAndStream,
|
||||
[Description("RecordingModes_MultipleEventCircularBufferAndStream")]
|
||||
MultipleEventCircularBufferAndStream,
|
||||
[Description("RecordingModes_MultipleEventRecorderAndStream")]
|
||||
MultipleEventRecorderAndStream
|
||||
|
||||
}
|
||||
|
||||
// FB15520 Restrict Recording Mode Test Setup Default selections to non-streaming
|
||||
public class NonStreamingRecordingModeItemsSource : RecordingModeItemsSource
|
||||
{
|
||||
public override ItemCollection GetValues()
|
||||
{
|
||||
return FromModes(Constants.NonStreamingRecordingModes);
|
||||
}
|
||||
}
|
||||
|
||||
public abstract class RecordingModeItemsSource : IItemsSource
|
||||
{
|
||||
protected ItemCollection FromModes(RecordingModes[] modes)
|
||||
{
|
||||
var values = new ItemCollection();
|
||||
foreach (var mode in modes)
|
||||
{
|
||||
values.Add(mode, Strings.Strings.ResourceManager.GetString(mode.GetEnumDescription()));
|
||||
}
|
||||
return values;
|
||||
}
|
||||
|
||||
public virtual ItemCollection GetValues()
|
||||
{
|
||||
return FromModes(new RecordingModes[] { });
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Enums.Reports
|
||||
{
|
||||
}
|
||||
24
Common/DTS.CommonCore/Enums/RibbonControlOperation.cs
Normal file
24
Common/DTS.CommonCore/Enums/RibbonControlOperation.cs
Normal file
@@ -0,0 +1,24 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
/// <summary>
|
||||
/// Enum representing the TabControl operations type.
|
||||
/// </summary>
|
||||
public enum RibbonControlOperation
|
||||
{
|
||||
/// <summary>
|
||||
/// The item has been added to the TabControl.
|
||||
/// </summary>
|
||||
AddedItem,
|
||||
|
||||
/// <summary>
|
||||
/// The item has been removed from the TabControl.
|
||||
/// </summary>
|
||||
RemovedItem
|
||||
}
|
||||
}
|
||||
15
Common/DTS.CommonCore/Enums/RibbonTabNames.cs
Normal file
15
Common/DTS.CommonCore/Enums/RibbonTabNames.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
public static class RibbonTabNames
|
||||
{
|
||||
public const string Tab1 = "TBD";
|
||||
public const string Tab2 = "TBD";
|
||||
public const string Tab3 = "TBD";
|
||||
}
|
||||
}
|
||||
262
Common/DTS.CommonCore/Enums/RunTestVariables.cs
Normal file
262
Common/DTS.CommonCore/Enums/RunTestVariables.cs
Normal file
@@ -0,0 +1,262 @@
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
/// <summary>
|
||||
/// different variables to optimize or change the behavior of das factory based on whether a test
|
||||
/// is currently executing or not
|
||||
/// </summary>
|
||||
public abstract class RunTestVariables
|
||||
{
|
||||
/// <summary>
|
||||
/// whether to show ADC unsigned or not
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool ShowADCUnsigned { get; set; } = false;
|
||||
/// <summary>
|
||||
/// The realtime sample rate for TDAS
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static double RealtimeSampleRateTDAS { get; set; } = 1000;
|
||||
/// <summary>
|
||||
/// The default udp stream time channel id
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int DefaultUDPStreamTimeChannelId { get; set; } = 1;
|
||||
/// <summary>
|
||||
/// the default udp stream data channel id
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int DefaultUDPStreamDataChannelId { get; set; } = 3;
|
||||
/// <summary>
|
||||
/// the default irig time data packet interval in ms
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int DefaultIRIGTimeDataPacketIntervalMs { get; set; } = 1000;
|
||||
/// <summary>
|
||||
/// the default udp stream tmns config property as a string
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static string DefaultUDPStreamTmNSConfig { get; set; } = "";
|
||||
/// <summary>
|
||||
/// The ISO view mode
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static IsoViewMode ISOViewMode { get; set; } = IsoViewMode.ISOOnly;
|
||||
/// <summary>
|
||||
/// the realtime level trigger percentage
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static double RealtimeLevelTriggerPercentage { get; set; } = 100;
|
||||
/// <summary>
|
||||
/// the realtime level trigger beep interval in ms
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int RealtimeLevelTriggerBeepIntervalMS { get; set; } = 10;
|
||||
/// <summary>
|
||||
/// the realtime level trigger beep count
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int RealtimeLevelTriggerBeepCount { get; set; } = 10;
|
||||
/// <summary>
|
||||
/// whether to auto advance in realtime level trigger
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool RealtimeLevelTriggerAutoAdvance { get; set; } = false;
|
||||
/// <summary>
|
||||
/// how long to freeze after a level trigger in realtime in seconds
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int RealtimeLevelTriggerFreezeTimeSec { get; set; } = 3;
|
||||
/// <summary>
|
||||
/// whether to require completion of realtime level trigger checks or not
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool RealtimeLevelTriggerRequireCheckCompletion { get; set; } = false;
|
||||
/// <summary>
|
||||
/// realtime level trigger qualifying number of samples for a level trigger
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int RealtimeLevelTriggerQualifyingSamples { get; set; } = 5;
|
||||
/// <summary>
|
||||
/// whether to beep in realtime level trigger while idle
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool RealtimeLevelTriggerIdleBeep { get; set; } = false;
|
||||
/// <summary>
|
||||
/// realtime level trigger idle beep interval in ms
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int RealtimeLevelTriggerIdleBeepIntervalMS { get; set; } = 1000;
|
||||
/// <summary>
|
||||
/// whether to use realtime in metermode table mode
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool UseMeterModeTable { get; set; } = false;
|
||||
/// <summary>
|
||||
/// whether to save realtime snapshots to clipboard or not
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool SaveSnapshotToClipboard { get; set; } = false;
|
||||
/// <summary>
|
||||
/// the default UDP stream address
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static string RealtimeUDPStreamAddress { get; set; } = "";
|
||||
/// <summary>
|
||||
/// whether to use UDP for realtime streaming
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool UseUDPStreaming { get; set; } = false;
|
||||
/// <summary>
|
||||
/// the number of realtime charts to show
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static int NumberOfRealtimeCharts { get; set; } = 6;
|
||||
/// <summary>
|
||||
/// realtime sample rate for SLICE6
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static double RealtimeSampleRateSLICE6 { get; set; } = 1000;
|
||||
/// <summary>
|
||||
/// realtime sample rate
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static double RealtimeSampleRate { get; set; } = 1000;
|
||||
/// <summary>
|
||||
/// realtime sample rate for USB SLICE
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static double RealtimeSampleRateUSBSLICE { get; set; } = 1000;
|
||||
public static double RealtimeSampleRateEthSLICE { get; set; } = 120;
|
||||
/// <summary>
|
||||
/// default realtime chart width in seconds
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static double ChartWidthInSeconds { get; set; } = 2;
|
||||
/// <summary>
|
||||
/// whether to enable dynamic realtime optimization
|
||||
/// This is just a property to hold the value during run test
|
||||
/// http://manuscript.dts.local/f/cases/33110/Eliminate-DB-communication-while-in-realtime
|
||||
/// </summary>
|
||||
public static bool EnableDynamicRealtimeOptimization { get; set; } = false;
|
||||
/// <summary>
|
||||
/// the number of ADC samples per data packet
|
||||
/// http://manuscript.dts.local/f/cases/31754/
|
||||
/// </summary>
|
||||
public static int ADCSamplesPerPacket { get; set; } = 100;
|
||||
/// <summary>
|
||||
/// whether to remove leap seconds from streaming timestamps
|
||||
/// note that this property does not retrieve the setting from the database, and only holds the value
|
||||
/// between operations, it must be updated separately
|
||||
/// </summary>
|
||||
public static bool RemoveLeapSeconds { get; set; } = false;
|
||||
/// <summary>
|
||||
/// whether to output reports in XLSM format or XLSX
|
||||
/// 20152 DataPRO Test Summary Preview - .xlsm support
|
||||
/// note that Test Summary is the only one requested so far, so that's the only one we do
|
||||
/// </summary>
|
||||
public static bool OutputXLSMReports { get; set; } = false;
|
||||
/// <summary>
|
||||
/// controls whether to mask EU meta data when streaming
|
||||
/// 25597 Add option in System Settings to populate TMATs without offset values or scalefactors; "Stream without EU Metadata in TMATs"
|
||||
/// does not query setting, only holds the setting in memory for use
|
||||
/// across modules
|
||||
/// </summary>
|
||||
public static bool MaskEUMetaData { get; set; } = false;
|
||||
/// <summary>
|
||||
/// the protocol version S6 are assumed to be when running a test (protocol version not queried)
|
||||
/// </summary>
|
||||
public static byte AssumedProtocolVersionForSlice6InRunTest { get; set; } = 0;
|
||||
/// <summary>
|
||||
/// whether to query cal date when running a test
|
||||
/// </summary>
|
||||
public static bool QueryCalDateInRunTest { get; set; } = false;
|
||||
/// <summary>
|
||||
/// whether currently running a test or not
|
||||
/// </summary>
|
||||
public static bool InRunTest { get; set; } = false;
|
||||
/// <summary>
|
||||
/// whether to query connected devices when running a test or not
|
||||
/// </summary>
|
||||
public static bool QueryConnectedDevicesInRunTest { get; set; } = false;
|
||||
/// <summary>
|
||||
/// the minimum time between different ATDs when connecting
|
||||
/// </summary>
|
||||
public static int PerBucketOffsetMS { get; set; } = 2000;
|
||||
/// <summary>
|
||||
/// the maximum time variance within the bucket itself for an ATD (so 2000, 1000 means all units in ATD2 should have their chance to start between 2 and 3s)
|
||||
/// </summary>
|
||||
public static int BucketVariance { get; set; } = 1000;
|
||||
/// <summary>
|
||||
/// performance improvement possibility, skip QueryProtocolVersion in RunTest and just
|
||||
/// assume the protocol version of devices
|
||||
/// a value of -1 means the version will still be queried
|
||||
/// </summary>
|
||||
public static byte Assumed_S6DB_ProtocolVersion = 13;
|
||||
/// <summary>
|
||||
/// performance improvement, skip QueryBaseHardwareRevision and use this assumed value in RunTest
|
||||
/// a value of -1 means it will be queried anyhow
|
||||
/// </summary>
|
||||
public static int AssumedBaseHardwareRevisionSLICE6 = 0;
|
||||
/// <summary>
|
||||
/// performance improvement, skip QueryBaseType in RunTest for S6 and just use this value as the
|
||||
/// assumed base type, a value of -1 means it will be queried anyhow
|
||||
/// </summary>
|
||||
public static int AssumeBaseTypeSLICE6 = 6;
|
||||
/// <summary>
|
||||
/// performance improvement, skip QueryEventData in run test or not
|
||||
/// </summary>
|
||||
public static bool OptimizeQueryEventData = true;
|
||||
/// <summary>
|
||||
/// performance improvement, skip setting polarity in run test
|
||||
/// </summary>
|
||||
public static bool DontSetPolarityInRunTest = false;
|
||||
/// <summary>
|
||||
/// performance improvement, whether to cache voltage settings in runtest
|
||||
/// rather than always retrieving from db
|
||||
/// </summary>
|
||||
public static bool CacheVoltageSettingsInRunTest = true;
|
||||
/// <summary>
|
||||
/// performance improvment, skip getting TiltSensorScaleFactor from S6
|
||||
/// as they aren't currently calibrated and use the same scalefactor
|
||||
/// </summary>
|
||||
public static float TiltSensorScaleFactor = 0.0009765625F;
|
||||
/// <summary>
|
||||
/// performance improvment, whether to check for autoarmed in runtest or not
|
||||
/// </summary>
|
||||
public static bool CheckForAutoArmedInRunTest = true;
|
||||
/// <summary>
|
||||
/// performance, whether to avoid executing PrepareDataCollection when arming
|
||||
/// [per LP since arming does same work]
|
||||
/// </summary>
|
||||
public static bool EliminatePrepareForDataCollection = true;
|
||||
/// <summary>
|
||||
/// performance improvement, whether to check hardware first use date in run test
|
||||
/// </summary>
|
||||
public static bool CheckHardwareFirstUseDateInRunTest = true;
|
||||
}
|
||||
}
|
||||
13
Common/DTS.CommonCore/Enums/SLICE6MulticastProperties.cs
Normal file
13
Common/DTS.CommonCore/Enums/SLICE6MulticastProperties.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
/// <summary>
|
||||
/// properties for SLICE6 multicast
|
||||
/// this is the UDP broadcast SLICE6 uses for autodiscovery
|
||||
/// </summary>
|
||||
public enum SLICE6Properties
|
||||
{
|
||||
SLICE6MulticastAddress,
|
||||
SLICE6MulticastCommandPort,
|
||||
SLICE6MulticastResponsePort
|
||||
}
|
||||
}
|
||||
12
Common/DTS.CommonCore/Enums/ScriptTypes.cs
Normal file
12
Common/DTS.CommonCore/Enums/ScriptTypes.cs
Normal file
@@ -0,0 +1,12 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum ScriptTypes
|
||||
{
|
||||
Migration,
|
||||
Initialization
|
||||
}
|
||||
}
|
||||
545
Common/DTS.CommonCore/Enums/Sensors/CSVImportTags.cs
Normal file
545
Common/DTS.CommonCore/Enums/Sensors/CSVImportTags.cs
Normal file
@@ -0,0 +1,545 @@
|
||||
using DTS.Common.Attributes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.Linq;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
/// <summary>
|
||||
/// holds information for all CSV import/export fields and their versions
|
||||
/// </summary>
|
||||
public abstract class CSVImportTags
|
||||
{
|
||||
public const int MIN_VALID_VERSION = 0;
|
||||
public const int MAX_VALID_VERSION = 6;
|
||||
private static readonly object MY_LOCK = new object();
|
||||
private static HashSet<int> _SensorTagsVersions = new HashSet<int>()
|
||||
{
|
||||
0, 2, 3, 4
|
||||
};
|
||||
public static bool IsSensorTag(int version)
|
||||
{
|
||||
return _SensorTagsVersions.Contains(version);
|
||||
}
|
||||
private static string TagToDisplayString(Tags tag)
|
||||
{
|
||||
var enumType = tag.GetType();
|
||||
var name = Enum.GetName(enumType, tag);
|
||||
if (string.IsNullOrEmpty(name)) { return string.Empty; }
|
||||
var fieldInfo = enumType.GetField(name);
|
||||
if (null == fieldInfo || 0 == fieldInfo.CustomAttributes.Count()) { return string.Empty; }
|
||||
var attributes = fieldInfo.GetCustomAttributes(false).OfType<DisplayAttribute>();
|
||||
if (null == attributes || !attributes.Any()) { return string.Empty; }
|
||||
return attributes.FirstOrDefault().Name;
|
||||
}
|
||||
private static int TagToVersion(Tags tag)
|
||||
{
|
||||
var enumType = tag.GetType();
|
||||
var name = Enum.GetName(enumType, tag);
|
||||
if (string.IsNullOrEmpty(name)) { return int.MaxValue; }
|
||||
var fieldInfo = enumType.GetField(name);
|
||||
if (null == fieldInfo || 0 == fieldInfo.CustomAttributes.Count()) { return int.MaxValue; }
|
||||
var attributes = fieldInfo.GetCustomAttributes(false).OfType<VersionAttribute>();
|
||||
if (null == attributes || !attributes.Any()) { return int.MaxValue; }
|
||||
return attributes.FirstOrDefault().Version;
|
||||
}
|
||||
/// <summary>
|
||||
/// gets all tags for a given version of import
|
||||
/// </summary>
|
||||
/// <param name="version"></param>
|
||||
/// <returns></returns>
|
||||
public static Tags [] GetVersionTags(int version)
|
||||
{
|
||||
lock (MY_LOCK)
|
||||
{
|
||||
if (null == _versionToTags) { PopulateLookups(); }
|
||||
return _versionToTags.ContainsKey(version) ? _versionToTags[version].ToArray() : new Tags[0];
|
||||
}
|
||||
}
|
||||
private static Dictionary<string, Tags> _stringToTag = null;
|
||||
private static Dictionary<Tags, string> _tagToString = null;
|
||||
private static Dictionary<int, List<Tags>> _versionToTags = null;
|
||||
private static Dictionary<Tags, int> _tagToVersion = null;
|
||||
/// <summary>
|
||||
/// gets a display string given a tag
|
||||
/// </summary>
|
||||
/// <param name="tag"></param>
|
||||
/// <returns></returns>
|
||||
public static string GetStringForTag(Tags tag)
|
||||
{
|
||||
lock (MY_LOCK)
|
||||
{
|
||||
if (null == _tagToString) { PopulateLookups(); }
|
||||
return _tagToString.ContainsKey(tag) ? _tagToString[tag] : string.Empty;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// returns a tag given a display string
|
||||
/// </summary>
|
||||
/// <param name="s"></param>
|
||||
/// <returns></returns>
|
||||
public static Tags GetTagForString(string s)
|
||||
{
|
||||
lock (MY_LOCK)
|
||||
{
|
||||
if (null == _stringToTag) { PopulateLookups(); }
|
||||
return _stringToTag.ContainsKey(s) ? _stringToTag[s] : Tags.Unknown;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// returns a version the tag was used in given a tag
|
||||
/// </summary>
|
||||
/// <param name="t"></param>
|
||||
/// <returns></returns>
|
||||
public static int GetVersionForTag(Tags t)
|
||||
{
|
||||
lock (MY_LOCK)
|
||||
{
|
||||
if (null == _tagToVersion) { PopulateLookups(); }
|
||||
return _tagToVersion.ContainsKey(t) ? _tagToVersion[t] : int.MaxValue;
|
||||
}
|
||||
}
|
||||
|
||||
private static void PopulateLookups()
|
||||
{
|
||||
var lookup1 = new Dictionary<string, Tags>();
|
||||
var lookup2 = new Dictionary<Tags, string>();
|
||||
var lookup3 = new Dictionary<int, List<Tags>>();
|
||||
var lookup4 = new Dictionary<Tags, int>();
|
||||
|
||||
var allTags = Enum.GetValues(typeof(Tags)).Cast<Tags>().ToArray();
|
||||
foreach (var tag in allTags)
|
||||
{
|
||||
var s = TagToDisplayString(tag);
|
||||
var version = TagToVersion(tag);
|
||||
lookup1[s] = tag;
|
||||
lookup2[tag] = s;
|
||||
if(!lookup3.ContainsKey(version))
|
||||
{
|
||||
lookup3.Add(version, new List<Tags>());
|
||||
}
|
||||
lookup3[version].Add(tag);
|
||||
lookup4[tag] = version;
|
||||
}
|
||||
lock (MY_LOCK)
|
||||
{
|
||||
_stringToTag = lookup1;
|
||||
_tagToString = lookup2;
|
||||
_versionToTags = lookup3;
|
||||
_tagToVersion = lookup4;
|
||||
}
|
||||
}
|
||||
public enum Tags
|
||||
{
|
||||
[Display(Name = "Database Reference Number")]
|
||||
[Version(0)]
|
||||
DatabaseReferenceNumber,
|
||||
[Display(Name = "Sensor SN")]
|
||||
[Version(0)]
|
||||
SensorSN,
|
||||
[Display(Name = "Channel Name")]
|
||||
[Version(0)]
|
||||
ChannelName,
|
||||
[Display(Name = "Location")]
|
||||
[Version(0)]
|
||||
Location,
|
||||
[Display(Name = "Laboratory Code")]
|
||||
[Version(0)]
|
||||
LaboratoryCode,
|
||||
[Display(Name = "Customer Code")]
|
||||
[Version(0)]
|
||||
CustomerCode,
|
||||
[Display(Name = "Partial ISO Code")]
|
||||
[Version(0)]
|
||||
PartialISOCode,
|
||||
[Display(Name = "Comment Field")]
|
||||
[Version(0)]
|
||||
CommentField,
|
||||
[Display(Name = "Sensor Type")]
|
||||
[Version(0)]
|
||||
SensorType,
|
||||
[Display(Name = "Manufacturer")]
|
||||
[Version(0)]
|
||||
Manufacturer,
|
||||
[Display(Name = "Model")]
|
||||
[Version(0)]
|
||||
Model,
|
||||
[Display(Name = "Axis (X, Y, Z)")]
|
||||
[Version(0)]
|
||||
Axis,
|
||||
[Display(Name = "Dimension")]
|
||||
[Version(0)]
|
||||
Dimension,
|
||||
[Display(Name = "EU")]
|
||||
[Version(0)]
|
||||
EU,
|
||||
[Display(Name = "Full Scale (EU)")]
|
||||
[Version(0)]
|
||||
FullScale,
|
||||
[Display(Name = "Exc (VDC)")]
|
||||
[Version(0)]
|
||||
Exc,
|
||||
[Display(Name = "Output @ EXC & FS (mV)")]
|
||||
[Version(0)]
|
||||
OutputAtEXCFSmV,
|
||||
[Display(Name = "Sensitivity (mV/V/EU)")]
|
||||
[Version(0)]
|
||||
Sensitivity,
|
||||
[Display(Name = "Output Proportional to EXC? (Yes, No)")]
|
||||
[Version(0)]
|
||||
Proportional,
|
||||
[Display(Name = "Desired Range (EU)")]
|
||||
[Version(0)]
|
||||
DesiredRange,
|
||||
[Display(Name = "BRIDGE (Full, Half)")]
|
||||
[Version(0)]
|
||||
BRIDGE,
|
||||
[Display(Name = "Use Shunt Cal? (Yes, No)")]
|
||||
[Version(0)]
|
||||
UseShuntCal,
|
||||
[Display(Name = "Bridge Res. (Ohm)")]
|
||||
[Version(0)]
|
||||
BridgeResistance,
|
||||
[Display(Name = "Shunt Resistor Value (Ohms)")]
|
||||
[Version(0)]
|
||||
ShuntResistorValue,
|
||||
[Display(Name = "Equivalent EU for Shunt Resistor")]
|
||||
[Version(0)]
|
||||
EquivalentEUShuntResistor,
|
||||
[Display(Name = "Bypass AA Filter? (Yes, No)")]
|
||||
[Version(0)]
|
||||
BypassAAFilter,
|
||||
[Display(Name = "Invert Signal? (Yes, No)")]
|
||||
[Version(0)]
|
||||
InvertSignal,
|
||||
[Display(Name = "Remove Sensor Offset? (Yes, No)")]
|
||||
[Version(0)]
|
||||
RemoveOffset,
|
||||
[Display(Name = "Sensor Offset Low (mV)")]
|
||||
[Version(0)]
|
||||
OffsetToleranceLow,
|
||||
[Display(Name = "Sensor Offset High (mV)")]
|
||||
[Version(0)]
|
||||
OffsetToleranceHigh,
|
||||
[Display(Name = "SAE Filter Class")]
|
||||
[Version(0)]
|
||||
FilterClass,
|
||||
[Display(Name = "Software Zero Reference (Pre, Avg, 0mV)")]
|
||||
[Version(0)]
|
||||
SoftwareZeroReference,
|
||||
[Display(Name = "Software Zero Equivalent EU")]
|
||||
[Version(0)]
|
||||
SoftwareZeroEquivalentEU,
|
||||
[Display(Name = "16 Byte Dallas Sensor ID")]
|
||||
[Version(0)]
|
||||
SensorID,
|
||||
[Display(Name = "Received")]
|
||||
[Version(0)]
|
||||
Received,
|
||||
[Display(Name = "Last Cal")]
|
||||
[Version(0)]
|
||||
LastCal,
|
||||
[Display(Name = "Due Cal")]
|
||||
[Version(0)]
|
||||
DueCal,
|
||||
[Display(Name = "Due")]
|
||||
[Version(0)]
|
||||
Due,
|
||||
[Display(Name = "Tech")]
|
||||
[Version(0)]
|
||||
Tech,
|
||||
[Display(Name = "Group 1")]
|
||||
[Version(0)]
|
||||
Group1,
|
||||
[Display(Name = "Group 2")]
|
||||
[Version(0)]
|
||||
Group2,
|
||||
[Display(Name = "Group 3")]
|
||||
[Version(0)]
|
||||
Group3,
|
||||
[Display(Name = "Group 4")]
|
||||
[Version(0)]
|
||||
Group4,
|
||||
[Display(Name = "Group 5")]
|
||||
[Version(0)]
|
||||
Group5,
|
||||
[Display(Name = "Category")]
|
||||
[Version(0)]
|
||||
Category,
|
||||
[Display(Name = "IRTRACC Exponent")]
|
||||
[Version(0)]
|
||||
IRTRACCExponent,
|
||||
[Display(Name = "unknown")]
|
||||
[Version(0)]
|
||||
Unknown,
|
||||
[Display(Name = "Version")]
|
||||
[Version(1)]
|
||||
Version,
|
||||
[Display(Name = "Test Setup Name")]
|
||||
[Version(1)]
|
||||
TestSetupName,
|
||||
[Display(Name = "Test Setup Description")]
|
||||
[Version(1)]
|
||||
TestSetupDescription,
|
||||
[Display(Name = "Recording Mode")]
|
||||
[Version(1)]
|
||||
RecordingMode,
|
||||
[Display(Name = "SampleRate")]
|
||||
[Version(1)]
|
||||
SampleRate,
|
||||
[Display(Name = "PreTriggerSec")]
|
||||
[Version(1)]
|
||||
PreTriggerSec,
|
||||
[Display(Name = "PostTriggerSec")]
|
||||
[Version(1)]
|
||||
PostTriggerSec,
|
||||
[Display(Name = "Tags")]
|
||||
[Version(1)]
|
||||
Tags,
|
||||
[Display(Name = "Two Volt Exc.")]
|
||||
[Version(2)]
|
||||
TwoVoltExcSensitivity,
|
||||
[Display(Name = "Five Volt Exc.")]
|
||||
[Version(2)]
|
||||
FiveVoltExcSensitivity,
|
||||
[Display(Name = "Ten Volt Exc.")]
|
||||
[Version(2)]
|
||||
TenVoltExcSensitivity,
|
||||
[Display(Name = "Range Low")]
|
||||
[Version(2)]
|
||||
RangeLow,
|
||||
[Display(Name = "Range Medium")]
|
||||
[Version(2)]
|
||||
RangeMedium,
|
||||
[Display(Name = "Range High")]
|
||||
[Version(2)]
|
||||
RangeHigh,
|
||||
[Display(Name = "Supported Excitation")]
|
||||
[Version(2)]
|
||||
SupportedExcitation,
|
||||
[Display(Name = "Bridge Type")]
|
||||
[Version(2)]
|
||||
BridgeType,
|
||||
[Display(Name = "Unipolar")]
|
||||
[Version(2)]
|
||||
Unipolar,
|
||||
[Display(Name = "Axis Number")]
|
||||
[Version(2)]
|
||||
AxisNumber,
|
||||
[Display(Name = "Number of Axes")]
|
||||
[Version(2)]
|
||||
NumberOfAxes,
|
||||
[Display(Name = "Cal Interval")]
|
||||
[Version(2)]
|
||||
CalInterval,
|
||||
[Display(Name = "Polarity")]
|
||||
[Version(2)]
|
||||
Polarity,
|
||||
[Display(Name = "Physical Dimension")]
|
||||
[Version(2)]
|
||||
PhysicalDimension,
|
||||
[Display(Name = "Direction")]
|
||||
[Version(2)]
|
||||
Direction,
|
||||
[Display(Name = "InitialOffset")]
|
||||
[Version(2)]
|
||||
InitialOffset,
|
||||
[Display(Name = "NonLinear")]
|
||||
[Version(2)]
|
||||
NonLinear,
|
||||
[Display(Name = "Software Zero Method")]
|
||||
[Version(2)]
|
||||
ZeroMethod,
|
||||
[Display(Name = "Zero Averaging Window Start")]
|
||||
[Version(2)]
|
||||
ZeroMethodStart,
|
||||
[Display(Name = "Zero Averaging Window End")]
|
||||
[Version(2)]
|
||||
ZeroMethodEnd,
|
||||
[Display(Name = "Bridge Leg Mode")]
|
||||
[Version(2)]
|
||||
BridgeLegMode,
|
||||
[Display(Name = "Created")]
|
||||
[Version(2)]
|
||||
Created,
|
||||
[Display(Name = "Times Used")]
|
||||
[Version(2)]
|
||||
TimesUsed,
|
||||
[Display(Name = "IEPE Coupling Mode")]
|
||||
[Version(2)]
|
||||
CouplingMode,
|
||||
[Display(Name = "DelayMS")]
|
||||
[Version(2)]
|
||||
DelayMS,
|
||||
[Display(Name = "DigitalOutputDelayMS")]
|
||||
[Version(2)]
|
||||
DigitalOutputDelayMS,
|
||||
[Display(Name = "DurationMS")]
|
||||
[Version(2)]
|
||||
DurationMS,
|
||||
[Display(Name = "DigitalOutputDurationMS")]
|
||||
[Version(2)]
|
||||
DigitalOutputDurationMS,
|
||||
[Display(Name = "Digital Output Mode")]
|
||||
[Version(2)]
|
||||
DigitalOutputMode,
|
||||
[Display(Name = "LimitDuration")]
|
||||
[Version(2)]
|
||||
LimitDuration,
|
||||
[Display(Name = "Squib Fire Mode")]
|
||||
[Version(2)]
|
||||
SquibFireMode,
|
||||
[Display(Name = "Squib Measurement Type")]
|
||||
[Version(2)]
|
||||
SquibMeasurementType,
|
||||
[Display(Name = "Squib Output Current")]
|
||||
[Version(2)]
|
||||
SquibOutputCurrent,
|
||||
[Display(Name = "Digital Scale Multiplier")]
|
||||
[Version(2)]
|
||||
DigitalScaleMultiplier,
|
||||
[Display(Name = "Digital Input Mode")]
|
||||
[Version(2)]
|
||||
DigitalInputMode,
|
||||
[Display(Name = "NonLinear Cal")]
|
||||
[Version(2)]
|
||||
NonLinearCalibration,
|
||||
[Display(Name = "DisplayUnits")]
|
||||
[Version(2)]
|
||||
DisplayUnits,
|
||||
[Display(Name = "At Capacity")]
|
||||
[Version(2)]
|
||||
AtCapacity,
|
||||
[Display(Name = "Capacity Ouptut Is Based On")]
|
||||
[Version(2)]
|
||||
CapacityOutputIsBasedOn,
|
||||
[Display(Name = "Sensitivity Units")]
|
||||
[Version(2)]
|
||||
SensitivityUnits,
|
||||
[Display(Name = "CheckOffset")]
|
||||
[Version(2)]
|
||||
CheckOffset,
|
||||
[Display(Name = "Broken")]
|
||||
[Version(2)]
|
||||
Broken,
|
||||
[Display(Name = "Do Not Use")]
|
||||
[Version(2)]
|
||||
DoNotUse,
|
||||
[Display(Name = "ISOChannelName")]
|
||||
[Version(2)]
|
||||
ISOChannelName,
|
||||
[Display(Name = "UserCode")]
|
||||
[Version(2)]
|
||||
UserCode,
|
||||
[Display(Name = "UserChannelName")]
|
||||
[Version(2)]
|
||||
UserChannelName,
|
||||
[Display(Name = "Addl Linear Sensitivity")]
|
||||
[Version(2)]
|
||||
AdditionalLinearSensitivity,
|
||||
[Display(Name = "Addl Linear Zero Method")]
|
||||
[Version(2)]
|
||||
AdditionalLinearZeroMethod,
|
||||
[Display(Name = "Addl Linear Zero Method Start")]
|
||||
[Version(2)]
|
||||
AdditionalLinearZeroMethodStart,
|
||||
[Display(Name = "Addl Linear Zero Method End")]
|
||||
[Version(2)]
|
||||
AdditionalLinearZeroMethodEnd,
|
||||
[Display(Name = "Addl Initial Offsets")]
|
||||
[Version(2)]
|
||||
AdditionalInitialOffsets,
|
||||
[Display(Name = "Group Name")]
|
||||
[Version(3)]
|
||||
GroupName,
|
||||
[Display(Name = "Group Type")]
|
||||
[Version(3)]
|
||||
GroupType,
|
||||
[Display(Name = "DAS serial number")]
|
||||
[Version(4)]
|
||||
DASSerialNumber,
|
||||
[Display(Name = "DAS channel index")]
|
||||
[Version(4)]
|
||||
DASChannelIndex,
|
||||
[Display(Name = "Stream profile")]
|
||||
[Version(4)]
|
||||
StreamProfile,
|
||||
[Display(Name = "UDP address")]
|
||||
[Version(4)]
|
||||
UDPAddress,
|
||||
[Display(Name = "Time channel Id")]
|
||||
[Version(4)]
|
||||
TimeChannelId,
|
||||
[Display(Name = "Data channel Id")]
|
||||
[Version(4)]
|
||||
DataChannelId,
|
||||
[Display(Name = "Stream output configuration")]
|
||||
[Version(4)]
|
||||
TmNSConfig,
|
||||
[Display(Name = "IRIG time packet interval ms")]
|
||||
[Version(4)]
|
||||
IRIGTimeDataPacketIntervalMS,
|
||||
[Display(Name = "TMATS packet interval ms")]
|
||||
[Version(4)]
|
||||
TMATSIntervalMS,
|
||||
[Display(Name = "Baud rate")]
|
||||
[Version(4)]
|
||||
BaudRate,
|
||||
[Display(Name = "Data bits")]
|
||||
[Version(4)]
|
||||
DataBits,
|
||||
[Display(Name = "Stop bits")]
|
||||
[Version(4)]
|
||||
StopBits,
|
||||
[Display(Name = "Parity")]
|
||||
[Version(4)]
|
||||
Parity,
|
||||
[Display(Name = "Data format")]
|
||||
[Version(4)]
|
||||
DataFormat,
|
||||
[Display(Name = "Test user code")]
|
||||
[Version(4)]
|
||||
TestUserCode,
|
||||
[Display(Name = "Test user channel name")]
|
||||
[Version(4)]
|
||||
TestUserChannelName,
|
||||
[Display(Name = "Test isocode")]
|
||||
[Version(4)]
|
||||
TestIsoCode,
|
||||
[Display(Name = "Test iso channel name")]
|
||||
[Version(4)]
|
||||
TestIsoChannelName,
|
||||
[Display(Name = "Clock master input type")]
|
||||
[Version(5)]
|
||||
ClockMasterInputType,
|
||||
[Display(Name = "Clock master output type")]
|
||||
[Version(5)]
|
||||
ClockMasterOutputType,
|
||||
[Display(Name = "Manage master clocks outside of DP")]
|
||||
[Version(5)]
|
||||
ManageClocksOutsideDPMaster,
|
||||
[Display(Name = "Manage slave clocks outside of DP")]
|
||||
[Version(5)]
|
||||
ManageClocksOutsideDPSlave,
|
||||
[Display(Name = "Clock slave input type")]
|
||||
[Version(5)]
|
||||
ClockSlaveInputType,
|
||||
[Display(Name = "Clock slave output type")]
|
||||
[Version(5)]
|
||||
ClockSlaveOutputType,
|
||||
[Display(Name = "DAS serial")]
|
||||
[Version(6)]
|
||||
DASSerial,
|
||||
[Display(Name = "DAS sample rate")]
|
||||
[Version(6)]
|
||||
DASSampleRate,
|
||||
[Display(Name = "PTP domain id")]
|
||||
[Version(6)]
|
||||
PTPDomainId,
|
||||
[Display(Name = "Clock master")]
|
||||
[Version(6)]
|
||||
ClockMaster
|
||||
}
|
||||
}
|
||||
}
|
||||
17
Common/DTS.CommonCore/Enums/Sensors/CalibrationBehaviors.cs
Normal file
17
Common/DTS.CommonCore/Enums/Sensors/CalibrationBehaviors.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum CalibrationBehaviors
|
||||
{
|
||||
[Description("CalibrationBehaviors_LinearIfAvailable")]
|
||||
LinearIfAvailable,
|
||||
[Description("CalibrationBehaviors_NonLinearIfAvailable")]
|
||||
NonLinearIfAvailable,
|
||||
[Description("CalibrationBehaviors_UseBothIfAvailable")]
|
||||
UseBothIfAvailable
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum CalibrationEnforcement
|
||||
{
|
||||
[Description("CalibrationEnforcement_None")]
|
||||
None,
|
||||
[Description("CalibrationEnforcement_NonLinear")]
|
||||
NonLinear,
|
||||
[Description("CalibrationEnforcement_Linear")]
|
||||
Linear
|
||||
}
|
||||
}
|
||||
25
Common/DTS.CommonCore/Enums/Sensors/FilterClassType.cs
Normal file
25
Common/DTS.CommonCore/Enums/Sensors/FilterClassType.cs
Normal file
@@ -0,0 +1,25 @@
|
||||
using DTS.Common.Base.Classes;
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum FilterClassType
|
||||
{
|
||||
[DescriptionResource("FilterClassType_None")]
|
||||
None = 0, //Code = P unless UseZeroForUnfiltered is True, then Code = 0
|
||||
AdHoc = -1,
|
||||
[DescriptionResource("FilterClassType_Unfiltered")]
|
||||
Unfiltered = -2, // Code = 0
|
||||
CFC10 = 17, // 17 Hz
|
||||
[DescriptionResource("FilterClassType_CFC60")]
|
||||
CFC60 = 100, // 100 Hz; Code = D
|
||||
[DescriptionResource("FilterClassType_CFC180")]
|
||||
CFC180 = 300, // 300 Hz; Code = C
|
||||
[DescriptionResource("FilterClassType_CFC600")]
|
||||
CFC600 = 1000, // 1000 Hz; Code = B
|
||||
[DescriptionResource("FilterClassType_CFC1000")]
|
||||
CFC1000 = 1650 // 1650 Hz; Code = A
|
||||
}
|
||||
}
|
||||
25
Common/DTS.CommonCore/Enums/Sensors/InitialOffsetTypes.cs
Normal file
25
Common/DTS.CommonCore/Enums/Sensors/InitialOffsetTypes.cs
Normal file
@@ -0,0 +1,25 @@
|
||||
using DTS.Common.Converters;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
/// <summary>
|
||||
/// the format Initial Offset is in
|
||||
/// </summary>
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum InitialOffsetTypes
|
||||
{
|
||||
[Description("InitialOffsetType_None")]
|
||||
None = 0,
|
||||
[Description("InitialOffsetType_EU")]
|
||||
EU = 1,
|
||||
[Description("InitialOffsetType_EUAtMV")]
|
||||
EUAtMV = 2,
|
||||
[Description("InitialOffsetType_LHS")]
|
||||
LHS = 3,
|
||||
[Description("InitialOffsetType_RHS")]
|
||||
RHS = 4,
|
||||
[Description("InitialOffsetType_FRONTAL")]
|
||||
FRONTAL=5
|
||||
}
|
||||
}
|
||||
20
Common/DTS.CommonCore/Enums/Sensors/LinearizationFormula.cs
Normal file
20
Common/DTS.CommonCore/Enums/Sensors/LinearizationFormula.cs
Normal file
@@ -0,0 +1,20 @@
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
public enum NonLinearStyles
|
||||
{
|
||||
IRTraccManual,
|
||||
IRTraccDiagnosticsZero,
|
||||
IRTraccZeroMMmV,
|
||||
IRTraccAverageOverTime,
|
||||
Polynomial,
|
||||
IRTraccCalFactor
|
||||
}
|
||||
public enum NonLinearSLICEWareStyles
|
||||
{
|
||||
Manual,
|
||||
DiagnosticZeroMMmV,
|
||||
ZeroMMmV,
|
||||
AverageOverTime,
|
||||
Polynomial
|
||||
}
|
||||
}
|
||||
17
Common/DTS.CommonCore/Enums/Sensors/PossibleFilters.cs
Normal file
17
Common/DTS.CommonCore/Enums/Sensors/PossibleFilters.cs
Normal file
@@ -0,0 +1,17 @@
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
/// <summary>
|
||||
/// describes different ways of filtering channels and sensors by type
|
||||
/// </summary>
|
||||
public enum PossibleFilters
|
||||
{
|
||||
All,
|
||||
Analog,
|
||||
Squib,
|
||||
DigitalIn,
|
||||
DigitalOut,
|
||||
UART,
|
||||
StreamOut,
|
||||
StreamIn
|
||||
}
|
||||
}
|
||||
7
Common/DTS.CommonCore/Enums/Sensors/SensorChangeTypes.cs
Normal file
7
Common/DTS.CommonCore/Enums/Sensors/SensorChangeTypes.cs
Normal file
@@ -0,0 +1,7 @@
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
public enum SensorChangeTypes
|
||||
{
|
||||
OffsetTolerance
|
||||
}
|
||||
}
|
||||
688
Common/DTS.CommonCore/Enums/Sensors/SensorConstants.cs
Normal file
688
Common/DTS.CommonCore/Enums/Sensors/SensorConstants.cs
Normal file
@@ -0,0 +1,688 @@
|
||||
using DTS.Common.Converters;
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using System.IO.Ports;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
public abstract class SensorConstants
|
||||
{
|
||||
public const string VOLTAGE_INSERTION_UNIT = "mV";
|
||||
public const string TSRAIR_ACCEL_UNIT = "g";
|
||||
public const string TSRAIR_ARS_UNIT = "deg/sec";
|
||||
public const string TSRAIR_TEMPERATURE_UNIT = "C";
|
||||
public const string TSRAIR_HUMIDITY_UNIT = "%";
|
||||
public const string TSRAIR_PRESSURE_UNIT = "PSI";
|
||||
//these are 3D IR-TRACC values for equations
|
||||
//taken originally from config file for
|
||||
//http://manuscript.dts.local/f/cases/29720/config-file-properties-not-being-used-in-view-3D-IRTRACC-channel-add
|
||||
public static double δThorax { get; set; } = 15.65;
|
||||
public static double δAbdomen { get; set; } = 0;
|
||||
public static double D0Thorax { get; set; } = 141.8;
|
||||
public static double D0Abdomen { get; set; } = 150.9;
|
||||
public static double δThoraxLower { get; set; } = -15.65;
|
||||
public static double D0ThoraxLower { get; set; } = 141.8;
|
||||
//EU string for degrees
|
||||
public const string DEGREES = "deg";
|
||||
//EUstring for degrees used by GM
|
||||
public const string DEGREE_ANGLE = "deg-ang";
|
||||
/// <summary>
|
||||
/// these are the units we accept when filtering channels for add calculated channel
|
||||
/// 25513 GM requests option to filter channels available for pots for 3d-IR TRACC to include sensors with "deg-ang"
|
||||
/// </summary>
|
||||
public static readonly string[] POTUnits = new[] { DEGREES, DEGREE_ANGLE };
|
||||
public const double MIN_BRIDGE_RESISTANCE_OHMS = 1;
|
||||
public const double MAX_BRIDGE_RESISTANCE_OHMS = 32000;
|
||||
/// <summary>
|
||||
/// the DEFAULT value for whether sensor calibrations intervals start after calibration or first use
|
||||
/// </summary>
|
||||
public const bool SENSOR_FIRST_USE_DEFAULT = false;
|
||||
/// <summary>
|
||||
/// the current value for whether sensor calibration intervals start after calibration or first use
|
||||
/// note does not query the value, just holds the value between different modules
|
||||
/// </summary>
|
||||
public static bool UseSensorFirstUseDate { get; set; } = false;
|
||||
/// <summary>
|
||||
/// a cached indicator of whether to use isocode filter mapping or not
|
||||
/// is updated whenever the setting is updated by the application, and on startup
|
||||
/// </summary>
|
||||
public static bool UseISOCodeFilterMapping { get; set; } = true;
|
||||
/// <summary>
|
||||
/// FB12764 a cached value for default zero method type
|
||||
/// is updated whenever the setting is updated by the application, and on startup
|
||||
/// </summary>
|
||||
public static ZeroMethodType DefaultZeroMethodType { get; set; } = ZeroMethodType.AverageOverTime;
|
||||
/// <summary>
|
||||
/// FB12764 a cached value for default window start time, if zero method type is Average Over Time
|
||||
/// is updated whenever the setting is updated by the application, and on startup
|
||||
/// </summary>
|
||||
public static double DefaultZeroMethodStart { get; set; } = -0.05D;
|
||||
/// <summary>
|
||||
/// FB12764 a cached value for default window end time, if zero method type is Average Over Time
|
||||
/// is updated whenever the setting is updated by the application, and on startup
|
||||
/// </summary>
|
||||
public static double DefaultZeroMethodEnd{ get; set; } = -0.02D;
|
||||
/// <summary>
|
||||
/// 29759 the default range for TSR AIR HiG channels
|
||||
/// </summary>
|
||||
public static double DefaultRangeHiG { get; set; } = 400D;
|
||||
/// <summary>
|
||||
/// 29759 the default range for TSR AIR LowG channels
|
||||
/// </summary>
|
||||
public static double DefaultRangeLowG { get; set; } = 64D;
|
||||
public static double DefaultRangeLowGDisplay { get; set; } = 50D;
|
||||
///
|
||||
/// 29759 the default range for TSR AIR ARS channels
|
||||
///
|
||||
public static double DefaultRangeARS { get; set; } = 2000D;
|
||||
/// <summary>
|
||||
/// 29917 the default range for the TSR AIR Temperature channel
|
||||
/// </summary>
|
||||
public static double DefaultRangeTemperature { get; set; } = 85D;
|
||||
/// <summary>
|
||||
/// 29917 the default range for the TSR AIR Humidity channel
|
||||
/// </summary>
|
||||
public static double DefaultRangeHumidity { get; set; } = 100D;
|
||||
/// <summary>
|
||||
/// 29917 the default range for the TSR AIR Pressure channel
|
||||
/// </summary>
|
||||
public static double DefaultRangePressure { get; set; } = 16D; //Actually 15.95 PSI (1100 hPa x 0.0145)
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for SQUIB DELAY in ms (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const double SQUIB_DELAY_CONSTANT = 0D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for whether to limit squib output (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const bool SQUIB_LIMIT_DURATION_CONSTANT = true;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for squib output duration (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const double SQUIB_DURATION_CONSTANT = 10D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for squib low tolerance (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const double SQUIB_LOW_TOLERANCE_CONSTANT = 1D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for squib high tolerance (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// 26826 Max Squib Resistance Limit needs to be raised from 8.0 ohms to 10.0 ohms
|
||||
/// </summary>
|
||||
public const double SQUIB_HIGH_TOLERANCE_CONSTANT = 10D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for squib fire mode (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const SquibFireMode SQUIB_FIREMODE_CONSTANT = SquibFireMode.CAP;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for squib output current (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const double SQUIB_CURRENT_CONSTANT = 1.5D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for digital output mode (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const DigitalOutputModes DIGITALOUT_MODE_CONSTANT = DigitalOutputModes.FVLH;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for digital output delay (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const double DIGITALOUT_DELAY_CONSTANT = 0D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for digital output limit duration (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const bool DIGITALOUT_LIMITDURATION_CONSTANT = true;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for digital output duration (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// 13677 Restore defaults page button not functional for sensor settings nav step in system settings tile.
|
||||
/// </summary>
|
||||
public const double DIGITALOUT_DURATION_CONSTANT = 10D;
|
||||
|
||||
/// <summary>
|
||||
/// represents the _original_ default for uart baud rate (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const uint UART_BAUDRATE_CONSTANT = 57600;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for uart data bits (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const uint UART_DATABITS_CONSTANT = 8;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for uart stop bits (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const StopBits UART_STOPBITS_CONSTANT = StopBits.One;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for uart parity (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const Parity UART_PARITY_CONSTANT = Parity.None;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for uart flow control (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const Handshake UART_FLOWCONTROL_CONSTANT = Handshake.None;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for uart data format (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const UartDataFormat UART_DATAFORMAT_CONSTANT = UartDataFormat.Binary;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream input udp address (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const string STREAMIN_ADDRESS_CONSTANT = "UDP://239.1.2.10:8400";
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream output udp profile (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const UDPStreamProfile STREAMOUT_PROFILE_CONSTANT = UDPStreamProfile.CH10_PCM_128BIT_2HDR;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream output udp address (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const string STREAMOUT_ADDRESS_CONSTANT = "UDP://239.1.2.10:8400";
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream output time channel id (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const ushort STREAMOUT_TIME_CHID_CONSTANT = 1;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream output data channel id (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const ushort STREAMOUT_DATA_CHID_CONSTANT = 3;
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream output TmNS configuration (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const string STREAMOUT_TMNS_CONFIG_CONSTANT = "(1,6,60,0,0,0,0,0)";
|
||||
/// <summary>
|
||||
/// represents the _original_ default for stream output irig time data packet interval (in milliseconds) (not the default in the db)
|
||||
/// used for restoring defaults
|
||||
/// </summary>
|
||||
public const ushort STREAMOUT_IRIG_TDP_INTERVAL_CONSTANT = 500;
|
||||
|
||||
public const string TEST_SPECIFIC_DOUT = "TSD_";
|
||||
public const string TEST_SPECIFIC_SQUIB = "TSQ_";
|
||||
public const string TEST_SPECIFIC_DIN = "TSI_";
|
||||
public const string TEST_SPECIFIC_EMB = "TSA_";
|
||||
public const string TEST_SPECIFIC_EMB_CLK = "TSC_";
|
||||
public const string TEST_SPECIFIC_UART = "TSU_";
|
||||
public const string TEST_SPECIFIC_STREAM_OUT = "TSS_";
|
||||
public const string TEST_SPECIFIC_STREAM_IN = "TSN_";
|
||||
|
||||
public const string TEST_SPECIFIC_DIGITAL_IN_SERIAL = "TSI_TestSpecific";
|
||||
public const string TEST_SPECIFIC_DIGITAL_OUT_SERIAL = "TSD_TestSpecific";
|
||||
public const string TEST_SPECIFIC_SQUIB_SERIAL = "TSQ_TestSpecific";
|
||||
public const string TEST_SPECIFIC_ANALOG_SERIAL = "TSA_Embedded";
|
||||
public const string TEST_SPECIFIC_CLOCK_SERIAL = "TSC_Embedded";
|
||||
public const string TEST_SPECIFIC_UART_SERIAL = "TSU_TestSpecific";
|
||||
public const string TEST_SPECIFIC_STREAM_OUT_SERIAL = "TSS_TestSpecific";
|
||||
public const string TEST_SPECIFIC_STREAM_IN_SERIAL = "TSN_TestSpecific";
|
||||
public const string VOLTAGE_INPUT = "Voltage input";
|
||||
|
||||
public static bool IsTestSpecificDigitalOut(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_DOUT)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public static bool IsTestSpecificSquib(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_SQUIB)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// returns true if the serial number belongs to a test specific digital input
|
||||
/// </summary>
|
||||
public static bool IsTestSpecificDigitalIn(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if( !sn.StartsWith(TEST_SPECIFIC_DIN)) return false;
|
||||
return true;
|
||||
}
|
||||
public static bool IsTestSpecificEmbedded(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_EMB)) return false;
|
||||
return true;
|
||||
}
|
||||
public static bool IsTestSpecificEmbeddedClock(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_EMB_CLK)) return false;
|
||||
return true;
|
||||
}
|
||||
public static bool IsTestSpecificStreamOut(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_STREAM_OUT)) return false;
|
||||
return true;
|
||||
}
|
||||
public static bool IsTestSpecificStreamIn(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_STREAM_IN)) return false;
|
||||
return true;
|
||||
}
|
||||
public static bool IsTestSpecificUart(string sn)
|
||||
{
|
||||
if (string.IsNullOrWhiteSpace(sn))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!sn.StartsWith(TEST_SPECIFIC_UART)) return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public const string EditObjectSensorChannelDragFormat = "EditObjectSensorsChannelTable.UserData []";
|
||||
public enum SensorSettings
|
||||
{
|
||||
Range,
|
||||
CFC,
|
||||
Polarity,
|
||||
Position,
|
||||
LimitDuration, //deprecated in 2.1
|
||||
Duration, //deprecated in 2.1
|
||||
Delay, //deprecated in 2.1
|
||||
OutputMode,
|
||||
SQMode,
|
||||
DIMode,
|
||||
DefaultValue,
|
||||
ActiveValue, //12 LAST value in V2.0 settings
|
||||
|
||||
//new in 2.1
|
||||
SquibLimitDuration,
|
||||
SquibDuration,
|
||||
SquibDelay,
|
||||
DigitalOutLimitDuration,
|
||||
DigitalOutDuration,
|
||||
DigitalOutDelay,
|
||||
SquibCurrent,
|
||||
//new in 3.0
|
||||
ZeroMethod,
|
||||
ZeroMethodStart,
|
||||
ZeroMethodEnd,
|
||||
UserValue1,
|
||||
UserValue2,
|
||||
UserValue3,
|
||||
InitialOffset,
|
||||
//FB 13120 added filter class
|
||||
FilterClass,
|
||||
//new in 4.0
|
||||
//18363 Uart Channels
|
||||
UartBaudRate,
|
||||
UartDataBits,
|
||||
UartStopBits,
|
||||
UartParity,
|
||||
UartFlowControl,
|
||||
UartDataFormat,
|
||||
//18364 Stream Out Channels
|
||||
StreamOutUDPProfile,
|
||||
StreamOutUDPAddress,
|
||||
StreamOutUDPTimeChannelId,
|
||||
StreamOutUDPDataChannelId,
|
||||
StreamOutUDPTmNSConfig,
|
||||
StreamOutIRIGTimeDataPacketIntervalMs,
|
||||
//26828 Stream In Channels
|
||||
StreamInUDPAddress,
|
||||
//29760 Implement ACCoupleEnable
|
||||
ACCouplingEnabled,
|
||||
//33145 Voltage insertion channel should be half-bridge
|
||||
BridgeType
|
||||
}
|
||||
|
||||
public enum SensorType
|
||||
{
|
||||
Analog,
|
||||
DigitalIn,
|
||||
DigitalOut,
|
||||
Squib,
|
||||
Clock,
|
||||
UART,
|
||||
StreamOut,
|
||||
StreamIn
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Separator for encoding an added linear calibration with a non-linear calibrated sensor
|
||||
/// </summary>
|
||||
public const string LinearValuesSeparator = "||";
|
||||
|
||||
/// <summary>
|
||||
/// used to convert between different formats and SensivityUnits
|
||||
/// 14448 Error when trying to import sensors.
|
||||
/// </summary>
|
||||
public abstract class SensUnitStringConverter
|
||||
{
|
||||
public static SensUnits ConvertFromString(string s)
|
||||
{
|
||||
s = s.Trim().ToLower();
|
||||
switch (s)
|
||||
{
|
||||
case "none": return SensUnits.NONE;
|
||||
case "mv": return SensUnits.mV;
|
||||
case "mv/v":
|
||||
case "mvperv":
|
||||
return SensUnits.mVperV;
|
||||
case "mv/v/eu":
|
||||
case "mvpervpereu":
|
||||
return SensUnits.mVperVperEU;
|
||||
case "mv/eu":
|
||||
case "mvpereu":
|
||||
return SensUnits.mVperEU;
|
||||
default: throw new InvalidCastException($"Can't convert {s} to SensUnits");
|
||||
}
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// All available Sensitivity Unit types.
|
||||
/// </summary>
|
||||
public enum SensUnits
|
||||
{
|
||||
/// <summary>
|
||||
/// No Sensitivity Units (Polynomial Sensor)
|
||||
/// </summary>
|
||||
[Description("NONE")] NONE = 0,
|
||||
|
||||
/// <summary>
|
||||
/// Sensitivity expressed in mV with output at Capacity EU
|
||||
/// </summary>
|
||||
[Description("mV")] mV = 1,
|
||||
|
||||
/// <summary>
|
||||
/// Excitation proportional sensitivity expressed in mV/V with output at Capacity EU
|
||||
/// </summary>
|
||||
[Description("mV/V")] mVperV = 2,
|
||||
|
||||
/// <summary>
|
||||
/// Excitation proportional sensitivity expressed in mV/V/EU
|
||||
/// </summary>
|
||||
[Description("mV/V/EU")] mVperVperEU = 3,
|
||||
|
||||
/// <summary>
|
||||
/// Sensitivity expressed in mV/EU
|
||||
/// </summary>
|
||||
[Description("mV/EU")] mVperEU = 4
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// All available bridge types.
|
||||
/// </summary>
|
||||
public enum BridgeType
|
||||
{
|
||||
/// <summary>
|
||||
/// sensor uses IEPE setup
|
||||
/// </summary>
|
||||
[Description("IEPE")] IEPE = 1 << 0,
|
||||
|
||||
/// <summary>
|
||||
/// sensor uses quarter bridge setup
|
||||
/// </summary>
|
||||
[Description("Quarter")] QuarterBridge = 1 << 1,
|
||||
|
||||
/// <summary>
|
||||
/// sensor uses half bridge setup
|
||||
/// </summary>
|
||||
[Description("Bridge-Half")] HalfBridge = 1 << 2,
|
||||
|
||||
/// <summary>
|
||||
/// sensor has a full bridge setup
|
||||
/// </summary>
|
||||
[Description("Bridge-Full")] FullBridge = 1 << 3,
|
||||
|
||||
/// <summary>
|
||||
/// digital input setup
|
||||
/// </summary>
|
||||
[Description("DigitalInput")] DigitalInput = 1 << 4,
|
||||
|
||||
/// <summary>
|
||||
/// squib output setup
|
||||
/// </summary>
|
||||
[Description("SQUIB")] SQUIB = 1 << 5,
|
||||
|
||||
/// <summary>
|
||||
/// digital output setup
|
||||
/// </summary>
|
||||
[Description("TOMDigital")] TOMDigital = 1 << 6,
|
||||
|
||||
/// <summary>
|
||||
/// sensor uses a G5 (signal plus) half bridge setup
|
||||
/// </summary>
|
||||
[Description("Bridge-Half SigPlus")] HalfBridge_SigPlus = 1 << 7,
|
||||
|
||||
/// <summary>
|
||||
/// not a "sensor" but encoding the RTC
|
||||
/// </summary>
|
||||
[Description("RTC")] RTC = 1 << 8,
|
||||
|
||||
/// <summary>
|
||||
/// not a "sensor" but values recorded on UART
|
||||
/// </summary>
|
||||
[Description("UART")] UART = 1 << 9,
|
||||
|
||||
/// <summary>
|
||||
/// not a "sensor" but values sent out via stream
|
||||
/// </summary>
|
||||
[Description("StreamOut")] StreamOut = 1 << 10,
|
||||
/// <summary>
|
||||
/// not a "sensor" but values received via stream
|
||||
/// </summary>
|
||||
[Description("StreamIn")] StreamIn = 1 << 11
|
||||
}
|
||||
public static BridgeType ConvertIntToBridgeType(int bridge)
|
||||
{
|
||||
switch (bridge)
|
||||
{
|
||||
case 0: return BridgeType.IEPE;
|
||||
case 4: return BridgeType.HalfBridge_SigPlus;
|
||||
case 3: return BridgeType.FullBridge;
|
||||
case 2: return BridgeType.HalfBridge;
|
||||
case 1: return BridgeType.QuarterBridge;
|
||||
case 8: return BridgeType.RTC;
|
||||
default: return BridgeType.FullBridge;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// this is apparently needed for historical reasons
|
||||
/// as the sensor db apparently doesn't use the bitmask value for storage?
|
||||
/// </summary>
|
||||
/// <param name="bridge"></param>
|
||||
/// <returns></returns>
|
||||
public static int ConvertBridgeToInt(BridgeType bridge)
|
||||
{
|
||||
switch (bridge)
|
||||
{
|
||||
case BridgeType.IEPE: return 0;
|
||||
case BridgeType.QuarterBridge: return 1;
|
||||
case BridgeType.HalfBridge: return 2;
|
||||
case BridgeType.FullBridge: return 3;
|
||||
case BridgeType.HalfBridge_SigPlus: return 4;
|
||||
case BridgeType.RTC: return 8;
|
||||
default: return 3;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// how to handle sensor calibrations that are out of date
|
||||
/// 1) always allow sensors in a data collection, just warn
|
||||
/// 2) don't allow sensors which are out of date, warn if near out of date
|
||||
/// </summary>
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum SensorCalPolicy
|
||||
{
|
||||
[Description("SENSOR_CAL_POLICY_ALLOW_ALWAYS")]
|
||||
AllowAlways,
|
||||
[Description("SENSOR_CAL_POLICY_DONT_ALLOW")]
|
||||
DONT_ALLOW
|
||||
}
|
||||
/// <summary>
|
||||
/// allows for this field to be cached without having to be retrieved when processing a lot of channels
|
||||
/// </summary>
|
||||
public static int SensorCalOutOfDateWarningPeriodDays = 14;
|
||||
public static SensorCalPolicy SensorCalPolicyCurrent = SensorCalPolicy.DONT_ALLOW;
|
||||
/// <summary>
|
||||
/// the default policy for sensors is to not allow out of cal sensors
|
||||
/// </summary>
|
||||
public const SensorCalPolicy CAL_SENSOR_POLICY_DEFAULT = SensorCalPolicy.DONT_ALLOW;
|
||||
/// <summary>
|
||||
/// default warning period for sensors for calibration (in days)
|
||||
/// </summary>
|
||||
public const int CAL_SENSOR_POLICY_WARNING_DAYS_DEFAULT = 14;
|
||||
|
||||
public enum CouplingModes
|
||||
{
|
||||
AC=0,
|
||||
DC
|
||||
}
|
||||
/// <summary>
|
||||
/// signifies whether autosense for IEPE/analog will be performed
|
||||
/// this variable only holds the value for the property, it does not
|
||||
/// serialize, deserialize, the property must be set by any using
|
||||
/// applications first
|
||||
/// </summary>
|
||||
public static bool DisableAutoSense{ get; set; }
|
||||
|
||||
// FB16524: diagnostic result should include the resting voltage of an IEPE sensor
|
||||
// http://manuscript.dts.local/f/cases/16524/diagnostic-result-should-include-the-resting-voltage-of-an-IEPE-sensor
|
||||
public static double DefaultBridgeOffsetMVTolLow { get; set; } = -100;
|
||||
public static double DefaultBridgeOffsetMVTolHigh { get; set; } = 100;
|
||||
public static double DefaultIEPEOffsetMVTolLow { get; set; } = -2000;
|
||||
public static double DefaultIEPEOffsetMVTolHigh { get; set; } = 2000;
|
||||
|
||||
//ARS valid ranges for TSR AIR
|
||||
private const int ARS2000 = 2000;
|
||||
private const int ARS250 = 250;
|
||||
public const int ARSMax = 2000;
|
||||
public const int ARSMin = 250;
|
||||
|
||||
//LowG valid ranges for TSR AIR
|
||||
private const int LowG64 = 64;
|
||||
private const int LowG32 = 32;
|
||||
private const int LowG16 = 16;
|
||||
private const int LowG8 = 8;
|
||||
public const int LowGMax = 64;
|
||||
public const int LowGMin = 8;
|
||||
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum AvailableRangesLowG
|
||||
{
|
||||
[Description("TSRAIR_LOW_g_64")]
|
||||
LowG64D = LowG64,
|
||||
[Description("TSRAIR_LOW_g_32")]
|
||||
LowG32D = LowG32,
|
||||
[Description("TSRAIR_LOW_g_16")]
|
||||
LowG16D = LowG16,
|
||||
[Description("TSRAIR_LOW_g_8")]
|
||||
LowG8D = LowG8
|
||||
};
|
||||
|
||||
public enum AvailableRangesARS
|
||||
{
|
||||
ARS2000D = ARS2000,
|
||||
ARS250D = ARS250
|
||||
};
|
||||
|
||||
public const string HighG = "-High g";
|
||||
public const string LowG = "-Low g";
|
||||
public const string ARS = "-ARS";
|
||||
public const string Atm = "-Atm";
|
||||
public const int TSRAirTemperatureChannel = 9;
|
||||
public const int TSRAirHumidityChannel = 10;
|
||||
public const int TSRAirPressureChannel = 11;
|
||||
public static bool IsTSRAirHighGChannel(string moduleSerialNumber)
|
||||
{
|
||||
if (moduleSerialNumber.EndsWith(HighG))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
public static bool IsTSRAirLowGChannel(string moduleSerialNumber)
|
||||
{
|
||||
if (moduleSerialNumber.EndsWith(LowG))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
public static bool IsTSRAirARSChannel(string moduleSerialNumber)
|
||||
{
|
||||
if (moduleSerialNumber.EndsWith(ARS))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
public static bool IsTSRAirAtmChannel(string moduleSerialNumber)
|
||||
{
|
||||
if (moduleSerialNumber.EndsWith(Atm))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
public static bool IsTSRAirHumidityChannel(string moduleSerialNumber, int channelNumber)
|
||||
{
|
||||
return IsTSRAirAtmChannel(moduleSerialNumber) && (channelNumber == TSRAirHumidityChannel);
|
||||
}
|
||||
}
|
||||
}
|
||||
11
Common/DTS.CommonCore/Enums/Sensors/SensorStatus.cs
Normal file
11
Common/DTS.CommonCore/Enums/Sensors/SensorStatus.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
public enum SensorStatus
|
||||
{
|
||||
Available,
|
||||
InUse,
|
||||
OutForService,
|
||||
OutForCalibration,
|
||||
Retired
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,35 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum AnalogSensorFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
Manufacturer,
|
||||
Model,
|
||||
Capacity,
|
||||
CalInterval,
|
||||
Sensitivity,
|
||||
LinearSensitivity,
|
||||
Resistance,
|
||||
Excitation,
|
||||
Units,
|
||||
Id,
|
||||
CalDate,
|
||||
CalDueDate,
|
||||
ModifiedBy,
|
||||
LastModified,
|
||||
IEPE,
|
||||
OutOfDate,
|
||||
InWarningPeriod,
|
||||
NonLinearCalucationType,
|
||||
ZeroMethod,
|
||||
ZeroMethodStart,
|
||||
ZeroMethodEnd,
|
||||
//13065 Sensor "First Use" Date
|
||||
FirstUseDate,
|
||||
UserValue1,
|
||||
UserValue2,
|
||||
UserValue3
|
||||
}
|
||||
}
|
||||
18
Common/DTS.CommonCore/Enums/Sensors/SensorsList/CACOption.cs
Normal file
18
Common/DTS.CommonCore/Enums/Sensors/SensorsList/CACOption.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using DTS.Common.Base.Classes;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum CACOption
|
||||
{
|
||||
[DescriptionResourceAttribute("CAC_Manual")]
|
||||
Manual,
|
||||
[DescriptionResourceAttribute("CAC_Capacity")]
|
||||
Capacity,
|
||||
[DescriptionResourceAttribute("CAC_RangeHigh")]
|
||||
RangeHigh,
|
||||
[DescriptionResourceAttribute("CAC_RangeMedium")]
|
||||
RangeMedium,
|
||||
[DescriptionResourceAttribute("CAC_RangeLow")]
|
||||
RangeLow,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum DigitalInputFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
Mode,
|
||||
ModifiedBy,
|
||||
LastModified
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum DigitalOutFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
Delay,
|
||||
Duration,
|
||||
ModifiedBy,
|
||||
LastModified
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum SensorListTabs
|
||||
{
|
||||
ANALOG = 0,
|
||||
SQUIB = 1,
|
||||
DIGITAL_IN = 2,
|
||||
DIGITAL_OUT = 3,
|
||||
UART = 4,
|
||||
STREAM_IN = 5,
|
||||
STREAM_OUT = 6
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum SquibFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
ResistanceLow,
|
||||
ResistanceHigh,
|
||||
Id,
|
||||
Mode,
|
||||
Delay,
|
||||
Current,
|
||||
Duration,
|
||||
ModifiedBy,
|
||||
LastModified
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum StreamInSettingFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
LastModifiedBy,
|
||||
LastModified,
|
||||
UDPAddress,
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum StreamOutSettingFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
Description,
|
||||
LastModifiedBy,
|
||||
LastModified,
|
||||
UDPProfile,
|
||||
UDPAddress,
|
||||
UDPTimeChannelId,
|
||||
UDPDataChannelId,
|
||||
UDPTmNSConfig,
|
||||
IRIGTimeDataPacketIntervalMs,
|
||||
TMATSIntervalMs
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
namespace DTS.Common.Enums.Sensors.SensorsList
|
||||
{
|
||||
public enum UartSettingFields
|
||||
{
|
||||
Included,
|
||||
SerialNumber,
|
||||
BaudRate,
|
||||
DataBits,
|
||||
StopBits,
|
||||
Parity,
|
||||
FlowControl,
|
||||
DataFormat,
|
||||
LastModifiedBy,
|
||||
LastModified
|
||||
}
|
||||
}
|
||||
51
Common/DTS.CommonCore/Enums/Sensors/ZeroMethodType.cs
Normal file
51
Common/DTS.CommonCore/Enums/Sensors/ZeroMethodType.cs
Normal file
@@ -0,0 +1,51 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums.Sensors
|
||||
{
|
||||
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum ZeroMethodType
|
||||
{
|
||||
// Lots of legacy compatibility (e.g. importing GM ISF) depends on the order/value of this enum.
|
||||
// also 14906 Can the parameter names in the test match the sensors tile names?
|
||||
/// <summary>
|
||||
/// calculate electrical zero using an average over time
|
||||
/// </summary>
|
||||
[Description("ZeroMethod_AverageOverTime")]
|
||||
AverageOverTime = 0,
|
||||
/// <summary>
|
||||
/// calculate zero using time in pre-event
|
||||
/// </summary>
|
||||
//[Description("Use Diagnostics Zero")]
|
||||
[Description("ZeroMethod_DiagnosticLevel")]
|
||||
UsePreEventDiagnosticsZero = 1,
|
||||
/// <summary>
|
||||
/// calculate zero using injected value
|
||||
/// </summary>
|
||||
//[Description("Absolute Zero")]
|
||||
[Description("ZeroMethod_None")]
|
||||
None = 2
|
||||
}
|
||||
/// <summary>
|
||||
/// Original version of all available zero method types.
|
||||
/// </summary>
|
||||
public enum OriginalZeroMethodType
|
||||
{
|
||||
/// <summary>
|
||||
/// calculate electrical zero using an average over time
|
||||
/// </summary>
|
||||
//[Description("Average Over Time")]
|
||||
AverageOverTime,
|
||||
/// <summary>
|
||||
/// calculate zero using time in pre-event
|
||||
/// </summary>
|
||||
//[Description("Use Diagnostics Zero")]
|
||||
UsePreCalZero,
|
||||
/// <summary>
|
||||
/// calculate zero using injected value
|
||||
/// </summary>
|
||||
//[Description("Absolute Zero")]
|
||||
None
|
||||
}
|
||||
}
|
||||
13
Common/DTS.CommonCore/Enums/SettingsExport/TopLevelFields.cs
Normal file
13
Common/DTS.CommonCore/Enums/SettingsExport/TopLevelFields.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
namespace DTS.Common.Enums.SettingsExport
|
||||
{
|
||||
/// <summary>
|
||||
/// possible root tags in the xml
|
||||
/// </summary>
|
||||
public enum TopLevelFields
|
||||
{
|
||||
GlobalSettings,
|
||||
TestSetupDefaultSettings,
|
||||
SensorSettings,
|
||||
TestHistorySettings
|
||||
}
|
||||
}
|
||||
31
Common/DTS.CommonCore/Enums/SliceSimpleArm/SSACommands.cs
Normal file
31
Common/DTS.CommonCore/Enums/SliceSimpleArm/SSACommands.cs
Normal file
@@ -0,0 +1,31 @@
|
||||
namespace DTS.Common.Enums.SliceSimpleArm
|
||||
{
|
||||
public enum SSACommand
|
||||
{
|
||||
ConfigureDevice,
|
||||
Diagnostics,
|
||||
Arm,
|
||||
StartRecord,
|
||||
CheckForArmed,
|
||||
Disarm,
|
||||
Download,
|
||||
SetLowPowerMode,
|
||||
Trigger,
|
||||
}
|
||||
|
||||
public enum SSAResponse
|
||||
{
|
||||
Unknown,
|
||||
Status,
|
||||
Pass,
|
||||
Fail,
|
||||
SystemNotArmed,
|
||||
NoSensorsFound,
|
||||
NoEIDsFound,
|
||||
UnknownEIDFound,
|
||||
NoDASConnected,
|
||||
ExceptionThrown,
|
||||
DiagnosticsFailedOffsetTolerance,
|
||||
DiagnosticsFailedShuntCheck,
|
||||
}
|
||||
}
|
||||
25
Common/DTS.CommonCore/Enums/Squibs.cs
Normal file
25
Common/DTS.CommonCore/Enums/Squibs.cs
Normal file
@@ -0,0 +1,25 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Base.Classes;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum SquibMeasurementType
|
||||
{
|
||||
NONE = 0, //the squib's measurement mode has not been set
|
||||
CURRENT = 1 << 0, //the squib's current will be recorded
|
||||
INIT_SIGNAL = 1 << 1, //the squib's initiation indicator will be recorded
|
||||
VOLTAGE = 1 << 2, //the squib's voltage will be recorded
|
||||
}
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum SquibFireMode
|
||||
{
|
||||
NONE = 1 << 0, //squib's fire mode not set
|
||||
[DescriptionResource("SquibFireMode_Cap")]
|
||||
CAP = 1 << 1, //use capacitor discharge
|
||||
[DescriptionResource("SquibFireMode_CC")]
|
||||
CONSTANT = 1 << 2, //use constant current discharge
|
||||
AC = 1 << 3 //use AC discharge
|
||||
}
|
||||
}
|
||||
61
Common/DTS.CommonCore/Enums/StreamDigitalFilterTypes.cs
Normal file
61
Common/DTS.CommonCore/Enums/StreamDigitalFilterTypes.cs
Normal file
@@ -0,0 +1,61 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Base.Classes;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
// Implement DSP IIR/FIR Profile API http://manuscript.dts.local/f/cases/17913/Implement-DSP-IIR-FIR-Profile-API
|
||||
// Options for Digital Filters on S6A
|
||||
//
|
||||
// The API:
|
||||
// System Attribute 168 uint32[6]. The first value is the DSP profile which follows the setting example in FWTU version 1.0850.xxx or later in realtime page.
|
||||
// There are only 4 settings supported at this time.The enum is defined in FWTU as well.
|
||||
// NO_DSP_DILTER = default option as currently is in older firmware.
|
||||
// CH10_IIR_6TH_OPTION_80x = Selection for Boeing chapter10 and TmNS streaming.
|
||||
// CH10_FIR_45T65T_OPTION_80x = Selection for Boeing rate/bandwidth but using FIR filter.Not IIR.This is for customer who is interested in linear Phase Response.
|
||||
// ALL_RT_IIR_6TH_OPTION_80x = Selection for Boeing chapter10 and TmNS streaming including DTS realtime stream.
|
||||
// ALL_RT_FIR_45T65T_OPTION_80x = Selection for Boeing rate/bandwidth but using FIR filter.Not IIR.This is for customer who is interested in linear Phase Response including DTS realtime stream.
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum StreamDigitalFilterTypes
|
||||
{
|
||||
[DescriptionResource("StreamDigitalFilterTypes_NO_DSP_FILTER")]
|
||||
NO_DSP_FILTER = 0, /*! 0 disable and run all realtime stream as legacy */
|
||||
//[Description("Manual Mode IIR - File")]
|
||||
//TESTMODE_CH10_IIR = 1, /*! 1 manual mode with IIR enable. Looks for parameters from file and filled other with defaults */
|
||||
//[Description("Manual Mode FIR - File")]
|
||||
//TESTMODE_CH10_FIR = 2, /*! 2 manual mode with FIR enable. Looks for parameters from file and filled other with defaults */
|
||||
//[Description("Manual Mode IIR - All Streaming")]
|
||||
//TESTMODE_ALL_RT_IIR = 3, /*! 3 manual mode with IIR for all stream including legacy RT */
|
||||
//[Description("Manual Mode FIR - All Streaming")]
|
||||
//TESTMODE_ALL_RT_FIR = 4, /*! 4 manual mode with FIR for all stream including legacy RT */
|
||||
|
||||
[DescriptionResource("StreamDigitalFilterTypes_CH10_IIR_6TH_OPTION_80X")]
|
||||
CH10_IIR_6TH_OPTION_80X = 5, /*! 5 support BA rates with 6th IIR butterworth response */
|
||||
[DescriptionResource("StreamDigitalFilterTypes_CH10_FIR_45T65T_OPTION_80X")]
|
||||
CH10_FIR_45T65T_OPTION_80X = 6, /*! 6 support BA rates with dual-step 45T -> 65T FIR flat phase response */
|
||||
|
||||
//_TDB_CH10_FIR_85T_6X_SAMPLING = 7, /*! 7 FIR OPTION_1 FIR with automatic select sampling rate = 6x of realtime. Medium BPI */
|
||||
//_TDB_CH10_FIR_105T_6X_SAMPLING = 8, /*! 8 FIR OPTION_2 FIR with automatic select sampling rate = 8x of realtime. Narrow BPI */
|
||||
//_TDB_CH10_FIR_125T_8X_SAMPLING = 9, /*! 9 FIR OPTION_3 FIR with automatic select sampling rate = 8x of realtime. Narrow BPI */
|
||||
//_TDB_DTS_IIR_OPTION_1 = 10, /*! 10 */
|
||||
//_TDB_DTS_IIR_OPTION_2 = 11, /*! 11 */
|
||||
//_TDB_DTS_IIR_OPTION_3 = 12, /*! 12 */
|
||||
|
||||
[DescriptionResource("StreamDigitalFilterTypes_ALL_RT_IIR_6TH_OPTION_80X")]
|
||||
ALL_RT_IIR_6TH_OPTION_80X = 13, /*! 13 support BA rates with 6th IIR butterworth response */
|
||||
[DescriptionResource("StreamDigitalFilterTypes_ALL_RT_FIR_45T65T_OPTION_80X")]
|
||||
ALL_RT_FIR_45T65T_OPTION_80X = 14, /*! 14 support BA rates with dual-step 45T -> 65T FIR flat phase response */
|
||||
|
||||
//_TDB_ALL_RT_FIR_85T_6X_SAMPLING = 15, /*! 15 FIR OPTION_1 FIR with automatic select sampling rate = 6x of realtime. Medium BPI */
|
||||
//_TDB_ALL_RT_FIR_105T_6X_SAMPLING = 16, /*! 16 FIR OPTION_2 FIR with automatic select sampling rate = 8x of realtime. Narrow BPI */
|
||||
//_TDB_ALL_RT_FIR_125T_8X_SAMPLING = 17, /*! 17 FIR OPTION_3 FIR with automatic select sampling rate = 8x of realtime. Narrow BPI */
|
||||
//_TDB_ALL_RT_DTS_IIR_OPTION_1 = 18, /*! 18 */
|
||||
//_TDB_ALL_RT_DTS_IIR_OPTION_2 = 19, /*! 19 */
|
||||
//_TDB_ALL_RT_DTS_IIR_OPTION_3 = 20, /*! 20 */
|
||||
//_TDB_CH10_IIR_6TH_6X_SAMPLING = 21, /*! 21 IIR OPTION_1 DTS DBG IIR with automatic select sampling rate = 6x of realtime. Medium BPI */
|
||||
//_TDB_CH10_IIR_6TH_8X_SAMPLING = 22, /*! 22 IIR OPTION_2 DTS DBG IIR with automatic select sampling rate = 8x of realtime. Narrow BPI */
|
||||
//_TDB_ALL_RT_IIR_6TH_6X_SAMPLING = 23, /*! 23 IIR OPTION_1 DTS DBG IIR with automatic select sampling rate = 6x of realtime. Medium BPI */
|
||||
//_TDB_ALL_RT_IIR_6TH_8X_SAMPLING = 24, /*! 24 IIR OPTION_2 DTS DBG IIR with automatic select sampling rate = 8x of realtime. Narrow BPI */
|
||||
//_TDB_DSP_FILTER_OPTION_MAX = 25
|
||||
}
|
||||
}
|
||||
13
Common/DTS.CommonCore/Enums/Strings.cs
Normal file
13
Common/DTS.CommonCore/Enums/Strings.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum StringReplacementMode
|
||||
{
|
||||
All,
|
||||
First,
|
||||
Last
|
||||
}
|
||||
}
|
||||
38
Common/DTS.CommonCore/Enums/SupportedExportFormatBitFlags.cs
Normal file
38
Common/DTS.CommonCore/Enums/SupportedExportFormatBitFlags.cs
Normal file
@@ -0,0 +1,38 @@
|
||||
using System;
|
||||
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
[Flags]
|
||||
public enum SupportedExportFormatBitFlags
|
||||
{
|
||||
none = 0x0, //1<<0
|
||||
csvunfiltered = 0x1, //1<<0
|
||||
diademadc = 0x2, //1 <<1
|
||||
isounfiltered = 0x4, // 1<<2
|
||||
somatunfiltered = 0x8, //1 << 3
|
||||
tdmsadc = 0x10, //1 << 4
|
||||
toyotaunfiltered = 0x20, //1<<5
|
||||
tsvunfiltered = 0x40,
|
||||
csvfiltered = 0x80,
|
||||
//diademfiltered = 0x100, //unused & available
|
||||
isofiltered = 0x200,
|
||||
somatfiltered = 0x400,
|
||||
tdasadc = 0x800,
|
||||
toyotafiltered = 0x1000,
|
||||
tsvfiltered = 0x2000,
|
||||
rdfadc = 0x4000,
|
||||
ChryslerDDAS = 0x8000,
|
||||
HDFUnfiltered = 0x10000,
|
||||
HDFFiltered = 0x20000,
|
||||
HDFMV = 0x40000,
|
||||
HDFADC = 0x80000,
|
||||
xlsxfiltered = 0x100000,
|
||||
xlsxunfiltered = 0x200000,
|
||||
CSVADC = 0x400000,
|
||||
CSVMV = 0x800000,
|
||||
//DataPRO 3.3, Chapter 10 export
|
||||
Ch10FilteredEU = 0x1000000,
|
||||
Ch10UnfilteredEU = 0x2000000,
|
||||
FIATASC = 0x4000000,
|
||||
}
|
||||
}
|
||||
26
Common/DTS.CommonCore/Enums/T0Mode.cs
Normal file
26
Common/DTS.CommonCore/Enums/T0Mode.cs
Normal file
@@ -0,0 +1,26 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
using DTS.Common.Utils;
|
||||
using Xceed.Wpf.Toolkit.PropertyGrid.Attributes;
|
||||
// ReSharper disable ConvertToAutoProperty
|
||||
// ReSharper disable once CheckNamespace
|
||||
|
||||
namespace DTS.Common
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum T0Mode
|
||||
{
|
||||
[Description("DAS")]
|
||||
DAS = 0,
|
||||
[Description("Test")]
|
||||
Test = 1,
|
||||
}
|
||||
|
||||
public class T0ModeItemSource : IItemsSource
|
||||
{
|
||||
public ItemCollection GetValues()
|
||||
{
|
||||
return EnumUtil.GetValuesList<T0Mode>();
|
||||
}
|
||||
}
|
||||
}
|
||||
14
Common/DTS.CommonCore/Enums/TSRAIRGo/NavigationButtonId.cs
Normal file
14
Common/DTS.CommonCore/Enums/TSRAIRGo/NavigationButtonId.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
namespace DTS.Common.Enums.TSRAIRGo
|
||||
{
|
||||
public enum NavigationButtonId
|
||||
{
|
||||
TestId,
|
||||
ArmDisarm,
|
||||
Trigger,
|
||||
Download,
|
||||
ViewData,
|
||||
ExportData,
|
||||
Help,
|
||||
Dashboard
|
||||
}
|
||||
}
|
||||
148
Common/DTS.CommonCore/Enums/TTS/TTSEnums.cs
Normal file
148
Common/DTS.CommonCore/Enums/TTS/TTSEnums.cs
Normal file
@@ -0,0 +1,148 @@
|
||||
using System;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
|
||||
namespace DTS.Common.Enums.TTS
|
||||
{
|
||||
/// <summary>
|
||||
/// used to indicate the current support for the field
|
||||
/// 18396 TTS import has too many columns and it makes confusion
|
||||
/// </summary>
|
||||
public enum FieldSupportLevel
|
||||
{
|
||||
RequiredParameter,
|
||||
RemainedButNotUsed,
|
||||
RemovedParameter
|
||||
}
|
||||
/// <summary>
|
||||
/// an attribute that can be used to mark fields as required, ignore, or removed
|
||||
/// used in 18396 but could be applied to other enums pretty easily
|
||||
/// </summary>
|
||||
[AttributeUsage(AttributeTargets.Field)]
|
||||
public class FieldSupportAttribute : Attribute
|
||||
{
|
||||
public FieldSupportLevel SupportLevel { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// constructs a <see cref="ExcitationVoltageOptions.VoltageMagnitudeAttribute" />
|
||||
/// with a given value
|
||||
/// </summary>
|
||||
/// <param name="value"></param>
|
||||
public FieldSupportAttribute(FieldSupportLevel value) { SupportLevel = value; }
|
||||
|
||||
/// <summary>
|
||||
/// returns the support level for the enum value
|
||||
/// </summary>
|
||||
/// <param name="genericEnum"></param>
|
||||
/// <returns></returns>
|
||||
public static FieldSupportLevel GetSupportLevel(Enum genericEnum)
|
||||
{
|
||||
Type genericEnumType = genericEnum.GetType();
|
||||
var memberInfo = genericEnumType.GetMember(genericEnum.ToString());
|
||||
if ((memberInfo != null && memberInfo.Length > 0))
|
||||
{
|
||||
var attribs = memberInfo[0].GetCustomAttributes(typeof(FieldSupportAttribute), false);
|
||||
if (attribs != null && attribs.Any())
|
||||
{
|
||||
return ((FieldSupportAttribute)attribs.ElementAt(0)).SupportLevel;
|
||||
}
|
||||
}
|
||||
return FieldSupportLevel.RemovedParameter;
|
||||
}
|
||||
}
|
||||
public enum ToyotaFieldOrder
|
||||
{
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
ChannelNumber = 0,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
ChannelCode = 1,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
JCodeOrDescription = 2,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
ChannelRange = 3,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
ChannelFilterHz = 4,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
SensorID = 5,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
SensorSerialNumber = 6,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
SensorSensitivity = 7,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
SensorExcitationVolts = 8,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
SensorCapacity = 9,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
SensorEU = 10,
|
||||
[FieldSupport(FieldSupportLevel.RequiredParameter)]
|
||||
SensorPolarity = 11,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
ChannelType = 12,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
Description = 13,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
ProportionalToExcitation = 14,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
BridgeResistance = 15,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
InitialOffsetVoltage = 16,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
InitialOffsetVoltageTolerance = 17,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
RemoveOffset = 18,
|
||||
[FieldSupport(FieldSupportLevel.RemainedButNotUsed)]
|
||||
ZeroMethod = 19,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
CableCompensationMultiplier = 20,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
InitialEUInMV = 21,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
InitialEUInEU = 22,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
IRTRACCExponent = 23,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
PolynomialConstant = 24,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
PolynomialCoefficentC = 25,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
PolynomialCoefficentB = 26,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
PolynomialCoefficentA = 27,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
PolynomialCoefficentAlpha = 28,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
ISOCode = 29,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
ISODescription = 30,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
ISOPolarity = 31,
|
||||
[FieldSupport(FieldSupportLevel.RemovedParameter)]
|
||||
KyowaSpecificField_1 = 32, //http://fogbugz/fogbugz/default.asp?5433
|
||||
}
|
||||
public enum ToyotaBridgeType
|
||||
{
|
||||
[Description("Full Bridge")]
|
||||
FullBridge,
|
||||
[Description("Half Bridge")]
|
||||
HalfBridge,
|
||||
[Description("Voltage")]
|
||||
Voltage,
|
||||
[Description("PotentiometerFB")]
|
||||
PotentionmeterFullBridge,
|
||||
[Description("PotentiometerHB")]
|
||||
PotentionmeterHalfBridge,
|
||||
[Description("IRTRACC")]
|
||||
IRTRACC,
|
||||
[Description("LinearChestPot")]
|
||||
LinearChestPot
|
||||
}
|
||||
public enum ToyotaZeroMethods
|
||||
{
|
||||
[Description("0")]
|
||||
None = 0,
|
||||
[Description("1")]
|
||||
AverageOverTime = 1,
|
||||
[Description("2")]
|
||||
UsePreEventDiagnosticsZero = 2
|
||||
}
|
||||
}
|
||||
18
Common/DTS.CommonCore/Enums/TabControlOperation.cs
Normal file
18
Common/DTS.CommonCore/Enums/TabControlOperation.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
namespace DTS.Common.Enums
|
||||
{
|
||||
/// <summary>
|
||||
/// Enum representing the TabControl operations type.
|
||||
/// </summary>
|
||||
public enum TabControlOperation
|
||||
{
|
||||
/// <summary>
|
||||
/// The item has been added to the TabControl.
|
||||
/// </summary>
|
||||
AddedItem,
|
||||
|
||||
/// <summary>
|
||||
/// The item has been removed from the TabControl.
|
||||
/// </summary>
|
||||
RemovedItem
|
||||
}
|
||||
}
|
||||
16
Common/DTS.CommonCore/Enums/TestSetups/RealtimeGraphsEnum.cs
Normal file
16
Common/DTS.CommonCore/Enums/TestSetups/RealtimeGraphsEnum.cs
Normal file
@@ -0,0 +1,16 @@
|
||||
using System.ComponentModel;
|
||||
using DTS.Common.Converters;
|
||||
|
||||
namespace DTS.Common.Enums.TestSetups
|
||||
{
|
||||
[TypeConverter(typeof(EnumDescriptionTypeConverter))]
|
||||
public enum RealtimeGraphsEnum
|
||||
{
|
||||
[Description("RealtimeGraphs_One")]
|
||||
One = 1,
|
||||
[Description("RealtimeGraphs_Three")]
|
||||
Three = 3,
|
||||
[Description("RealtimeGraphs_Six")]
|
||||
Six = 6
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user