添加升降台控制功能
This commit is contained in:
@ -267,9 +267,13 @@ HPPA::HPPA(QWidget *parent)
|
||||
configfile.getYMotorParm(StepAnglemar_y, Lead_y, SubdivisionMultiples_y, ScaleFactor_y);*/
|
||||
|
||||
//
|
||||
connect(ui.objective_table_up_btn, SIGNAL(clicked()), this, SLOT(onObjectivTableUp_btn()));
|
||||
connect(ui.objective_table_down_btn, SIGNAL(clicked()), this, SLOT(onObjectivTableDown_btn()));
|
||||
connect(ui.objective_table_stop_btn, SIGNAL(clicked()), this, SLOT(onObjectivTableStop_btn()));
|
||||
connect(ui.objective_table1_up_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable1Up_btn()));
|
||||
connect(ui.objective_table1_down_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable1Down_btn()));
|
||||
connect(ui.objective_table1_stop_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable1Stop_btn()));
|
||||
|
||||
connect(ui.objective_table2_up_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable2Up_btn()));
|
||||
connect(ui.objective_table2_down_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable2Down_btn()));
|
||||
connect(ui.objective_table2_stop_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable2Stop_btn()));
|
||||
}
|
||||
|
||||
HPPA::~HPPA()
|
||||
@ -1718,19 +1722,37 @@ void HPPA::requestFinished(QNetworkReply* reply) {
|
||||
}
|
||||
}
|
||||
|
||||
void HPPA::onObjectivTableUp_btn()
|
||||
void HPPA::onObjectivTable1Up_btn()
|
||||
{
|
||||
QString xx = "http://192.168.1.253/set_up";
|
||||
getRequest(xx);
|
||||
}
|
||||
|
||||
void HPPA::onObjectivTable1Down_btn()
|
||||
{
|
||||
QString xx = "http://192.168.1.253/set_down";
|
||||
getRequest(xx);
|
||||
}
|
||||
|
||||
void HPPA::onObjectivTable1Stop_btn()
|
||||
{
|
||||
QString xx = "http://192.168.1.253/stopnow";
|
||||
getRequest(xx);
|
||||
}
|
||||
|
||||
void HPPA::onObjectivTable2Up_btn()
|
||||
{
|
||||
QString xx = "http://192.168.1.254/set_up";
|
||||
getRequest(xx);
|
||||
}
|
||||
|
||||
void HPPA::onObjectivTableDown_btn()
|
||||
void HPPA::onObjectivTable2Down_btn()
|
||||
{
|
||||
QString xx = "http://192.168.1.254/set_down";
|
||||
getRequest(xx);
|
||||
}
|
||||
|
||||
void HPPA::onObjectivTableStop_btn()
|
||||
void HPPA::onObjectivTable2Stop_btn()
|
||||
{
|
||||
QString xx = "http://192.168.1.254/stopnow";
|
||||
getRequest(xx);
|
||||
|
@ -321,9 +321,12 @@ public Q_SLOTS:
|
||||
|
||||
void requestFinished(QNetworkReply* reply);
|
||||
|
||||
void onObjectivTableUp_btn();
|
||||
void onObjectivTableDown_btn();
|
||||
void onObjectivTableStop_btn();
|
||||
void onObjectivTable1Up_btn();
|
||||
void onObjectivTable1Down_btn();
|
||||
void onObjectivTable1Stop_btn();
|
||||
void onObjectivTable2Up_btn();
|
||||
void onObjectivTable2Down_btn();
|
||||
void onObjectivTable2Stop_btn();
|
||||
|
||||
signals:
|
||||
void StartFocusSignal();
|
||||
|
127
HPPA/HPPA.ui
127
HPPA/HPPA.ui
@ -1686,44 +1686,101 @@
|
||||
<attribute name="title">
|
||||
<string>升降台</string>
|
||||
</attribute>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<item>
|
||||
<widget class="QPushButton" name="objective_table_up_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>上升</string>
|
||||
<layout class="QGridLayout" name="gridLayout_12">
|
||||
<item row="0" column="0">
|
||||
<widget class="QGroupBox" name="groupBox_7">
|
||||
<property name="title">
|
||||
<string>1号升降台</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_11">
|
||||
<item row="0" column="0">
|
||||
<widget class="QPushButton" name="objective_table1_up_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>上升</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QPushButton" name="objective_table1_down_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>下降</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QPushButton" name="objective_table1_stop_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>停止</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="objective_table_down_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>下降</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="objective_table_stop_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>停止</string>
|
||||
<item row="0" column="1">
|
||||
<widget class="QGroupBox" name="groupBox_6">
|
||||
<property name="title">
|
||||
<string>2号升降台</string>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="gridLayout_9">
|
||||
<item row="0" column="0">
|
||||
<widget class="QPushButton" name="objective_table2_up_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>上升</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QPushButton" name="objective_table2_down_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>下降</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QPushButton" name="objective_table2_stop_btn">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>停止</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
@ -1743,7 +1800,7 @@
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>2213</width>
|
||||
<height>23</height>
|
||||
<height>30</height>
|
||||
</rect>
|
||||
</property>
|
||||
<widget class="QMenu" name="file">
|
||||
|
Reference in New Issue
Block a user