This commit is contained in:
@@ -784,7 +784,18 @@ public partial class D7896ViewModel : ObservableObject
|
|||||||
CurrentMeasurementIndex = 0;
|
CurrentMeasurementIndex = 0;
|
||||||
StatusMessage = "已重置";
|
StatusMessage = "已重置";
|
||||||
TestDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
TestDateTime = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss");
|
||||||
TemperatureCurveModel = null;
|
|
||||||
|
// 清空曲线:新建一个空白的 PlotModel 替换原来的
|
||||||
|
TemperatureCurveModel = new PlotModel
|
||||||
|
{
|
||||||
|
Title = "温升与冷却曲线",
|
||||||
|
Background = OxyColors.White
|
||||||
|
};
|
||||||
|
TemperatureCurveModel.Axes.Add(new LinearAxis { Position = AxisPosition.Bottom, Title = "时间 (s)" });
|
||||||
|
TemperatureCurveModel.Axes.Add(new LinearAxis { Position = AxisPosition.Left, Title = "温升 (℃)" });
|
||||||
|
TemperatureCurveModel.InvalidatePlot(true);
|
||||||
|
|
||||||
|
CurveTitle = "温升曲线";
|
||||||
}
|
}
|
||||||
|
|
||||||
[RelayCommand]
|
[RelayCommand]
|
||||||
|
|||||||
@@ -38,7 +38,7 @@
|
|||||||
<RadioButton x:Name="rb50Hz" Content="50 Hz" GroupName="Freq" IsChecked="True" Margin="5,0,15,0"/>
|
<RadioButton x:Name="rb50Hz" Content="50 Hz" GroupName="Freq" IsChecked="True" Margin="5,0,15,0"/>
|
||||||
<RadioButton x:Name="rb60Hz" Content="60 Hz" GroupName="Freq"/>
|
<RadioButton x:Name="rb60Hz" Content="60 Hz" GroupName="Freq"/>
|
||||||
<Label Content="设定电流 (A):" Margin="20,0,0,0"/>
|
<Label Content="设定电流 (A):" Margin="20,0,0,0"/>
|
||||||
<TextBox x:Name="txtSetCurrent" Text="0.650" Width="80" TextAlignment="Center"/>
|
<TextBox x:Name="txtSetCurrent" Text="0.680" Width="80" TextAlignment="Center"/>
|
||||||
<Label Content="A"/>
|
<Label Content="A"/>
|
||||||
<Button x:Name="btnSet" Content="直接设定" Click="BtnSet_Click" Width="80" Margin="10,0,0,0"/>
|
<Button x:Name="btnSet" Content="直接设定" Click="BtnSet_Click" Width="80" Margin="10,0,0,0"/>
|
||||||
<Button x:Name="btnStop" Content="禁止输出" Click="BtnStop_Click" Width="80" Margin="5,0,0,0"/>
|
<Button x:Name="btnStop" Content="禁止输出" Click="BtnStop_Click" Width="80" Margin="5,0,0,0"/>
|
||||||
|
|||||||
Reference in New Issue
Block a user