Implement PowerUp Sequencing
bindings to datagridview
This commit is contained in:
@@ -63,9 +63,12 @@ namespace HTOLHAST
|
||||
Agilent34970a DAQ;
|
||||
Project Project;
|
||||
List<SwitchMatrix> switchMatrix;
|
||||
List<PowerUpSequence> powerUpSequences;
|
||||
List<PowerUpSequence> powerDownSequences;
|
||||
|
||||
BindingList<PowerSequence> powerUpSequences;
|
||||
BindingSource bindingSourcePowerUpSequence = new BindingSource();
|
||||
|
||||
BindingList<PowerSequence> powerDownSequences;
|
||||
BindingSource bindingSourcePowerDownSequence = new BindingSource();
|
||||
|
||||
BindingList<Measurement> measurements;
|
||||
BindingSource bindingSourceMeasurements = new BindingSource();
|
||||
|
||||
@@ -105,10 +108,21 @@ namespace HTOLHAST
|
||||
InitDgvPowersupply();
|
||||
InitDgvHeaderSetting();
|
||||
InitDgvMeasurements();
|
||||
InitDgvPowerSequences();
|
||||
InitSwitchMatrix();
|
||||
InitializePowerupSequence();
|
||||
|
||||
}
|
||||
|
||||
private void InitDgvPowerSequences()
|
||||
{
|
||||
// Bind powerup sequences to datagridviews
|
||||
bindingSourcePowerUpSequence.DataSource = powerUpSequences;
|
||||
dgvPowerUpSequence.DataSource = bindingSourcePowerUpSequence;
|
||||
|
||||
bindingSourcePowerDownSequence.DataSource = powerDownSequences;
|
||||
dgvPowerDownSequence.DataSource = bindingSourcePowerDownSequence;
|
||||
}
|
||||
#region INITIALIZATION
|
||||
private void InitializeButtons()
|
||||
{
|
||||
@@ -202,20 +216,20 @@ namespace HTOLHAST
|
||||
}
|
||||
private void InitializePowerupSequence()
|
||||
{
|
||||
powerUpSequences = new List<PowerUpSequence>()
|
||||
{ new PowerUpSequence { Channel = 1, Delay = 100},
|
||||
new PowerUpSequence { Channel = 2, Delay = 100},
|
||||
new PowerUpSequence { Channel = 3, Delay = 100},
|
||||
new PowerUpSequence { Channel = 4, Delay = 100}
|
||||
powerUpSequences = new BindingList<PowerSequence>()
|
||||
{ new PowerSequence { Channel = 1, Delay = 1},
|
||||
new PowerSequence { Channel = 2, Delay = 1},
|
||||
new PowerSequence { Channel = 3, Delay = 1},
|
||||
new PowerSequence { Channel = 4, Delay = 1}
|
||||
};
|
||||
}
|
||||
private void InitializePowerDownSequence()
|
||||
{
|
||||
powerDownSequences = new List<PowerUpSequence>()
|
||||
{ new PowerUpSequence { Channel = 1, Delay = 1},
|
||||
new PowerUpSequence { Channel = 2, Delay = 1},
|
||||
new PowerUpSequence { Channel = 3, Delay = 1},
|
||||
new PowerUpSequence { Channel = 4, Delay = 1}
|
||||
powerDownSequences = new BindingList<PowerSequence>()
|
||||
{ new PowerSequence { Channel = 4, Delay = 1},
|
||||
new PowerSequence { Channel = 3, Delay = 1},
|
||||
new PowerSequence { Channel = 2, Delay = 1},
|
||||
new PowerSequence { Channel = 1, Delay = 1}
|
||||
};
|
||||
}
|
||||
public void InitializeInstruments()
|
||||
@@ -436,12 +450,12 @@ namespace HTOLHAST
|
||||
// 2025-01-09, 1, AGILENT, HEADER1, 1.0, -
|
||||
}
|
||||
|
||||
private void PowerUpPSU(List<PowerUpSequence> powerUpsequences)
|
||||
private void PowerUpPSU(BindingList<PowerSequence> powerUpsequences)
|
||||
{
|
||||
PSU1.PowerUpSequence(powerUpsequences);
|
||||
PSU1.SetGeneralOutputState(true);
|
||||
}
|
||||
private void PowerDownPSU(List<PowerUpSequence> powerUpsequences)
|
||||
private void PowerDownPSU(BindingList<PowerSequence> powerUpsequences)
|
||||
{
|
||||
PSU1.PowerDownSequence(powerUpsequences);
|
||||
PSU1.SetGeneralOutputState(false);
|
||||
|
||||
Reference in New Issue
Block a user