添加升降台控制功能
This commit is contained in:
@ -267,9 +267,13 @@ HPPA::HPPA(QWidget *parent)
|
|||||||
configfile.getYMotorParm(StepAnglemar_y, Lead_y, SubdivisionMultiples_y, ScaleFactor_y);*/
|
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_table1_up_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable1Up_btn()));
|
||||||
connect(ui.objective_table_down_btn, SIGNAL(clicked()), this, SLOT(onObjectivTableDown_btn()));
|
connect(ui.objective_table1_down_btn, SIGNAL(clicked()), this, SLOT(onObjectivTable1Down_btn()));
|
||||||
connect(ui.objective_table_stop_btn, SIGNAL(clicked()), this, SLOT(onObjectivTableStop_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()
|
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";
|
QString xx = "http://192.168.1.254/set_up";
|
||||||
getRequest(xx);
|
getRequest(xx);
|
||||||
}
|
}
|
||||||
|
|
||||||
void HPPA::onObjectivTableDown_btn()
|
void HPPA::onObjectivTable2Down_btn()
|
||||||
{
|
{
|
||||||
QString xx = "http://192.168.1.254/set_down";
|
QString xx = "http://192.168.1.254/set_down";
|
||||||
getRequest(xx);
|
getRequest(xx);
|
||||||
}
|
}
|
||||||
|
|
||||||
void HPPA::onObjectivTableStop_btn()
|
void HPPA::onObjectivTable2Stop_btn()
|
||||||
{
|
{
|
||||||
QString xx = "http://192.168.1.254/stopnow";
|
QString xx = "http://192.168.1.254/stopnow";
|
||||||
getRequest(xx);
|
getRequest(xx);
|
||||||
|
@ -321,9 +321,12 @@ public Q_SLOTS:
|
|||||||
|
|
||||||
void requestFinished(QNetworkReply* reply);
|
void requestFinished(QNetworkReply* reply);
|
||||||
|
|
||||||
void onObjectivTableUp_btn();
|
void onObjectivTable1Up_btn();
|
||||||
void onObjectivTableDown_btn();
|
void onObjectivTable1Down_btn();
|
||||||
void onObjectivTableStop_btn();
|
void onObjectivTable1Stop_btn();
|
||||||
|
void onObjectivTable2Up_btn();
|
||||||
|
void onObjectivTable2Down_btn();
|
||||||
|
void onObjectivTable2Stop_btn();
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void StartFocusSignal();
|
void StartFocusSignal();
|
||||||
|
73
HPPA/HPPA.ui
73
HPPA/HPPA.ui
@ -1686,9 +1686,15 @@
|
|||||||
<attribute name="title">
|
<attribute name="title">
|
||||||
<string>升降台</string>
|
<string>升降台</string>
|
||||||
</attribute>
|
</attribute>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
<layout class="QGridLayout" name="gridLayout_12">
|
||||||
<item>
|
<item row="0" column="0">
|
||||||
<widget class="QPushButton" name="objective_table_up_btn">
|
<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">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -1700,8 +1706,8 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item row="1" column="0">
|
||||||
<widget class="QPushButton" name="objective_table_down_btn">
|
<widget class="QPushButton" name="objective_table1_down_btn">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -1713,8 +1719,8 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item row="2" column="0">
|
||||||
<widget class="QPushButton" name="objective_table_stop_btn">
|
<widget class="QPushButton" name="objective_table1_stop_btn">
|
||||||
<property name="sizePolicy">
|
<property name="sizePolicy">
|
||||||
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
<sizepolicy hsizetype="Minimum" vsizetype="Expanding">
|
||||||
<horstretch>0</horstretch>
|
<horstretch>0</horstretch>
|
||||||
@ -1728,6 +1734,57 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
|
</item>
|
||||||
|
<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>
|
||||||
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
@ -1743,7 +1800,7 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>2213</width>
|
<width>2213</width>
|
||||||
<height>23</height>
|
<height>30</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QMenu" name="file">
|
<widget class="QMenu" name="file">
|
||||||
|
Reference in New Issue
Block a user