Commit 44a11727 authored by Lorenz Meier's avatar Lorenz Meier

Merge branch 'config' of github.com:mavlink/qgroundcontrol into config

parents 46ca0aba 3f88380f
...@@ -229,6 +229,11 @@ QGCPX4SensorCalibration QLabel#accelLabel { ...@@ -229,6 +229,11 @@ QGCPX4SensorCalibration QLabel#accelLabel {
min-height: 25px; min-height: 25px;
} }
QGCPX4VehicleConfig QLabel#rcLabel {
color: #FEC654;
font-size: 18pt;
}
QGCToolWidgetItem { QGCToolWidgetItem {
border: 1px solid #666; border: 1px solid #666;
border-radius: 3px; border-radius: 3px;
......
...@@ -239,6 +239,8 @@ QGCPX4VehicleConfig::QGCPX4VehicleConfig(QWidget *parent) : ...@@ -239,6 +239,8 @@ QGCPX4VehicleConfig::QGCPX4VehicleConfig(QWidget *parent) :
connect(&updateTimer, SIGNAL(timeout()), this, SLOT(updateView())); connect(&updateTimer, SIGNAL(timeout()), this, SLOT(updateView()));
updateTimer.start(); updateTimer.start();
ui->rcLabel->setText(tr("NO RADIO CONTROL INPUT DETECTED. PLEASE ENSURE THE TRANSMITTER IS ON."));
} }
QGCPX4VehicleConfig::~QGCPX4VehicleConfig() QGCPX4VehicleConfig::~QGCPX4VehicleConfig()
...@@ -423,6 +425,7 @@ void QGCPX4VehicleConfig::startCalibrationRC() ...@@ -423,6 +425,7 @@ void QGCPX4VehicleConfig::startCalibrationRC()
QMessageBox::warning(0, QMessageBox::warning(0,
tr("RC not Connected"), tr("RC not Connected"),
tr("Is the RC receiver connected and transmitter turned on? Detected %1 radio channels. To operate PX4, you need at least 5 channels. ").arg(chanCount)); tr("Is the RC receiver connected and transmitter turned on? Detected %1 radio channels. To operate PX4, you need at least 5 channels. ").arg(chanCount));
ui->rcCalibrationButton->setChecked(false);
return; return;
} }
...@@ -464,6 +467,9 @@ void QGCPX4VehicleConfig::startCalibrationRC() ...@@ -464,6 +467,9 @@ void QGCPX4VehicleConfig::startCalibrationRC()
void QGCPX4VehicleConfig::stopCalibrationRC() void QGCPX4VehicleConfig::stopCalibrationRC()
{ {
if (!calibrationEnabled)
return;
QMessageBox::information(0,"Trims","Ensure all controls are centered and throttle is in the lowest position. Click OK to continue"); QMessageBox::information(0,"Trims","Ensure all controls are centered and throttle is in the lowest position. Click OK to continue");
calibrationEnabled = false; calibrationEnabled = false;
...@@ -1808,5 +1814,8 @@ void QGCPX4VehicleConfig::updateView() ...@@ -1808,5 +1814,8 @@ void QGCPX4VehicleConfig::updateView()
updateRcWidgetValues(); updateRcWidgetValues();
updateRcChanLabels(); updateRcChanLabels();
if (chanCount > 0)
ui->rcLabel->setText(tr("Radio control detected with %1 channels.").arg(chanCount));
} }
} }
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>1256</width> <width>1256</width>
<height>918</height> <height>985</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
...@@ -198,6 +198,13 @@ ...@@ -198,6 +198,13 @@
</item> </item>
</layout> </layout>
</item> </item>
<item>
<widget class="QLabel" name="rcLabel">
<property name="text">
<string>Waiting for RC channel data..</string>
</property>
</widget>
</item>
<item> <item>
<widget class="QCheckBox" name="advancedCheckBox"> <widget class="QCheckBox" name="advancedCheckBox">
<property name="text"> <property name="text">
...@@ -822,8 +829,8 @@ ...@@ -822,8 +829,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>21</width> <width>98</width>
<height>16</height> <height>28</height>
</rect> </rect>
</property> </property>
<layout class="QHBoxLayout" name="horizontalLayout_4"> <layout class="QHBoxLayout" name="horizontalLayout_4">
...@@ -859,8 +866,8 @@ ...@@ -859,8 +866,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>21</width> <width>98</width>
<height>16</height> <height>28</height>
</rect> </rect>
</property> </property>
<layout class="QHBoxLayout" name="horizontalLayout_5"> <layout class="QHBoxLayout" name="horizontalLayout_5">
...@@ -910,8 +917,8 @@ ...@@ -910,8 +917,8 @@
<rect> <rect>
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>16</width> <width>98</width>
<height>16</height> <height>28</height>
</rect> </rect>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_7"> <layout class="QVBoxLayout" name="verticalLayout_7">
......
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