Commit e6a071a8 authored by 潘栩锋's avatar 潘栩锋 🚴

测试完成,吹膜扫描. 自动计算膜距离选择角度 完成

parent dafdd73a
...@@ -122,15 +122,19 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -122,15 +122,19 @@ namespace FLY.Thick.BlowingScan.UI.Client
#region 自动 #region 自动
/// <summary> /// <summary>
/// 旋转架转动角度 查找范围 ±25° /// 旋转架转动角度 查找范围 50°
/// </summary> /// </summary>
public int RAngleRange { get; set; } = 25; public int RAngleRange { get; set; } = 90;
/// <summary> /// <summary>
/// 旋转架转动角度 查找范围 ±10m /// 旋转架转动角度 查找范围 20m
/// </summary> /// </summary>
public int FilmLengthRange { get; set; } = 10; public int FilmLengthRange { get; set; } = 20;
/// <summary>
/// 查找过程信息
/// </summary>
public string SearchMsg { get; private set; }
#endregion #endregion
BlowingAngleDetect mAngleDetect = new BlowingAngleDetect(); BlowingAngleDetect mAngleDetect = new BlowingAngleDetect();
...@@ -149,7 +153,7 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -149,7 +153,7 @@ namespace FLY.Thick.BlowingScan.UI.Client
return (LastBM - (ScanInfoList.Count() - 1)); return (LastBM - (ScanInfoList.Count() - 1));
int markno = idx+ (LastBM - (ScanInfoList.Count() - 1)); int markno = idx + (LastBM - (ScanInfoList.Count() - 1));
return markno; return markno;
} }
...@@ -277,7 +281,7 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -277,7 +281,7 @@ namespace FLY.Thick.BlowingScan.UI.Client
IsStep2Ing = false; IsStep2Ing = false;
return; return;
} }
GetSolveEquation(RAngle, FilmLength); GetSolveEquation();
ClearAllResult(); ClearAllResult();
MarkNo1.Refresh(); MarkNo1.Refresh();
...@@ -299,19 +303,338 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -299,19 +303,338 @@ namespace FLY.Thick.BlowingScan.UI.Client
} }
int idx1 = GetIdxFromRList(MarkNo1.Number); int idx1 = GetIdxFromRList(MarkNo1.Number);
int idx2 = GetIdxFromRList(MarkNo2.Number); int idx2 = GetIdxFromRList(MarkNo2.Number);
if (idx1 >= 0 && idx2>=0 && idx1!= idx2) if (idx1 >= 0 && idx2 >= 0 && idx1 != idx2)
{ {
//TODO if(autoSearchRAngle(idx1, idx2, out double bestParam))
double step = RAngleRange*2 / 10; {
RAngle = bestParam;
GetSolveEquation();
ClearAllResult();
MarkNo1.Refresh();
MarkNo2.Refresh();
}
}
IsStep2Ing = false;
}
bool autoSearchRAngle(int idx1, int idx2,out double bestRa)
{
ParamRs.Clear();
double minParam = RAngle - RAngleRange / 2;
double maxParam = RAngle + RAngleRange / 2;
if (minParam < 200)
minParam = 200;
if (maxParam > 360)
maxParam = 360;
GetSolveEquation(RAngle, FilmLength); double bestParam = RAngle;
double bestR;
searchMsgHeader = "";
GetSolveEquation(RAngle, FilmLength, idx1);
GetSolveEquation(RAngle, FilmLength, idx2);
TrySolveEquationAndGetR(idx1, idx2, out bestR);
searchMsgHeader = $"最佳旋转角度={bestParam:F1}°相关性={bestR:F5}";
while (true)
{
double step = (maxParam - minParam) / 8;
if (step < 0.1)
step = 0.1;
if (!SearchParam(minParam, maxParam, step, 0.05, out bestParam, out bestR,
(double par, out double r) =>
{
//GetSolveEquation(par, FilmLength, idx1);
//GetSolveEquation(par, FilmLength, idx2);
//获取角度信息
for (int i = 0; i < mBufList.Count(); i++)
{
GetSolveEquation(par, FilmLength, i);
}
return TrySolveEquationAndGetR(idx1, idx2, out r);
})
)
{
//异常停止
bestRa = bestParam;
return false;
}
searchMsgHeader = $"最佳旋转角度={bestParam:F1}°相关性={bestR:F5}";
if (step <= 0.1)
{
//查找完成
bestRa = bestParam;
return true;
}
minParam = bestParam - step * 2;
maxParam = bestParam + step * 2;
}
}
/// <summary>
/// 自动查找膜距离
/// </summary>
public void StepAutoSearchFilmLength()
{
IsStep2Ing = true;
if (mBufList == null)
{
IsStep2Ing = false;
return;
}
int idx1 = GetIdxFromRList(MarkNo1.Number);
int idx2 = GetIdxFromRList(MarkNo2.Number);
if (idx1 >= 0 && idx2 >= 0 && idx1 != idx2)
{
if(autoSearchFilmLength(idx1, idx2, out double bestParam))
{
FilmLength = bestParam;
GetSolveEquation();
ClearAllResult(); ClearAllResult();
double r;
bool ret = TrySolveEquationAndGetR(idx1, idx2, out r);
MarkNo1.Refresh();
MarkNo2.Refresh();
}
}
IsStep2Ing = false;
}
bool autoSearchFilmLength(int idx1, int idx2, out double bestFl)
{
ParamRs.Clear();
double minParam = FilmLength - FilmLengthRange / 2;
double maxParam = FilmLength + FilmLengthRange / 2;
if (minParam < 5)
minParam = 5;
if (maxParam > 50)
maxParam = 50;
double bestParam = FilmLength;
double bestR;
searchMsgHeader = "";
GetSolveEquation(RAngle, bestParam, idx1);
GetSolveEquation(RAngle, bestParam, idx2);
TrySolveEquationAndGetR(idx1, idx2, out bestR);
searchMsgHeader = $"最佳膜距离={bestParam:F1}m 相关性={bestR:F5}";
while (true)
{
double step = (maxParam - minParam) / 8;
if (step < 0.1)
step = 0.1;
if (!SearchParam(minParam, maxParam, step, 0.05, out bestParam, out bestR,
(double par, out double r) =>
{
//GetSolveEquation(RAngle,par, SearchIdx1);
//GetSolveEquation(RAngle,par, SearchIdx2);
//获取角度信息
for (int i = 0; i < mBufList.Count(); i++)
{
GetSolveEquation(RAngle, par, i);
}
return TrySolveEquationAndGetR(idx1, idx2, out r);
})
)
{
//异常停止
bestFl = bestParam;
return false;
}
searchMsgHeader = $"最佳膜距离={bestParam:F1}m 相关性={bestR:F5}";
if (step <= 0.1)
{
//查找完成
bestFl = bestParam;
return true;
}
minParam = bestParam - step * 2;
maxParam = bestParam + step * 2;
}
}
/// <summary>
/// 自动查找全部参数
/// </summary>
public void StepAutoSearchParams()
{
IsStep2Ing = true;
if (mBufList == null)
{
IsStep2Ing = false;
return;
}
int lastIdx = ScanInfoList.Count() - 1;
List<Range> sameDirScanInfoIdxs = new List<Range>();
//必须有个方向切换点
for (int i = 0; i < ScanInfoList.Count(); i++)
{
int idx = lastIdx - i;
var direction = ScanInfoList[idx].Direction;
if (direction != DIRECTION.FIX)
{
if (sameDirScanInfoIdxs.Count() == 0)
sameDirScanInfoIdxs.Add(new Range() { Begin = idx, End = idx });
else
{
Range range = sameDirScanInfoIdxs.Last();
int idxBegin = range.Begin;
if (ScanInfoList[idxBegin].Direction == direction)
{
range.Begin = idx;
}
else
{
//另一个方向
sameDirScanInfoIdxs.Add(new Range() { Begin = idx, End = idx });
}
}
}
}
if (sameDirScanInfoIdxs.Count < 3)
{
SearchMsg = "查找失败!!旋转次数<3";
goto _end;
}
int IdxOfSameDirRangeForSearchRAngle = -1;
int IdxOfSameDirRangeForSearchFilmLength = -1;
int minInfoCnt = SolveCnt * 2+2;
for (int i = 1; i < sameDirScanInfoIdxs.Count - 1; i++)
{
if (sameDirScanInfoIdxs[i].Width > minInfoCnt)
{
//合符要求
if (IdxOfSameDirRangeForSearchRAngle == -1)
{
IdxOfSameDirRangeForSearchRAngle = i;
} }
else
{
IdxOfSameDirRangeForSearchFilmLength = i;
break;
}
}
}
if (IdxOfSameDirRangeForSearchFilmLength == -1)
{
SearchMsg = $"查找失败!!不能找到连续2次 在相同旋转内 扫描次数大于 {minInfoCnt}";
goto _end;
}
int idx1 = sameDirScanInfoIdxs[IdxOfSameDirRangeForSearchRAngle].Mid ;
int idx2 = sameDirScanInfoIdxs[IdxOfSameDirRangeForSearchRAngle].Mid + SolveCnt-1;
if (!autoSearchRAngle(idx1, idx2, out double bestRa))
{
SearchMsg = $"查找失败!!旋转角度查找失败";
goto _end;
}
RAngle = bestRa;
idx1 = sameDirScanInfoIdxs[IdxOfSameDirRangeForSearchRAngle].Mid + SolveCnt / 2;
idx2 = sameDirScanInfoIdxs[IdxOfSameDirRangeForSearchFilmLength].Mid + SolveCnt / 2;
if (!autoSearchFilmLength(idx1, idx2, out double bestFl))
{
SearchMsg = $"查找失败!!膜距离查找失败";
goto _end;
}
FilmLength = bestFl;
GetSolveEquation();
ClearAllResult();
MarkNo1.Refresh();
MarkNo2.Refresh();
MarkNo1.Number = GetMarkNoFromRList(idx2);
MarkNo2.Number = GetMarkNoFromRList(idx1);
_end:
IsStep2Ing = false; IsStep2Ing = false;
} }
public class ParamR
{
public double Param;
public double R;
public ParamR(double par, double r)
{
Param = par;
R = r;
}
public override string ToString()
{
return $"{Param:F2}:R={R:F5}";
}
}
/// <summary>
/// 旋转角度查找过程!!!
/// </summary>
public List<ParamR> ParamRs { get; set; } = new List<ParamR>();
delegate bool GetRHandler(double param, out double r);
string searchMsgHeader;
/// <summary>
/// 给定范围,步距,查找最大相关性时的旋转角度
/// 中间过程记录在RaRs
/// </summary>
/// <param name="minPar">参数最小值</param>
/// <param name="maxPar">参数最大值</param>
/// <param name="step">步距</param>
/// <param name="minStep">最小步距</param>
/// <param name="bestPar">最佳参数</param>
/// <param name="getR">更新参数解方程且获取相关性</param>
/// <returns>不能解方程返回 false</returns>
bool SearchParam(double minPar, double maxPar, double step, double minStep, out double bestPar, out double bestR, GetRHandler getR)
{
bestPar = 0;
bestR = -1;
List<ParamR> parList = new List<ParamR>();
for (double par = minPar; par <= maxPar; par += step)
{
var rar = ParamRs.Find(_rar => Math.Abs(_rar.Param - par) < minStep);
if (rar != null)
{
//已经测试过!!!!
parList.Add(rar);
continue;
}
double r;
bool ret = getR(par, out r);
if (ret)
{
parList.Add(new ParamR(par, r));
}
SearchMsg = searchMsgHeader + $"| 参数:{par:F1} 相关性={r:F5}";
}
if (parList.Count() == 0)
return false;
//找到最大值
{
double r = parList.Max(rar => rar.R);
bestR = r;
bestPar = parList.Find(_r => _r.R == r).Param;
}
//把列表插入到 RaRs
foreach (var rar in parList)
{
if (ParamRs.Find(_rar => _rar.Param == rar.Param) == null)
{
ParamRs.Add(rar);
}
}
ParamRs.Sort((rar1, rar2) => { return rar1.Param.CompareTo(rar2.Param); });
return true;
}
/// <summary> /// <summary>
/// 清除全部计算结果 /// 清除全部计算结果
/// </summary> /// </summary>
...@@ -380,9 +703,6 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -380,9 +703,6 @@ namespace FLY.Thick.BlowingScan.UI.Client
} }
/// <summary> /// <summary>
/// 转为 位置与厚度信息 /// 转为 位置与厚度信息
/// </summary> /// </summary>
...@@ -489,15 +809,27 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -489,15 +809,27 @@ namespace FLY.Thick.BlowingScan.UI.Client
/// <summary> /// <summary>
/// 第2步,修改 旋转角度,膜距离 执行, 耗时很短 /// 第2步,修改 旋转角度,膜距离 执行, 耗时很短
/// </summary> /// </summary>
void GetSolveEquation(double rAngle,double filmLength) void GetSolveEquation()
{ {
mAngleDetect.RAngle = rAngle;// RAngle;
//mAngleDetect.FilmLength = FilmLength;
//获取角度信息 //获取角度信息
for (int i = 0; i < mBufList.Count(); i++) for (int i = 0; i < mBufList.Count(); i++)
{ {
FlyData_BlowingScan f = mBufList[i]; GetSolveEquation(RAngle, FilmLength, i);
ScanInfoCell scaninfocell = ScanInfoList[i]; }
}
/// <summary>
/// 只获取某次扫描的方程
/// </summary>
/// <param name="rAngle"></param>
/// <param name="filmLength"></param>
/// <param name="idx"></param>
void GetSolveEquation(double rAngle, double filmLength, int idx)
{
FlyData_BlowingScan f = mBufList[idx];
ScanInfoCell scaninfocell = ScanInfoList[idx];
scaninfocell.equationList.Clear(); scaninfocell.equationList.Clear();
scaninfocell.State = ScanInfoCell.STATE.OK; scaninfocell.State = ScanInfoCell.STATE.OK;
...@@ -508,9 +840,10 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -508,9 +840,10 @@ namespace FLY.Thick.BlowingScan.UI.Client
BlowingAngleDetect.FilmInfo filminfo; BlowingAngleDetect.FilmInfo filminfo;
mAngleDetect.RAngle = rAngle;
int ret = mAngleDetect.GetFilmInfo( int ret = mAngleDetect.GetFilmInfo(
out filminfo, out filminfo,
scanpos.dt, f.FilmRange.Width, scanpos.pos, filmLength, f.Velocity);//FilmLength scanpos.dt, f.FilmRange.Width, scanpos.pos, filmLength, f.Velocity);
//探头直径转为角度范围 //探头直径转为角度范围
double sensor_angle = 180.0 * Sensor / f.FilmRange.Width; double sensor_angle = 180.0 * Sensor / f.FilmRange.Width;
...@@ -539,8 +872,7 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -539,8 +872,7 @@ namespace FLY.Thick.BlowingScan.UI.Client
break; break;
} }
} }
scaninfocell.AddEquation(j,sensor_angle); scaninfocell.AddEquation(j, sensor_angle);
}
} }
} }
......
...@@ -177,6 +177,7 @@ ...@@ -177,6 +177,7 @@
<Grid.RowDefinitions> <Grid.RowDefinitions>
<RowDefinition Height="auto"/> <RowDefinition Height="auto"/>
<RowDefinition/> <RowDefinition/>
<RowDefinition Height="auto"/>
<RowDefinition/> <RowDefinition/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<Grid Grid.ColumnSpan="2"> <Grid Grid.ColumnSpan="2">
...@@ -341,7 +342,8 @@ ...@@ -341,7 +342,8 @@
<WindowsFormsHost Grid.Row="1"> <WindowsFormsHost Grid.Row="1">
<Chr:Chart x:Name="chart1" /> <Chr:Chart x:Name="chart1" />
</WindowsFormsHost> </WindowsFormsHost>
<Grid Grid.Row="2"> <TextBlock Grid.Row="2" Style="{StaticResource TextBlockStyle_FieldHeader2}" Text="{Binding SearchMsg}" />
<Grid Grid.Row="3">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition/> <ColumnDefinition/>
<ColumnDefinition/> <ColumnDefinition/>
...@@ -403,14 +405,7 @@ ...@@ -403,14 +405,7 @@
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
<StackPanel Orientation="Horizontal">
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Style="{StaticResource TextBlockStyle_FieldHeader2}" Text="自相关性" />
<StackPanel Orientation="Horizontal">
<TextBlock Style="{StaticResource TextBlockStyle_FieldContent2}" Text="{Binding R, StringFormat=\{0:F5\}}" />
</StackPanel>
</StackPanel>
</StackPanel>
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
<StackPanel x:Name="stackpanel_markno2" Orientation="Vertical" Grid.Column="1" > <StackPanel x:Name="stackpanel_markno2" Orientation="Vertical" Grid.Column="1" >
...@@ -470,21 +465,13 @@ ...@@ -470,21 +465,13 @@
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
<StackPanel Orientation="Horizontal">
<StackPanel Orientation="Vertical" Margin="5">
<TextBlock Style="{StaticResource TextBlockStyle_FieldHeader2}" Text="自相关性" />
<StackPanel Orientation="Horizontal">
<TextBlock Style="{StaticResource TextBlockStyle_FieldContent2}" Text="{Binding R, StringFormat=\{0:F5\}}" />
</StackPanel>
</StackPanel>
</StackPanel>
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
</Grid> </Grid>
<GroupBox Header="调整" FontSize="20" Grid.Row="1" Grid.Column="1" Grid.RowSpan="2" > <GroupBox Header="调整" FontSize="20" Grid.Row="1" Grid.Column="1" Grid.RowSpan="3" >
<ScrollViewer VerticalScrollBarVisibility="Auto">
<StackPanel Orientation="Vertical"> <StackPanel>
<StackPanel Orientation="Horizontal"> <StackPanel Orientation="Horizontal">
<StackPanel Orientation="Vertical" Margin="5"> <StackPanel Orientation="Vertical" Margin="5">
<TextBlock Style="{StaticResource TextBlockStyle_FieldHeader2}" Text="相关性" /> <TextBlock Style="{StaticResource TextBlockStyle_FieldHeader2}" Text="相关性" />
...@@ -520,11 +507,8 @@ ...@@ -520,11 +507,8 @@
<TextBlock Style="{StaticResource TextBlockStyle_FieldContent_mm}" Text="m" FontSize="15" /> <TextBlock Style="{StaticResource TextBlockStyle_FieldContent_mm}" Text="m" FontSize="15" />
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
<Button Click="button_left_Click" > <Button Click="button_calFl_Click" >
<Path Data="{StaticResource Geometry_arrow-left}" /> <Path Data="{StaticResource Geometry_auto-fix}" />
</Button>
<Button Click="button_right_Click" >
<Path Data="{StaticResource Geometry_arrow-right}" />
</Button> </Button>
</StackPanel> </StackPanel>
...@@ -533,29 +517,32 @@ ...@@ -533,29 +517,32 @@
<TextBlock Style="{StaticResource TextBlockStyle_FieldHeaderEditable}" Text="旋转角度" /> <TextBlock Style="{StaticResource TextBlockStyle_FieldHeaderEditable}" Text="旋转角度" />
<StackPanel Orientation="Horizontal"> <StackPanel Orientation="Horizontal">
<TextBox Style="{StaticResource TextBoxStyle_FieldContent}" Text="{Binding RAngle}" /> <TextBox Style="{StaticResource TextBoxStyle_FieldContent}" Text="{Binding RAngle,StringFormat={}{0:F1}}" />
<TextBlock Style="{StaticResource TextBlockStyle_FieldContent_mm}" Text="°" VerticalAlignment="Top" /> <TextBlock Style="{StaticResource TextBlockStyle_FieldContent_mm}" Text="°" VerticalAlignment="Top" />
</StackPanel> </StackPanel>
</StackPanel> </StackPanel>
<Button Click="button_collapse_Click" > <Button Click="button_calRa_Click" >
<Path Data="{StaticResource Geometry_arrow-collapse-horizontal}" /> <Path Data="{StaticResource Geometry_auto-fix}" />
</Button>
<Button Click="button_expand_Click" >
<Path Data="{StaticResource Geometry_arrow-expand-horizontal}" />
</Button> </Button>
</StackPanel> </StackPanel>
<StackPanel Orientation="Vertical" > <StackPanel Orientation="Vertical" >
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition/>
<ColumnDefinition/>
</Grid.ColumnDefinitions>
<Button Style="{StaticResource ButtonStyle2}" Width="auto" Click="button_solve_Click" FontSize="30"> <Button Style="{StaticResource ButtonStyle2}" Width="auto" Click="button_solve_Click" FontSize="30">
<Grid> <Grid>
<TextBlock Text="更新参数"/> <TextBlock Text="更新参数"/>
<Grid HorizontalAlignment="Right" VerticalAlignment="Bottom" Margin="20" x:Name="grid_solveprogress" Visibility="{Binding IsRunning,Converter={StaticResource visbilityconv}}"> <Grid HorizontalAlignment="Right" VerticalAlignment="Bottom" Margin="10" x:Name="grid_solveprogress" Visibility="{Binding IsRunning,Converter={StaticResource visbilityconv}}">
<ed:Arc Width="45" Height="45" Opacity="0.9" <ed:Arc Width="40" Height="40" Opacity="0.9"
ArcThickness="4" ArcThickness="4"
ArcThicknessUnit="Pixel" ArcThicknessUnit="Pixel"
StartAngle="0" EndAngle="360" StartAngle="0" EndAngle="360"
Fill="White" Stretch="None" Stroke="#FF988585" /> Fill="White" Stretch="None" Stroke="#FF988585" />
<ed:Arc Width="45" Height="45" <ed:Arc Width="40" Height="40"
ArcThickness="4" ArcThickness="4"
ArcThicknessUnit="Pixel" ArcThicknessUnit="Pixel"
StartAngle="0" StartAngle="0"
...@@ -565,10 +552,21 @@ ...@@ -565,10 +552,21 @@
</Grid> </Grid>
</Grid> </Grid>
</Button> </Button>
<Button Grid.Column="1" Style="{StaticResource ButtonStyle2}" Width="auto" Click="button_calAuto_Click" FontSize="30">
<StackPanel>
<TextBlock Text="全自动"/>
<TextBlock Text="计算"/>
</StackPanel> </StackPanel>
</Button>
</Grid>
</StackPanel> </StackPanel>
</StackPanel>
</ScrollViewer>
</GroupBox> </GroupBox>
</Grid> </Grid>
......
...@@ -1268,38 +1268,9 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -1268,38 +1268,9 @@ namespace FLY.Thick.BlowingScan.UI.Client
} }
} }
private void button_left_Click(object sender, RoutedEventArgs e)
{
if (mAnaylze.FilmLength > 10)
{
mAnaylze.FilmLength -= 0.1;
}
}
private void button_right_Click(object sender, RoutedEventArgs e)
{
if (mAnaylze.FilmLength < 30)
{
mAnaylze.FilmLength += 0.1;
}
}
private void button_collapse_Click(object sender, RoutedEventArgs e)
{
if (mAnaylze.RAngle > 300)
{
mAnaylze.RAngle -= 1;
}
}
private void button_expand_Click(object sender, RoutedEventArgs e)
{
if (mAnaylze.RAngle < 358)
{
mAnaylze.RAngle += 1;
}
}
private void button_pre1_Click(object sender, RoutedEventArgs e) private void button_pre1_Click(object sender, RoutedEventArgs e)
...@@ -1385,6 +1356,45 @@ namespace FLY.Thick.BlowingScan.UI.Client ...@@ -1385,6 +1356,45 @@ namespace FLY.Thick.BlowingScan.UI.Client
mAnaylze.MarkNo2.IsFocus = true; mAnaylze.MarkNo2.IsFocus = true;
mAnaylze.MarkNo1.IsFocus = false; mAnaylze.MarkNo1.IsFocus = false;
} }
private void button_calRa_Click(object sender, RoutedEventArgs e)
{
if (IsRunning)
return;
if (mAnaylze.IsStep2Ing)
return;
//第2步,修改 旋转角度,膜距离 执行 解方程
Thread t = new Thread(mAnaylze.StepAutoSearchRAngle);
t.IsBackground = true;
t.Start();
}
private void button_calFl_Click(object sender, RoutedEventArgs e)
{
if (IsRunning)
return;
if (mAnaylze.IsStep2Ing)
return;
//第2步,修改 旋转角度,膜距离 执行 解方程
Thread t = new Thread(mAnaylze.StepAutoSearchFilmLength);
t.IsBackground = true;
t.Start();
}
private void button_calAuto_Click(object sender, RoutedEventArgs e)
{
if (IsRunning)
return;
if (mAnaylze.IsStep2Ing)
return;
//第2步,修改 旋转角度,膜距离 执行 解方程
Thread t = new Thread(mAnaylze.StepAutoSearchParams);
t.IsBackground = true;
t.Start();
}
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment