Commit 89d5e6a8 LN

压力传感器值显示到设置界面

1 个父辈 1b3123b8
......@@ -144,7 +144,7 @@ namespace DeviceLibrary
int errorCount = Math.Abs(outCount - wait.TargetPosition);
if (errorCount <= wait.AxisInfo.CanErrorCountMax)
{
LogUtil.info($"{wait.AxisInfo.Explain},到达目标:errorCount:{errorCount},停止上升");
LogUtil.info($"{wait.AxisInfo.Explain},到达目标: 差异:{errorCount},停止上升");
axisBean.StopAxisCheckMove();
wait.IsEnd = true;
}
......
......@@ -46,7 +46,7 @@ namespace DeviceLibrary
bool result = rGB_Controller.OpenPort(port, out msg);
if (result)
{
LogUtil.error("LED灯初始化成功");
LogUtil.info("LED灯初始化成功");
rgbLedInitOk = true;
ledRgbTimer = new System.Threading.Timer(new TimerCallback(RgbLedProcess), null, 0, 500);
GC.KeepAlive(ledRgbTimer);
......
......@@ -37,14 +37,30 @@ namespace TheMachineNView
if (!RobotManage.haveFixpos)
cb_usefixpos.Visible = false;
}
private void SettingControl_Load(object sender, EventArgs e)
private void SShow(bool isShow)
{
lblMaxSet.Visible = isShow;
lblMaxY.Visible = isShow;
lblYa.Visible = isShow;
label1.Visible = isShow;
label3.Visible = isShow;
label5.Visible = isShow;
}
private void SettingControl_Load(object sender, EventArgs e)
{
//Config.PropertyBind("Device_Humiture_Port", cb_tempsensorport, "SelectedItem", "SelectedIndexChanged");
Config.PropertyBind("Device_Use_Fixpos", cb_usefixpos, "Checked", "CheckedChanged");
if (Setting_Init.Device_WeightSensor_PortName == "" )
{
SShow(false);
tp.RowStyles[1].Height = 0;
tp.RowStyles[2].Height = 0;
tp.AutoSize = true;
}
else
{ SShow(true); }
}
......@@ -119,6 +135,19 @@ namespace TheMachineNView
}
var t = HumitureController.LastData;
lbl_hmdstate.Text += $"{crc.GetString(L.temp, "温度")}:{t.Temperate}℃, {crc.GetString(L.humidity, "湿度")}:{t.Humidity}%";
if (Setting_Init.Device_WeightSensor_PortName == "" || RobotManage.oKLE_WeightSensor == null || (!RobotManage.oKLE_WeightSensor.IsPortOpen))
{
lblYa.Text = "";
lblMaxY.Text = "";
lblMaxSet.Text = "";
}
else
{
lblYa.Text =Math.Round( RobotManage.oKLE_WeightSensor.GetWeight(),2).ToString();
lblMaxY.Text = Math.Round(RobotManage.oKLE_WeightSensor.PeakWeight(), 2).ToString();
lblMaxSet.Text = Setting_Init.Device_WeightSensor_MaxValue.ToString();
}
}
private void button1_Click_1(object sender, EventArgs e)
......
......@@ -450,4 +450,7 @@ FlipDoor_R_Axis 右翻转托盘 Right Flip Tray
StringDoor_Axis 料串口折叠门 String Folding Door
FrmPositionTool_groupBox6_groupBox1_ioStatusControl1_label1_Text 检测信号 Detection Signal
Res0001 设备未启动 Device Not Started
stringDoorSafety 料串门光栅被遮挡 The grating of the string door is obstructed.
\ No newline at end of file
stringDoorSafety 料串门光栅被遮挡 The grating of the string door is obstructed.
Form1_tabc_tab_setting__SettingControl_tp_label5_Text 设置最大压力: Set maximum pressure:
Form1_tabc_tab_setting__SettingControl_tp_label3_Text 历史最大压力值: Historical maximum pressure value:
Form1_tabc_tab_setting__SettingControl_tp_label1_Text 压力传感器当前值: Current value of pressure sensor:
......@@ -454,3 +454,6 @@ StringDoor_Axis 料串口折叠门 ストリングドア
FrmPositionTool_groupBox6_groupBox1_ioStatusControl1_label1_Text 检测信号 検出信号
Res0001 设备未启动 デバイスは始まっていません
stringDoorSafety 料串门光栅被遮挡 料串口折叠门のグリッドが遮られています
Form1_tabc_tab_setting__SettingControl_tp_label5_Text 设置最大压力: 最大圧力を設定する:
Form1_tabc_tab_setting__SettingControl_tp_label3_Text 历史最大压力值: 過去の最大圧力値:
Form1_tabc_tab_setting__SettingControl_tp_label1_Text 压力传感器当前值: 圧力センサーの現在の値:
\ No newline at end of file
......@@ -438,4 +438,7 @@ FlipDoor_R_Axis 右翻转托盘
StringDoor_Axis 料串口折叠门
FrmPositionTool_groupBox6_groupBox1_ioStatusControl1_label1_Text 检测信号
Res0001 设备未启动
stringDoorSafety 料串门光栅被遮挡
stringDoorSafety 料串门光栅被遮挡
Form1_tabc_tab_setting__SettingControl_tp_label5_Text 设置最大压力:
Form1_tabc_tab_setting__SettingControl_tp_label3_Text 历史最大压力值:
Form1_tabc_tab_setting__SettingControl_tp_label1_Text 压力传感器当前值:
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!