init
This commit is contained in:
@@ -0,0 +1,54 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.ObjectModel;
|
||||
using System.Windows;
|
||||
using DTS.Common.Interface.Channels;
|
||||
using DTS.Common.Interface.DataRecorders;
|
||||
using DTS.Common.Interface.Groups.GroupList;
|
||||
using DTS.Common.Interface.Sensors;
|
||||
|
||||
namespace DTS.Common.Interface.TestSetups.TestSetupsList
|
||||
{
|
||||
public interface ITestSetup : ITestSetupRecord
|
||||
{
|
||||
void AddGroup(IGroup group, IDictionary<int, ISensorData> sensorLookup, IDictionary<long, IGroupChannel> channelLookup);
|
||||
Dictionary<IGroup, IGroupChannel[]> ChannelsForGroup { get; set; }
|
||||
Dictionary<string, bool> DASClockMasterList { get; set; }
|
||||
Dictionary<string, double> DASSampleRateList { get; set; }
|
||||
Dictionary<string, float> DASAAFRateList { get; set; }
|
||||
Dictionary<string, List<string>> EncapsulatedDASList { get; set; }
|
||||
//returns rate for das, if doesn't currently have a rate uses default value
|
||||
double GetSampleRate(string dasSerialNumber, double defaultValue);
|
||||
bool Filter(string term);
|
||||
Visibility TooltipVisibility { get; }
|
||||
string TooltipMessage { get; }
|
||||
string CompletionErrorMessage { get; }
|
||||
|
||||
ObservableCollection<IGroup> Groups { get; set; }
|
||||
void AddGroup(IGroup group, IDictionary<int, ISensorData> sensorLookup, IDictionary<int, IDASHardware> hardwareLookup, IChannelSetting[] channelDefaults);
|
||||
|
||||
/// <summary>
|
||||
/// explicitly adds hardware to test, regardless of what hardware is
|
||||
/// included through groups
|
||||
/// </summary>
|
||||
int[] AddedHardware { get; set; }
|
||||
/// <summary>
|
||||
/// explicitly removes hardware from test, regardless of what hardware was included through groups
|
||||
/// </summary>
|
||||
int[] RemovedHardware { get; set; }
|
||||
|
||||
int[] GetAllIncludedHardware();
|
||||
|
||||
void AddHardware(int dasId, string dasSerialNumber, IDASHardware[] allHardware, IDictionary<int, IDASHardware> lookup);
|
||||
void AddHardware(int dasId, IDictionary<int, IDASHardware> lookup);
|
||||
void RemoveHardware(int dasId, IDASHardware[] allHardware, IDictionary<int, IDASHardware> lookup);
|
||||
void SaveGroups();
|
||||
void SaveHardware();
|
||||
void RemoveGroup(IGroup group);
|
||||
void MoveGroupUp(IGroup group);
|
||||
void MoveGroupDown(IGroup group);
|
||||
void MoveGroupToDisplayOrder(IGroup group, int displayOrder);
|
||||
|
||||
List<IGroupChannel> GetChannels();
|
||||
void SetTestSetupChannelOrder();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,321 @@
|
||||
using DTS.Common.Enums;
|
||||
using DTS.Common.Enums.DASFactory;
|
||||
using DTS.Common.Enums.Sensors;
|
||||
using DTS.Common.Enums.Viewer;
|
||||
using DTS.Common.Interface.ISO.ExtraProperties;
|
||||
using DTS.Common.Interface.RegionOfInterest;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
|
||||
namespace DTS.Common.Interface.TestSetups.TestSetupsList
|
||||
{
|
||||
/// <summary>
|
||||
/// Describes a test setup record in the database
|
||||
/// </summary>
|
||||
public interface ITestSetupRecord
|
||||
{
|
||||
/// <summary>
|
||||
/// does a deep copy of provided test setup
|
||||
/// </summary>
|
||||
/// <param name="copy">source record to copy</param>
|
||||
void Copy(ITestSetupRecord copy);
|
||||
/// <summary>
|
||||
/// Database Id of test setup
|
||||
/// </summary>
|
||||
int Id { get; set; }
|
||||
/// <summary>
|
||||
/// Name of test setup
|
||||
/// </summary>
|
||||
string Name { get; set; }
|
||||
/// <summary>
|
||||
/// Description of test setup
|
||||
/// </summary>
|
||||
string Description { get; set; }
|
||||
/// <summary>
|
||||
/// whether test execution should progress automatically
|
||||
/// </summary>
|
||||
bool AutomaticProgression { get; set; }
|
||||
/// <summary>
|
||||
/// delay between steps when using automatic progression
|
||||
/// </summary>
|
||||
int AutomaticProgressionDelayMS { get; set; }
|
||||
/// <summary>
|
||||
/// whether the trigger polarity should be switched from close to open
|
||||
/// </summary>
|
||||
bool InvertTriggerCompletion { get; set; }
|
||||
/// <summary>
|
||||
/// whether the start polarity should be switched from close to open
|
||||
/// </summary>
|
||||
bool InvertStartRecordCompletion { get; set; }
|
||||
/// <summary>
|
||||
/// Whether or not a shorted start should be ignored
|
||||
/// </summary>
|
||||
bool IgnoreShortedStartCompletion { get; set; }
|
||||
/// <summary>
|
||||
/// Whether or not a shorted trigger should be ignored
|
||||
/// </summary>
|
||||
bool IgnoreShortedTriggerCompletion { get; set; }
|
||||
/// <summary>
|
||||
/// Whether diagnostics should be a viewable step when executing test
|
||||
/// </summary>
|
||||
bool ViewDiagnostics { get; set; }
|
||||
/// <summary>
|
||||
/// whether verify channels should be a viewable step when executing test
|
||||
/// </summary>
|
||||
bool VerifyChannels { get; set; }
|
||||
|
||||
bool AutoVerifyChannels { get; set; }
|
||||
double AutoVerifyDelaySeconds { get; set; }
|
||||
/// <summary>
|
||||
/// overall recording mode of test
|
||||
/// Some DAS may not support the actual recording mode but may support a related recording
|
||||
/// mode (example circular buffer + UART versus circular buffer)
|
||||
/// </summary>
|
||||
RecordingModes RecordingMode { get; set; }
|
||||
/// <summary>
|
||||
/// samples per second for test as overall value
|
||||
/// Each DAS can have it's own rate so this is mostly just to control the rate for new das added to a test
|
||||
/// </summary>
|
||||
double SamplesPerSecondAggregate { get; set; }
|
||||
/// <summary>
|
||||
/// amount of data pre trigger that is requested in seconds
|
||||
/// </summary>
|
||||
double PreTriggerSeconds { get; set; }
|
||||
/// <summary>
|
||||
/// amount of data post trigger that is requested in seconds
|
||||
/// </summary>
|
||||
double PostTriggerSeconds { get; set; }
|
||||
/// <summary>
|
||||
/// number of events to record if recording mode supports multiple events
|
||||
/// </summary>
|
||||
int NumberOfEvents { get; set; }
|
||||
/// <summary>
|
||||
/// whether all channels are required to pass diagnostics for test execution
|
||||
/// </summary>
|
||||
bool StrictDiagnostics { get; set; }
|
||||
/// <summary>
|
||||
/// whether user confirmation is required on diagnostic errors discovered before
|
||||
/// test execution continues
|
||||
/// </summary>
|
||||
bool RequireUserConfirmationOnErrors { get; set; }
|
||||
/// <summary>
|
||||
/// whether to perform a Region of Interest (ROI) download as a unique step of test execution
|
||||
/// </summary>
|
||||
bool DoROIDownload { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include viewing region of interest (ROI) as a step of test execution
|
||||
/// </summary>
|
||||
bool ViewROIDownload { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include downloading all available data as a step of test execution
|
||||
/// </summary>
|
||||
bool DownloadAll { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include real time as a step of test execution
|
||||
/// </summary>
|
||||
bool ViewRealtime { get; set; }
|
||||
/// <summary>
|
||||
/// the number of plots to show in real time if viewing real time
|
||||
/// </summary>
|
||||
short DefaultNumberRealtimeGraphs { get; set; }
|
||||
BindingList<IRegionOfInterest> RegionsOfInterest { get; set; }
|
||||
/// <summary>
|
||||
/// the start of the region of interest (deprecated?)
|
||||
/// </summary>
|
||||
double ROIStart { get; set; }
|
||||
/// <summary>
|
||||
/// the end of the region of interest (deprecated?)
|
||||
/// </summary>
|
||||
double ROIEnd { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include viewing of all download data as a step of test execution
|
||||
/// </summary>
|
||||
bool ViewDownloadAll { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include export as a step of test execution
|
||||
/// </summary>
|
||||
bool ViewExport { get; set; }
|
||||
/// <summary>
|
||||
/// Bit mask of export formats to select in export step by default
|
||||
/// </summary>
|
||||
SupportedExportFormatBitFlags ExportFormats { get; set; }
|
||||
string LabDetails { get; set; }
|
||||
/// <summary>
|
||||
/// Whether lab details should be included as a part of test execution
|
||||
/// </summary>
|
||||
bool UseLabratoryDetails { get; set; }
|
||||
string CustomerDetails { get; set; }
|
||||
/// <summary>
|
||||
/// Whether customer details should be included as a part of test execution
|
||||
/// </summary>
|
||||
bool UseCustomerDetails { get; set; }
|
||||
/// <summary>
|
||||
/// Whether to allow test execution to continue when sensors in test are missing
|
||||
/// </summary>
|
||||
bool AllowMissingSensors { get; set; }
|
||||
/// <summary>
|
||||
/// whether a sensor with an ID is allowed to be assigned on a channel if the Id
|
||||
/// was not found on that channel
|
||||
/// </summary>
|
||||
bool AllowSensorIdToBlankChannel { get; set; }
|
||||
CalibrationBehaviors CalibrationBehavior { get; set; }
|
||||
/// <summary>
|
||||
/// whether test setup record should be synchronized with central server
|
||||
/// (deprecated)
|
||||
/// </summary>
|
||||
bool LocalOnly { get; set; }
|
||||
/// <summary>
|
||||
/// when test setup was last modified
|
||||
/// </summary>
|
||||
DateTime LastModified { get; set; }
|
||||
/// <summary>
|
||||
/// who last modified test setup
|
||||
/// </summary>
|
||||
string LastModifiedBy { get; set; }
|
||||
bool TurnOffExcitation { get; set; }
|
||||
/// <summary>
|
||||
/// whether to use EU levels to "trigger" channels in realtime viewer
|
||||
/// </summary>
|
||||
bool TriggerCheckRealtime { get; set; }
|
||||
/// <summary>
|
||||
/// Whether to include trigger check as a step in test execution
|
||||
/// </summary>
|
||||
bool TriggerCheckStep { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include post test diagnostics as a step in test execution
|
||||
/// </summary>
|
||||
bool PostTestDiagnosticsLevel { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// whether there's an expectation that there is a common status line between all DAS
|
||||
/// in test.
|
||||
/// </summary>
|
||||
bool CommonStatusLine { get; set; }
|
||||
bool SameAsDownloadFolder { get; set; }
|
||||
/// <summary>
|
||||
/// whether to include upload data as a step
|
||||
/// </summary>
|
||||
bool UploadData { get; set; }
|
||||
/// <summary>
|
||||
/// folder to upload data to
|
||||
/// [legacy, superseded by upload ini file]
|
||||
/// </summary>
|
||||
string UploadFolder { get; set; }
|
||||
/// <summary>
|
||||
/// whether to upload only export data files when uploading files
|
||||
/// </summary>
|
||||
bool UploadExportsOnly { get; set; }
|
||||
string Settings { get; set; }
|
||||
bool WarnOnFailedBattery { get; set; }
|
||||
/// <summary>
|
||||
/// whether test setup completion has been calculated yet or not
|
||||
/// If dirty is true it has not been calculated and needs to be
|
||||
/// </summary>
|
||||
bool Dirty { get; set; }
|
||||
/// <summary>
|
||||
/// whether the test setup is complete and ready to run
|
||||
/// [dependent on Dirty]
|
||||
/// </summary>
|
||||
bool IsComplete { get; set; }
|
||||
/// <summary>
|
||||
/// any warnings or errors known in test setup, stored to avoid needing to calculate when retrieving all setups
|
||||
/// </summary>
|
||||
string ErrorMessage { get; set; }
|
||||
string TestEngineerDetails { get; set; }
|
||||
/// <summary>
|
||||
/// whether to use test engineer details in test execution
|
||||
/// </summary>
|
||||
bool UseTestEngineerDetails { get; set; }
|
||||
byte[] TagsBlobBytes { get; set; }
|
||||
/// <summary>
|
||||
/// whether units in the test should be auto armed
|
||||
/// </summary>
|
||||
bool DoAutoArm { get; set; }
|
||||
bool DoEnableRepeat { get; set; }
|
||||
/// <summary>
|
||||
/// Whether test is a checkout test
|
||||
/// this has multiple internal meanings including whether strict diagnostics are used or not, whether data
|
||||
/// should be collected from sensors or not, etc
|
||||
/// this should generally be false
|
||||
/// </summary>
|
||||
bool CheckoutMode { get; set; }
|
||||
/// <summary>
|
||||
/// Instrumentation Setup File used to create test setup, if relevant
|
||||
/// </summary>
|
||||
string ISFFile { get; set; }
|
||||
bool QuitTestWithoutWarning { get; set; }
|
||||
bool NotAllChannelsRealTime { get; set; }
|
||||
bool NotAllChannelsViewer { get; set; }
|
||||
bool SuppressMissingSensorsWarning { get; set; }
|
||||
bool DoStreaming { get; set; }
|
||||
ClockSyncProfile ClockSyncProfileMaster { get; set; }
|
||||
ClockSyncProfile ClockSyncProfileSlave { get; set; }
|
||||
List<IExtraProperty> ExtraProperties { get; set; }
|
||||
bool MeasureSquibResistancesStep { get; set; }
|
||||
string TestSetupUniqueId { get; set; }
|
||||
|
||||
bool LowgLevelTriggerOn { get; set; }
|
||||
bool LowgLevelTriggerOnX { get; set; }
|
||||
bool LowgLevelTriggerOnY { get; set; }
|
||||
bool LowgLevelTriggerOnZ { get; set; }
|
||||
bool HighgLevelTriggerOn { get; set; }
|
||||
|
||||
bool HighgLevelTriggerOnX { get; set; }
|
||||
bool HighgLevelTriggerOnY { get; set; }
|
||||
bool HighgLevelTriggerOnZ { get; set; }
|
||||
bool AngularAccelLevelTriggerOn { get; set; }
|
||||
bool AngularAccelLevelTriggerOnX { get; set; }
|
||||
bool AngularAccelLevelTriggerOnY { get; set; }
|
||||
bool AngularAccelLevelTriggerOnZ { get; set; }
|
||||
bool AngularRateLevelTriggerOn { get; set; }
|
||||
bool AngularRateLevelTriggerOnX { get; set; }
|
||||
bool AngularRateLevelTriggerOnY { get; set; }
|
||||
bool AngularRateLevelTriggerOnZ { get; set; }
|
||||
double LowgLinearLevelTriggerX { get; set; }
|
||||
double LowgLinearLevelTriggerY { get; set; }
|
||||
double LowgLinearLevelTriggerZ { get; set; }
|
||||
double HighgLinearLevelTriggerX { get; set; }
|
||||
double HighgLinearLevelTriggerY { get; set; }
|
||||
double HighgLinearLevelTriggerZ { get; set; }
|
||||
double AngularRateLevelTriggerX { get; set; }
|
||||
double AngularRateLevelTriggerY { get; set; }
|
||||
double AngularRateLevelTriggerZ { get; set; }
|
||||
double AngularAccelLevelTriggerX { get; set; }
|
||||
double AngularAccelLevelTriggerY { get; set; }
|
||||
double AngularAccelLevelTriggerZ { get; set; }
|
||||
bool HumidityLevelTriggerOn { get; set; }
|
||||
bool PressureLevelTriggerOn { get; set; }
|
||||
bool TemperatureLevelTriggerOn { get; set; }
|
||||
double HumidityLevelTriggerBelow { get; set; }
|
||||
double HumidityLevelTriggerAbove { get; set; }
|
||||
double PressureLevelTriggerBelow { get; set; }
|
||||
double PressureLevelTriggerAbove { get; set; }
|
||||
double TemperatureLevelTriggerBelow { get; set; }
|
||||
double TemperatureLevelTriggerAbove { get; set; }
|
||||
double LowgLinearAccRate { get; set; }
|
||||
double HighgLinearAccRate { get; set; }
|
||||
double AngularRate { get; set; }
|
||||
double TemperatureHumidityPressureRate { get; set; }
|
||||
bool BatterySaverModeOn { get; set; }
|
||||
bool WakeUpAndArmTriggerOn { get; set; }
|
||||
WakeupTriggers WakeUpTrigger { get; set; }
|
||||
int WakeUpMagnetTimeout { get; set; }
|
||||
int WakeUpMotionTimeout { get; set; }
|
||||
DateTime WakeUpTimeSessionStart { get; set; }
|
||||
TimeSpan WakeUpTimeDuration { get; set; }
|
||||
bool TimedIntervalTriggerOn { get; set; }
|
||||
int IntervalBetweenEventStartsMinutes { get; set; }
|
||||
TimeUnitTypeEnum TimedIntervalUnits { get; set; }
|
||||
double TimedIntervalDuration { get; set; }
|
||||
double TimedIntervalEvents { get; set; }
|
||||
bool RTCScheduleTriggerOn { get; set; }
|
||||
DateTime RTCScheduleStartDateTime { get; set; }
|
||||
TimeSpan RTCScheduleDuration { get; set; }
|
||||
bool StartWithEvent { get; set; }
|
||||
void InitializeFromDefaults(CalibrationBehaviors calBehavior,
|
||||
RecordingModes recordingMode, double preTriggerSeconds, double postTriggerSeconds,
|
||||
int numEvents);
|
||||
bool AlignUDPToPPS { get; set; }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
using DTS.Common.Base;
|
||||
|
||||
namespace DTS.Common.Interface.TestSetups.TestSetupsList
|
||||
{
|
||||
public interface ITestSetupsListView : IBaseView { }
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
using DTS.Common.Base;
|
||||
using DTS.Common.Interface.Pagination;
|
||||
|
||||
namespace DTS.Common.Interface.TestSetups.TestSetupsList
|
||||
{
|
||||
public interface ITestSetupsListViewModel : IBaseViewModel, IFilterableListView
|
||||
{
|
||||
ITestSetupsListView View { get; set; }
|
||||
ITestSetup[] TestSetups { get; set; }
|
||||
void SetTestSetups(ITestSetup[] allTestSetups);
|
||||
void Sort(object sortBy, bool bColumnClick);
|
||||
void Unset();
|
||||
void Filter(string currentFilter);
|
||||
void MouseDoubleClick(int index);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,369 @@
|
||||
using DTS.Common.Interface.DASFactory;
|
||||
using DTS.Common.Interface.DataRecorders;
|
||||
using DTS.Common.Interface.Groups.GroupList;
|
||||
using DTS.Common.Interface.Sensors;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace DTS.Common.Interface.TestSetups.TestSetupsList
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// this is an interface to the Heavy Test Setup class
|
||||
/// </summary>
|
||||
public interface ITestTemplate : ITestSetup
|
||||
{
|
||||
bool LowgLevelTriggersMixed { get; set; }
|
||||
double LowgLinearLevelTriggerAggregate { get; set; }
|
||||
bool HighgLevelTriggersMixed { get; set; }
|
||||
double HighgLinearLevelTriggerAggregate { get; set; }
|
||||
bool AngularAccelLevelTriggersMixed { get; set; }
|
||||
double AngularAccelLevelTriggerAggregate { get; set; }
|
||||
bool AngularRateLevelTriggersMixed { get; set; }
|
||||
double AngularRateLevelTriggerAggregate { get; set; }
|
||||
/// <summary>
|
||||
/// property used to indicate that the test is destructive or impact and should set the first use date
|
||||
/// of any relevant sensors or DAS
|
||||
/// 15524 DAS "First Use Date"
|
||||
/// 44625 make it optional property , null shows it's not selected
|
||||
/// note: this property is not serialized with the test setup, it's a run-time set property when
|
||||
/// running the test
|
||||
/// </summary>
|
||||
bool? DestructiveTest { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// removes the ids for this test template creating a copy without the id associations
|
||||
/// </summary>
|
||||
void CreateCopy();
|
||||
|
||||
void ClearHardware();
|
||||
|
||||
/// <summary>
|
||||
/// returns true whenever the test template is a quick test setup, false otherwise
|
||||
/// </summary>
|
||||
bool QuickSensorCheck { get; set; }
|
||||
|
||||
|
||||
#region Properties
|
||||
bool ExpressTestSetup { get; set; }
|
||||
bool PreserveTestId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// true if the test objects and other fields have already been loaded from the database, false otherwise
|
||||
/// </summary>
|
||||
bool IsLoaded { get; }
|
||||
|
||||
void SetIsLoaded(bool bIsLoaded);
|
||||
|
||||
bool ArmCheckListStep { get; set; }
|
||||
bool CheckListBatteryVoltageCheck { get; set; }
|
||||
bool CheckListInputVoltageCheck { get; set; }
|
||||
bool CheckListSquibResistanceCheck { get; set; }
|
||||
bool CheckListSensorIdCheck { get; set; }
|
||||
bool CheckListRequirePass { get; set; }
|
||||
bool CheckListTiltSensorCheck { get; set; }
|
||||
bool CheckListTemperatureCheck { get; set; }
|
||||
bool CheckListClockSyncCheck { get; set; }
|
||||
|
||||
Dictionary<string, double> FilterLookup { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// excitation warmup time
|
||||
/// can be defined at test level, test object level, (and maybe at hardware or channel level?)
|
||||
/// if defined here, we return it right away, otherwise we pass it to the max of the test objets
|
||||
/// </summary>
|
||||
int ExcitationWarmupTimeMS { get; set; }
|
||||
|
||||
int GraphCount { get; }
|
||||
|
||||
|
||||
string SetupFile { get; set; }
|
||||
string TestId { get; set; }
|
||||
string TestIdNode { get; set; }
|
||||
|
||||
string TestDirectory { get; set; }
|
||||
string OriginalTestDirectory { get; set; }
|
||||
string SampleRateText { get; set; }
|
||||
|
||||
List<string> CheckedDASList { get; set; }
|
||||
bool GroupsStepValid { get; set; }
|
||||
|
||||
|
||||
//assumes list is in order and sets display orders accordingly
|
||||
void SetGroupsListOrder();
|
||||
|
||||
double MaxSampleRate { get; }
|
||||
double MinSampleRate { get; }
|
||||
string DownloadFolder { get; set; }
|
||||
string ExportFolder { get; set; }
|
||||
DateTime TestTime { get; set; }
|
||||
int ChannelCount { get; }
|
||||
int IncludedChannelCount { get; }
|
||||
#endregion Properties
|
||||
|
||||
/// <summary>
|
||||
/// if you use rename serial number method to create a new test setup, we have to go and recreate the groups.
|
||||
/// groups are supposed to be unique to a test setup, and we don't want them to unintentionally share groups
|
||||
/// <param name="bAddedGroups">whether operating on static or dynamic groups</param>
|
||||
/// </summary>
|
||||
void Rename(bool bAddedGroups);
|
||||
|
||||
int GetMaxDisplayOrder();
|
||||
|
||||
|
||||
#region LEVEL_TRIGGER
|
||||
|
||||
/// <summary>
|
||||
/// replaces any level triggers that have a specific id, with another
|
||||
/// brand new id
|
||||
/// </summary>
|
||||
/// <param name="oldId"></param>
|
||||
/// <param name="newId"></param>
|
||||
void ReplaceLevelTriggerChannel(string oldId, string newId);
|
||||
|
||||
/// <summary>
|
||||
/// scans through all level triggers, looks for any level triggers that might be associated with an old group serial number
|
||||
/// and replaces those references with the new group serial number
|
||||
/// </summary>
|
||||
/// <param name="oldGroupSerial"></param>
|
||||
/// <param name="newGroupSerial"></param>
|
||||
void ReplaceLevelTriggerChannelGroupMapping(string oldGroupSerial, string newGroupSerial);
|
||||
|
||||
/// <summary>
|
||||
/// updates the channel settings for groups which have changed serial numbers [rename/clone group]
|
||||
/// 8404 Copy all channel parameters/settings/level triggers/graphs when cloning a test setup
|
||||
/// </summary>
|
||||
/// <param name="oldIdToNewIdLookup"></param>
|
||||
/// <param name="oldGroupSnToNewGroupSn"></param>
|
||||
void ReplaceChannelSetting(Dictionary<string, string> oldIdToNewIdLookup, Dictionary<string, string> oldGroupSnToNewGroupSn);
|
||||
|
||||
void ReplaceLevelTriggerChannel(Dictionary<string, string> oldIdToNewIdLookup, Dictionary<string, string> oldGroupSnToNewGroupSn);
|
||||
|
||||
void RenameLevelTriggerChannels(string oldName, string newName);
|
||||
|
||||
void RemoveImpossibleLevelTriggers();
|
||||
#endregion LEVEL_TRIGGER
|
||||
|
||||
#region Sensor
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// get sensor from sensor db again (but preserving custom values such as range/polarity/CFC/etc)
|
||||
/// note, test objects already get sensors from from db every time. we hold onto them here, I guess for efficiency, but we could get them fresh every time as well
|
||||
/// </summary>
|
||||
void RefreshSensorsFromDb();
|
||||
|
||||
/// <summary>
|
||||
/// sets a channel to be disabled
|
||||
/// disabled channels don't appear in run test
|
||||
/// </summary>
|
||||
/// <param name="groupName"></param>
|
||||
/// <param name="channelName"></param>
|
||||
/// <param name="disabled"></param>
|
||||
void SetDisabled(string groupName, string channelName, bool disabled);
|
||||
|
||||
//public SensorData GetSensor(IGroupChannel groupChannel)
|
||||
//SensorData GetSensor(string serialNumber, string testObjectSerial, string channelName)
|
||||
|
||||
// FB5438 & FB5023
|
||||
void RemoveSensor(string sensorserialnumber, string testobjectserial, string channelname);
|
||||
#endregion Sensor
|
||||
|
||||
#region XML
|
||||
/// <summary>
|
||||
/// writes a test setup out to xml
|
||||
/// </summary>
|
||||
/// <param name="writer"></param>
|
||||
void WriteXML(ref System.Xml.XmlWriter writer);
|
||||
#endregion XML
|
||||
|
||||
void ReloadGroupsMemoryOnly();
|
||||
|
||||
/// <summary>
|
||||
/// reloads static groups from list
|
||||
/// </summary>
|
||||
void ReloadGroups(bool bMemoryOnly);
|
||||
|
||||
bool CheckForIEPE();
|
||||
/// <summary>
|
||||
/// returns whether there is a TOM in the test setup or not
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
bool CheckForTOM();
|
||||
|
||||
/// <summary>
|
||||
/// returns whether there is a TOM with channels in use in the test setup or not
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
bool CheckForTOMInTest();
|
||||
|
||||
/// <summary>
|
||||
/// returns whether there is an analog channel in the test or not
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
bool CheckForAnalog();
|
||||
|
||||
/// <summary>
|
||||
/// sets the dirty flag
|
||||
/// does NOT set the flag in the database, so this should only be called when the flag needs to be set in memory
|
||||
/// (for instance during initialization)
|
||||
/// </summary>
|
||||
/// <param name="bDirty"></param>
|
||||
void SetIsDirty(bool bDirty);
|
||||
|
||||
/// <summary>
|
||||
/// sets the complete flag
|
||||
/// does not set the flag in the database, so this should only be called when the flag needs to be set in memory
|
||||
/// (for instance during initialization)
|
||||
/// </summary>
|
||||
/// <param name="bComplete"></param>
|
||||
void SetIsComplete(bool bComplete);
|
||||
|
||||
/// <summary>
|
||||
/// sets the completion error message.
|
||||
/// does not set the field in the db, so this should only be called when the information nets to be set in memory and not the db
|
||||
/// (for instance during initialization)
|
||||
/// </summary>
|
||||
/// <param name="msg"></param>
|
||||
void SetCompletionErrorMessage(string msg);
|
||||
double GetSampleRateForHardware(string h);
|
||||
|
||||
float GetAAFForHardware(IDASCommunication das);
|
||||
|
||||
float GetAAFForHardware(IDASCommunication das, int sps);
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// returns the Anti-Alias Filter (AAF) for the DAS in question
|
||||
/// this is dependent on the sample rate for the hardware and a ratio in the config file
|
||||
/// (RealtimeSampleRateAAFilterRatio)
|
||||
/// </summary>
|
||||
/// <param name="das"></param>
|
||||
/// <returns></returns>
|
||||
float GetRealtimeAAFForHardware(IDASCommunication idas, double samplerate);
|
||||
|
||||
void SetDefaultSetupFile();
|
||||
|
||||
/// <summary>
|
||||
/// calculates whether the test setup is complete or not
|
||||
/// will cause the test setup to be loaded if it is not yet
|
||||
/// does not unload the test setup
|
||||
/// </summary>
|
||||
void CalculateIsComplete(bool bSetInDb = true);
|
||||
|
||||
void CheckSensorCalDates();
|
||||
|
||||
/// <summary>
|
||||
/// marks a test setup as unchecked by setting the dirty flag, which means the next time completion is checked it will be calculated again
|
||||
/// this function will change that flag in the database immediately
|
||||
/// </summary>
|
||||
void MarkIsCompleteUnchecked(bool skipMemoryCheck = false);
|
||||
|
||||
void ClearOverrides();
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// frees up the memory assigned during Load, this includes channels, groups, meta data, etc
|
||||
/// various things may cause us to load the information and hold the information for some setups,
|
||||
/// but in general we want to unload it if we don't need it
|
||||
/// </summary>
|
||||
void UnLoad();
|
||||
|
||||
/// <summary>
|
||||
/// signifies if the test setup is being used for a quick checkout
|
||||
/// quick checkout tests are not stored and are run time only
|
||||
/// </summary>
|
||||
bool IsQuickCheckout { get; set; }
|
||||
|
||||
void Load(bool fromDB = false);
|
||||
|
||||
/// <summary>
|
||||
/// All items from db are updated in our cache
|
||||
/// </summary>
|
||||
void UpdateFromDb();
|
||||
|
||||
IDASHardware[] GetHardwareFromDb();
|
||||
|
||||
IDASHardware[] GetAllCachedHardware2();
|
||||
|
||||
ISensorCalibration[] GetCachedSensorCalibrations();
|
||||
|
||||
ISensorData[] GetCachedSensors();
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// loads all the information for the test setup from tables in the db
|
||||
/// we do this so that we can keep the minimal information on hand until we need it
|
||||
/// </summary>
|
||||
void LoadFromDb();
|
||||
|
||||
string GetTestIdNode();
|
||||
|
||||
/// <summary>
|
||||
/// gets a serialized version of the settings table
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
string GetSettings();
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// loads values from a serialized string into the settings table
|
||||
/// </summary>
|
||||
/// <param name="s"></param>
|
||||
void LoadSettings(string s);
|
||||
|
||||
bool CheckListTriggerStartCheck { get; set; }
|
||||
|
||||
void FilterTestObjects(string term);
|
||||
|
||||
int GetAbsoluteNumber(string serial, int dasChannelNumber);
|
||||
|
||||
double GetPreTriggerSeconds(string serial);
|
||||
|
||||
double GetPostTriggerSeconds(string serial);
|
||||
|
||||
int GetNumberOfRealtimeSupportedChannels();
|
||||
|
||||
/// <summary>
|
||||
/// for some reason it seems custom and lab details are held in two different areas, in meta deta and in the custom/lab detail objects
|
||||
/// this function merely synchronizes the meta data with the objects
|
||||
/// </summary>
|
||||
void SynchronizeTestMetaData();
|
||||
|
||||
|
||||
#region CalculatedChannels
|
||||
|
||||
void UpdateCalculatedChannelId(string[] names, int[] newIds);
|
||||
|
||||
void UpdateCalculatedChannelId(string name, int newId);
|
||||
|
||||
void RemoveImpossibleCalculatedChannels();
|
||||
|
||||
void ReplaceCalculatedChannel(Dictionary<string, string> oldIdToNewIdLookup);
|
||||
|
||||
void RenameCalculatedChannels(string oldName, string newName);
|
||||
|
||||
#endregion CalculatedChannels
|
||||
|
||||
void SetHardwareOverride(string hid, bool bAdd);
|
||||
|
||||
/// <summary>
|
||||
/// takes a dynamic group in the test and replaces it with a snapshot of the static group
|
||||
/// also updates calculated channels and level trigger channels
|
||||
/// 15400 Group Push/Pull should allow the LT to be preserved in the Test Setup regardless of push/pull
|
||||
/// </summary>
|
||||
/// <param name="_updateGroup"></param>
|
||||
/// <param name="staticGroup"></param>
|
||||
void UpdateDynamicGroupFromStaticGroup(IGroup _updateGroup, IGroup staticGroup);
|
||||
|
||||
#region MetaData
|
||||
|
||||
// FB14362 This method will keep the _metaDataLookup dictionary updated to prevent the missing data from database.
|
||||
void UpdateMetaDataLookupKey(char oldKey, char newKey);
|
||||
|
||||
#endregion MetaData
|
||||
|
||||
void Rename(string newName);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user