@@ -193,6 +193,15 @@ ModulePanel::ModulePanel(QWidget * parent, ModelData & model, ModuleData & modul
|
||||
}
|
||||
ui->label_module->setText(label);
|
||||
|
||||
// Antena selection for Horus
|
||||
if (IS_HORUS(firmware->getBoard()) && moduleIdx == 0) {
|
||||
ui->antennaMode->setCurrentIndex(module.ppm.pulsePol);
|
||||
}
|
||||
else {
|
||||
ui->label_antenna->hide();
|
||||
ui->antennaMode->hide();
|
||||
}
|
||||
|
||||
// The protocols available on this board
|
||||
for (int i=0; i<PULSES_PROTOCOL_LAST; i++) {
|
||||
if (firmware->isAvailable((PulsesProtocol)i, moduleIdx)) {
|
||||
@@ -416,6 +425,12 @@ void ModulePanel::on_ppmPolarity_currentIndexChanged(int index)
|
||||
emit modified();
|
||||
}
|
||||
|
||||
void ModulePanel::on_antennaMode_currentIndexChanged(int index)
|
||||
{
|
||||
module.ppm.pulsePol = index;
|
||||
emit modified();
|
||||
}
|
||||
|
||||
void ModulePanel::on_ppmOutputType_currentIndexChanged(int index)
|
||||
{
|
||||
module.ppm.outputType = index;
|
||||
|
||||
@@ -81,6 +81,7 @@ class ModulePanel : public ModelPanel
|
||||
void on_ppmPolarity_currentIndexChanged(int index);
|
||||
void on_ppmOutputType_currentIndexChanged(int index);
|
||||
void on_ppmFrameLength_editingFinished();
|
||||
void on_antennaMode_currentIndexChanged(int index);
|
||||
void on_rxNumber_editingFinished();
|
||||
void on_failsafeMode_currentIndexChanged(int value);
|
||||
void onFailsafeComboIndexChanged(int index);
|
||||
@@ -107,9 +108,9 @@ class SetupPanel : public ModelPanel
|
||||
|
||||
virtual void update();
|
||||
|
||||
signals:
|
||||
signals:
|
||||
void extendedLimitsToggled();
|
||||
|
||||
|
||||
private slots:
|
||||
void on_name_editingFinished();
|
||||
void on_throttleSource_currentIndexChanged(int index);
|
||||
|
||||
@@ -167,6 +167,48 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="2" alignment="Qt::AlignRight">
|
||||
<widget class="QLabel" name="label_antenna">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Antenna</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="3" alignment="Qt::AlignLeft">
|
||||
<widget class="QComboBox" name="antennaMode">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>125</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Internal</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Ext. + Int.</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="4" alignment="Qt::AlignRight">
|
||||
<widget class="QLabel" name="label_ppmDelay">
|
||||
<property name="maximumSize">
|
||||
|
||||
Reference in New Issue
Block a user