Compare commits
32 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 91032483c8 | |||
| 9e40708f7c | |||
| 54902a5a00 | |||
| 927a9b9f38 | |||
| bfdb3a9da7 | |||
| 63269ac35a | |||
| 113deb6b75 | |||
| c48f4a51a6 | |||
| 3cd2f709fc | |||
| d2df4af67d | |||
| 67177aed42 | |||
| 5879ca2fb6 | |||
| 77a7f13507 | |||
| 2a794e2ae3 | |||
| 090f659dca | |||
| ca79fabdc7 | |||
| 693f232f01 | |||
| 8c33914cbb | |||
| a8e594e54c | |||
| 17f7d90dbf | |||
| 7ad3d5d317 | |||
| 3d37b0d397 | |||
| e8fc7c4c89 | |||
| 405fd802d5 | |||
| 5d1e9a1701 | |||
| d09b85ddc4 | |||
| a4aa0eb7c8 | |||
| d105325dd7 | |||
| 1fb9e57c62 | |||
| 576d9d6d9d | |||
| b7f3d1674d | |||
| f7b009a9be |
@@ -493,3 +493,10 @@ Heinrich Illig
|
||||
Portstate Pty Ltd
|
||||
Jens Hoffmann
|
||||
Ricardo Santos
|
||||
Jean-Francois Le Breton
|
||||
Michael Deasy
|
||||
Anindya Mukerjee
|
||||
Emay Toha
|
||||
Kamco Enterprises
|
||||
Peter Mueller
|
||||
Giovanni Trentini
|
||||
|
||||
@@ -1,3 +1,13 @@
|
||||
<h2>Version 2.0.5</h2>
|
||||
<ul>
|
||||
<li>Fix crash on startup</li>
|
||||
<li>Fix version number in simu</li>
|
||||
<li>9XR-Pro now supported on Mac</li>
|
||||
<li>Fix loss of settings in telemetry custom screens</li>
|
||||
<li>Fix 10000% bug when using GVs in mixer weithg or offset</li>
|
||||
<li>Fix Cnsp range in logical switches (up to 30000mAh)</li>
|
||||
</ul>
|
||||
|
||||
<h2>Version 2.0.4</h2>
|
||||
<ul>
|
||||
<li>Sound should be ok on all platforms</li>
|
||||
|
||||
@@ -2,7 +2,7 @@ PROJECT( companion )
|
||||
|
||||
SET( C9X_VERSION_MAJOR "2" )
|
||||
SET( C9X_VERSION_MINOR "0" )
|
||||
SET( C9X_VERSION_REVISION "4" )
|
||||
SET( C9X_VERSION_REVISION "5" )
|
||||
SET( C9X_VERSION ${C9X_VERSION_MAJOR}.${C9X_VERSION_MINOR}.${C9X_VERSION_REVISION} )
|
||||
|
||||
CMAKE_MINIMUM_REQUIRED( VERSION 2.8 )
|
||||
|
||||
@@ -95,6 +95,9 @@ int main(int argc, char *argv[])
|
||||
app.installTranslator(&qtTranslator);
|
||||
|
||||
QTextCodec::setCodecForCStrings(QTextCodec::codecForName("UTF-8"));
|
||||
|
||||
RegisterEepromInterfaces();
|
||||
registerOpenTxFirmwares();
|
||||
|
||||
if (g.profile[g.id()].fwType().isEmpty()){
|
||||
g.profile[g.id()].fwType(default_firmware_variant->getId());
|
||||
@@ -110,9 +113,6 @@ int main(int argc, char *argv[])
|
||||
QPixmap pixmap = QPixmap(splashScreen);
|
||||
QSplashScreen *splash = new QSplashScreen(pixmap);
|
||||
|
||||
RegisterEepromInterfaces();
|
||||
registerOpenTxFirmwares();
|
||||
|
||||
current_firmware_variant = GetFirmware(g.profile[g.id()].fwType());
|
||||
|
||||
MainWindow *mainWin = new MainWindow();
|
||||
|
||||
@@ -242,7 +242,7 @@ RawSourceRange RawSource::getRange(const ModelData & model, const GeneralSetting
|
||||
break;
|
||||
case TELEMETRY_SOURCE_CONSUMPTION:
|
||||
result.step = singleprec ? 100 : 1;
|
||||
result.max = singleprec ? 25500 : 10000;
|
||||
result.max = singleprec ? 25500 : 30000;
|
||||
result.unit = QObject::tr("mAh");
|
||||
break;
|
||||
case TELEMETRY_SOURCE_POWER:
|
||||
|
||||
@@ -1169,8 +1169,7 @@ void registerOpenTxFirmwares()
|
||||
openTx->addOptions(fai_options);
|
||||
firmwares.push_back(openTx);
|
||||
|
||||
#ifndef __APPLE__
|
||||
/* SKY9X board */
|
||||
/* Sky9x board */
|
||||
openTx = new OpenTxFirmware("opentx-sky9x", QObject::tr("OpenTX for Sky9x board / 9X"), BOARD_SKY9X);
|
||||
openTx->addOption("heli", QObject::tr("Enable HELI menu and cyclic mix support"));
|
||||
openTx->addOption("templates", QObject::tr("Enable TEMPLATES menu"));
|
||||
@@ -1215,7 +1214,6 @@ void registerOpenTxFirmwares()
|
||||
openTx->addOption("bluetooth", QObject::tr("Bluetooth interface"));
|
||||
openTx->addOptions(fai_options);
|
||||
firmwares.push_back(openTx);
|
||||
#endif
|
||||
|
||||
/* Taranis board */
|
||||
openTx = new OpenTxFirmware("opentx-taranis", QObject::tr("OpenTX for FrSky Taranis"), BOARD_TARANIS);
|
||||
|
||||
@@ -316,6 +316,7 @@ GeneralEdit::GeneralEdit(RadioData &radioData, QWidget *parent) :
|
||||
ui->switchesDelay->hide();
|
||||
ui->switchesDelayLabel->hide();
|
||||
}
|
||||
ui->blAlarm_ChkB->setChecked(g_eeGeneral.flashBeep);
|
||||
|
||||
disableMouseScrolling();
|
||||
}
|
||||
@@ -325,6 +326,12 @@ GeneralEdit::~GeneralEdit()
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void GeneralEdit::on_blAlarm_ChkB_stateChanged()
|
||||
{
|
||||
g_eeGeneral.flashBeep = ui->blAlarm_ChkB->isChecked();
|
||||
updateSettings();
|
||||
}
|
||||
|
||||
void GeneralEdit::stickReverseEdited()
|
||||
{
|
||||
g_eeGeneral.stickReverse = ((int)ui->stickReverse1->isChecked()) | ((int)ui->stickReverse2->isChecked()<<1) | ((int)ui->stickReverse3->isChecked()<<2) | ((int)ui->stickReverse4->isChecked()<<3);
|
||||
|
||||
@@ -137,6 +137,7 @@ class GeneralEdit : public QDialog
|
||||
void shrink();
|
||||
void stickReverseEdited();
|
||||
void on_switchesDelay_valueChanged();
|
||||
void on_blAlarm_ChkB_stateChanged();
|
||||
};
|
||||
|
||||
#endif // GENERALEDIT_H
|
||||
|
||||
@@ -113,17 +113,31 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
<string>Setup</string>
|
||||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout" columnstretch="1,0,0,0,0">
|
||||
<item row="34" column="4">
|
||||
<item row="34" column="3">
|
||||
<widget class="QLabel" name="gpsFormatLabel">
|
||||
<property name="text">
|
||||
<string>GPS Coordinates</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="3">
|
||||
<widget class="QLabel" name="label_speakerPitch">
|
||||
<property name="text">
|
||||
<string>Speaker Pitch (spkr only)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="36" column="4">
|
||||
<widget class="QComboBox" name="voiceLang_CB"/>
|
||||
</item>
|
||||
<item row="31" column="3">
|
||||
<item row="33" column="3">
|
||||
<widget class="QLabel" name="units_label">
|
||||
<property name="text">
|
||||
<string>Measurement Units</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="32" column="4">
|
||||
<item row="34" column="4">
|
||||
<widget class="QComboBox" name="gpsFormatCB">
|
||||
<item>
|
||||
<property name="text">
|
||||
@@ -137,7 +151,7 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="33" column="4">
|
||||
<item row="35" column="4">
|
||||
<widget class="QSpinBox" name="timezoneSB">
|
||||
<property name="minimum">
|
||||
<number>-14</number>
|
||||
@@ -150,28 +164,21 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="34" column="3">
|
||||
<item row="36" column="3">
|
||||
<widget class="QLabel" name="VoiceLang_label">
|
||||
<property name="text">
|
||||
<string>Voice Language</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="32" column="3">
|
||||
<widget class="QLabel" name="gpsFormatLabel">
|
||||
<property name="text">
|
||||
<string>GPS Coordinates</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="33" column="3">
|
||||
<item row="35" column="3">
|
||||
<widget class="QLabel" name="label_timezone">
|
||||
<property name="text">
|
||||
<string>Timeshift from UTC</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="31" column="4">
|
||||
<item row="33" column="4">
|
||||
<widget class="QComboBox" name="units_CB">
|
||||
<item>
|
||||
<property name="text">
|
||||
@@ -185,14 +192,14 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="29" column="3">
|
||||
<item row="31" column="3">
|
||||
<widget class="QLabel" name="countrycode_label">
|
||||
<property name="text">
|
||||
<string>Country Code</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="29" column="4">
|
||||
<item row="31" column="4">
|
||||
<widget class="QComboBox" name="countrycode_CB">
|
||||
<item>
|
||||
<property name="text">
|
||||
@@ -256,14 +263,7 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="3">
|
||||
<widget class="QLabel" name="label_speakerPitch">
|
||||
<property name="text">
|
||||
<string>Speaker Pitch (spkr only)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="14" column="4">
|
||||
<item row="16" column="4">
|
||||
<layout class="QHBoxLayout" name="backlightColor_Layout">
|
||||
<item>
|
||||
<widget class="QLabel" name="backlightColor1_label">
|
||||
@@ -298,7 +298,7 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="15" column="3">
|
||||
<item row="17" column="3">
|
||||
<widget class="QLabel" name="re_label">
|
||||
<property name="text">
|
||||
<string>RotEnc Navigation</string>
|
||||
@@ -333,7 +333,7 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="27" column="0">
|
||||
<item row="29" column="0">
|
||||
<widget class="QLabel" name="ro_label">
|
||||
<property name="text">
|
||||
<string>Readonly Unlock</string>
|
||||
@@ -343,7 +343,7 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="36" column="0" colspan="2">
|
||||
<item row="38" column="0" colspan="2">
|
||||
<spacer name="verticalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
@@ -426,7 +426,7 @@ These will be relevant for all models in the same EEPROM.</string>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="2">
|
||||
<item row="14" column="2">
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
@@ -526,7 +526,7 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="27" column="1" colspan="3">
|
||||
<item row="29" column="1" colspan="3">
|
||||
<layout class="QGridLayout" name="TaranisReadOnlyUnlock" rowstretch="0,0" columnstretch="0,0,0,0,0,0,0,0,0">
|
||||
<property name="sizeConstraint">
|
||||
<enum>QLayout::SetMinimumSize</enum>
|
||||
@@ -1199,7 +1199,7 @@ Acceptable values are 5v..10v</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="3">
|
||||
<item row="14" column="3">
|
||||
<widget class="QLabel" name="label_BLBright">
|
||||
<property name="text">
|
||||
<string>Backlight Brightness</string>
|
||||
@@ -1220,17 +1220,17 @@ Acceptable values are 5v..10v</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="4">
|
||||
<item row="14" column="4">
|
||||
<widget class="QSpinBox" name="BLBright_SB">
|
||||
<property name="maximum">
|
||||
<number>100</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="15" column="4">
|
||||
<item row="17" column="4">
|
||||
<widget class="QComboBox" name="re_CB"/>
|
||||
</item>
|
||||
<item row="14" column="3">
|
||||
<item row="16" column="3">
|
||||
<widget class="QLabel" name="backlightColor_label">
|
||||
<property name="text">
|
||||
<string>Backlight color</string>
|
||||
@@ -1272,7 +1272,7 @@ Acceptable values are 5v..10v</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="15" column="1">
|
||||
<item row="17" column="1">
|
||||
<widget class="QComboBox" name="mavbaud_CB">
|
||||
<item>
|
||||
<property name="text">
|
||||
@@ -1374,7 +1374,7 @@ Acceptable values are 5v..10v</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="14" column="1">
|
||||
<item row="16" column="1">
|
||||
<widget class="QCheckBox" name="memwarnChkB">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
|
||||
@@ -1409,7 +1409,7 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="15" column="0">
|
||||
<item row="17" column="0">
|
||||
<widget class="QLabel" name="mavbaud_label">
|
||||
<property name="text">
|
||||
<string>MAVLink Baud Rate</string>
|
||||
@@ -1465,7 +1465,7 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="1">
|
||||
<item row="14" column="1">
|
||||
<widget class="QCheckBox" name="alarmwarnChkB">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
|
||||
@@ -1579,14 +1579,14 @@ p, li { white-space: pre-wrap; }
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="13" column="0">
|
||||
<item row="14" column="0">
|
||||
<widget class="QLabel" name="label_27">
|
||||
<property name="text">
|
||||
<string>"No Sound" Warning</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="14" column="0">
|
||||
<item row="16" column="0">
|
||||
<widget class="QLabel" name="label_11">
|
||||
<property name="text">
|
||||
<string>Low Memory Warning</string>
|
||||
@@ -1696,14 +1696,14 @@ p, li { white-space: pre-wrap; }
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="29" column="0">
|
||||
<item row="31" column="0">
|
||||
<widget class="QLabel" name="label_14">
|
||||
<property name="text">
|
||||
<string>Stick Mode</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="31" column="0">
|
||||
<item row="33" column="0">
|
||||
<widget class="QLabel" name="stickReverseLB">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||
@@ -1716,7 +1716,7 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="32" column="0">
|
||||
<item row="34" column="0">
|
||||
<widget class="QLabel" name="label_13">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||
@@ -1729,14 +1729,14 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="33" column="0">
|
||||
<item row="35" column="0">
|
||||
<widget class="QLabel" name="label_faimode">
|
||||
<property name="text">
|
||||
<string>FAI Mode</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="29" column="1">
|
||||
<item row="31" column="1">
|
||||
<widget class="QComboBox" name="stickmodeCB">
|
||||
<property name="toolTip">
|
||||
<string/>
|
||||
@@ -1790,7 +1790,7 @@ Mode 4:
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="31" column="1">
|
||||
<item row="33" column="1">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="stickReverse1">
|
||||
@@ -1822,7 +1822,7 @@ Mode 4:
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="32" column="1">
|
||||
<item row="34" column="1">
|
||||
<widget class="QComboBox" name="channelorderCB">
|
||||
<property name="toolTip">
|
||||
<string/>
|
||||
@@ -1958,7 +1958,7 @@ Mode 4:
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="33" column="1">
|
||||
<item row="35" column="1">
|
||||
<widget class="QCheckBox" name="faimode_CB">
|
||||
<property name="toolTip">
|
||||
<string>If you enable FAI, you loose the vario, the play functions, the telemetry screen. This function cannot be disabled by the radio.</string>
|
||||
@@ -1968,7 +1968,7 @@ Mode 4:
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="34" column="0">
|
||||
<item row="36" column="0">
|
||||
<widget class="QLabel" name="switchesDelayLabel">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Minimum" vsizetype="Minimum">
|
||||
@@ -1981,7 +1981,7 @@ Mode 4:
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="34" column="1">
|
||||
<item row="36" column="1">
|
||||
<widget class="QSpinBox" name="switchesDelay">
|
||||
<property name="toolTip">
|
||||
<string/>
|
||||
@@ -2014,6 +2014,20 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="3">
|
||||
<widget class="QLabel" name="blAlarm_LB">
|
||||
<property name="text">
|
||||
<string>Backlight flash on alarm</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="13" column="4">
|
||||
<widget class="QCheckBox" name="blAlarm_ChkB">
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tabTrainer">
|
||||
|
||||
@@ -290,7 +290,7 @@ void CurveGroup::gvarCBChanged(int state)
|
||||
{
|
||||
if (!lock) {
|
||||
if (state) {
|
||||
curve.value = 10000; // TODO constant in EEpromInterface ...
|
||||
curve.value = 10000+1; // TODO constant in EEpromInterface ...
|
||||
}
|
||||
else {
|
||||
curve.value = 0; // TODO could be better
|
||||
|
||||
@@ -332,7 +332,6 @@ TelemetryCustomScreen::TelemetryCustomScreen(QWidget *parent, ModelData & model,
|
||||
|
||||
void TelemetryCustomScreen::populateTelemetrySourceCB(QComboBox *b, unsigned int value, bool last, int hubproto)
|
||||
{
|
||||
int telem_hub[] = {0,0,0,0,0,0,0,0,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,0,0,2,2,1,1,1,1,1,1};
|
||||
b->clear();
|
||||
|
||||
b->addItem(RawSource(SOURCE_TYPE_NONE, 0).toString(model));
|
||||
@@ -340,24 +339,14 @@ void TelemetryCustomScreen::populateTelemetrySourceCB(QComboBox *b, unsigned int
|
||||
for (unsigned int i = 0; i < (last ? TELEMETRY_SOURCES_STATUS_COUNT : TELEMETRY_SOURCES_DISPLAY_COUNT); i++) {
|
||||
b->addItem(RawSource(SOURCE_TYPE_TELEMETRY, i).toString(model));
|
||||
if (!firmware->isTelemetrySourceAvailable(i)) {
|
||||
//disable item
|
||||
// disable item
|
||||
QModelIndex index = b->model()->index(i+1, 0);
|
||||
QVariant v(0);
|
||||
b->model()->setData(index, v, Qt::UserRole - 1);
|
||||
}
|
||||
if (!(i>=sizeof(telem_hub)/sizeof(int) || telem_hub[i]==0 || ((telem_hub[i]>=hubproto) && hubproto!=0))) {
|
||||
QModelIndex index = b->model()->index(i, 0);
|
||||
QVariant v(0);
|
||||
b->model()->setData(index, v, Qt::UserRole - 1);
|
||||
}
|
||||
}
|
||||
|
||||
if (value>=sizeof(telem_hub)/sizeof(int))
|
||||
b->setCurrentIndex(0);
|
||||
else if (telem_hub[value]==0 || ((telem_hub[value]>=hubproto) && hubproto!=0)) {
|
||||
b->setCurrentIndex(value);
|
||||
}
|
||||
|
||||
b->setCurrentIndex(value);
|
||||
b->setMaxVisibleItems(10);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,3 +1,14 @@
|
||||
<h2>Version 2.0.5 / 2014-06-26</h2>
|
||||
[Taranis]
|
||||
<ul>
|
||||
<li>Add Flight Mode indication to the mixer/inputs screens
|
||||
<li>Joystick emulation fixed
|
||||
<li>Fixed float number display in Lua
|
||||
<li>Fixed telemetry screens page order (Lua, custom, voltage, GPS)
|
||||
<li>Fixed unability to disable switch warning for SG
|
||||
<li>Lua bugfixes in getCustomFunction/setCustomFunction and getLogicalSwitch/setLogicalSwitch
|
||||
</ul>
|
||||
|
||||
<h2>Version 2.0.4 / 2014-06-24</h2>
|
||||
[Taranis]
|
||||
<ul>
|
||||
|
||||
+3
-3
@@ -285,7 +285,7 @@ SHELL = sh
|
||||
IMG2LBM = -python ../util/img2lbm.py
|
||||
BIN2LBM = -python ../util/bin2lbm.py
|
||||
TRANSLATE = -python ../util/translate.py
|
||||
VERSION = 2.0.4
|
||||
VERSION = 2.0.5
|
||||
|
||||
SRC =
|
||||
CPPSRC =
|
||||
@@ -1147,12 +1147,12 @@ bootloader.lbm: bootloader/bootloader_ramBoot.bin
|
||||
else ifeq ($(PCB), 9XRPRO)
|
||||
bootloader.lbm:
|
||||
@echo "Fetching Mike's bootloader..."
|
||||
wget https://ersky9x.googlecode.com/svn/trunk/src/bootloader/bootflash8.lbm
|
||||
wget http://ersky9x.googlecode.com/svn/trunk/src/bootloader/bootflash8.lbm
|
||||
mv bootflash8.lbm $@
|
||||
else ifeq ($(PCB), SKY9X)
|
||||
bootloader.lbm:
|
||||
@echo "Fetching Mike's bootloader..."
|
||||
wget https://ersky9x.googlecode.com/svn/trunk/src/bootloader/bootflash4.lbm
|
||||
wget http://ersky9x.googlecode.com/svn/trunk/src/bootloader/bootflash4.lbm
|
||||
mv bootflash4.lbm $@
|
||||
endif
|
||||
|
||||
|
||||
+123
-72
@@ -1028,7 +1028,7 @@ void menuModelSetup(uint8_t event)
|
||||
#define CURSOR_ON_CELL (true)
|
||||
#define MODEL_SETUP_MAX_LINES ((IS_PPM_PROTOCOL(protocol)||IS_DSM2_PROTOCOL(protocol)||IS_PXX_PROTOCOL(protocol)) ? 1+ITEM_MODEL_SETUP_MAX : ITEM_MODEL_SETUP_MAX)
|
||||
uint8_t protocol = g_model.protocol;
|
||||
MENU_TAB({ 0, 0, CASE_PCBTARANIS(0) 2, CASE_PERSISTENT_TIMERS(0) 0, 0, 2, CASE_PERSISTENT_TIMERS(0) 0, 0, 0, 1, 0, 0, 0, 0, 0, 6, NUM_STICKS+NUM_POTS+NUM_ROTARY_ENCODERS-1, FIELD_PROTOCOL_MAX, 2, CASE_PCBSKY9X(1) CASE_PCBSKY9X(2) });
|
||||
MENU_TAB({ 0, 0, CASE_PCBTARANIS(0) 2, CASE_PERSISTENT_TIMERS(0) 0, 0, 2, CASE_PERSISTENT_TIMERS(0) 0, 0, 0, 1, 0, 0, 0, 0, 0, NUM_SWITCHES, NUM_STICKS+NUM_POTS+NUM_ROTARY_ENCODERS-1, FIELD_PROTOCOL_MAX, 2, CASE_PCBSKY9X(1) CASE_PCBSKY9X(2) });
|
||||
#endif
|
||||
|
||||
if (!MENU_CHECK(menuTabModel, e_ModelSetup, MODEL_SETUP_MAX_LINES)) {
|
||||
@@ -1797,21 +1797,28 @@ uint8_t editDelay(const uint8_t y, const uint8_t event, const uint8_t attr, cons
|
||||
#define FlightModesType uint8_t
|
||||
#endif
|
||||
|
||||
#if defined(PCBTARANIS)
|
||||
void displayFlightModes(uint8_t x, uint8_t y, FlightModesType value)
|
||||
{
|
||||
lcd_puts(x, y, STR_FP);
|
||||
x = lcdNextPos + 1;
|
||||
for (uint8_t p=0; p<MAX_FLIGHT_MODES; p++) {
|
||||
lcd_putc(x, y, ((value & (1<<p)) ? '-' : '0'+p));
|
||||
x += 5;
|
||||
}
|
||||
}
|
||||
#else
|
||||
void displayFlightModes(uint8_t x, uint8_t y, FlightModesType value)
|
||||
{
|
||||
uint8_t p = MAX_FLIGHT_MODES;
|
||||
do {
|
||||
--p;
|
||||
if (!(value & (1<<p)))
|
||||
#if defined(PCBTARANIS)
|
||||
lcd_putcAtt(x, y+2, '0'+p, TINSIZE);
|
||||
x -= FWNUM-1;
|
||||
#else
|
||||
lcd_putc(x, y, '0'+p);
|
||||
x -= FWNUM;
|
||||
#endif
|
||||
x -= FWNUM;
|
||||
} while (p!=0);
|
||||
}
|
||||
#endif
|
||||
|
||||
FlightModesType editFlightModes(uint8_t x, uint8_t y, uint8_t event, FlightModesType value, uint8_t attr)
|
||||
{
|
||||
@@ -3328,16 +3335,16 @@ static uint8_t s_copySrcCh;
|
||||
#define EXPO_LINE_CURVE_POS 12*FW+11
|
||||
#define EXPO_LINE_TRIM_POS 19*FW-4
|
||||
#define EXPO_LINE_SWITCH_POS 20*FW-1
|
||||
#define EXPO_LINE_SIDE_POS 23*FW
|
||||
#define EXPO_LINE_FM_POS 24*FW+2
|
||||
#define EXPO_LINE_SIDE_POS 25*FW
|
||||
#define EXPO_LINE_FM_POS 12*FW+11
|
||||
#define EXPO_LINE_SELECT_POS 5*FW+2
|
||||
#define EXPO_LINE_NAME_POS LCD_W-LEN_EXPOMIX_NAME*FW-MENUS_SCROLLBAR_WIDTH
|
||||
#define MIX_LINE_WEIGHT_POS 6*FW+8
|
||||
#define MIX_LINE_SRC_POS 7*FW+3
|
||||
#define MIX_LINE_CURVE_POS 13*FW+3
|
||||
#define MIX_LINE_SWITCH_POS 21*FW-1
|
||||
#define MIX_LINE_FM_POS 24*FW+2
|
||||
#define MIX_LINE_DELAY_POS 18*FW+2
|
||||
#define MIX_LINE_SWITCH_POS 19*FW+1
|
||||
#define MIX_LINE_FM_POS 13*FW+3
|
||||
#define MIX_LINE_DELAY_POS 24*FW+3
|
||||
#elif defined(CPUARM)
|
||||
#define EXPO_LINE_WEIGHT_POS 7*FW+1
|
||||
#define EXPO_LINE_EXPO_POS 10*FW+5
|
||||
@@ -3345,7 +3352,7 @@ static uint8_t s_copySrcCh;
|
||||
#define EXPO_LINE_SIDE_POS 14*FW+2
|
||||
#define EXPO_LINE_SELECT_POS 24
|
||||
#define EXPO_LINE_FM_POS
|
||||
#define EXPO_LINE_NAME_POS LCD_W-sizeof(ed->name)*FW-MENUS_SCROLLBAR_WIDTH
|
||||
#define EXPO_LINE_NAME_POS LCD_W-LEN_EXPOMIX_NAME*FW-MENUS_SCROLLBAR_WIDTH
|
||||
#define MIX_LINE_SRC_POS 4*FW-1
|
||||
#define MIX_LINE_WEIGHT_POS 11*FW+3
|
||||
#define MIX_LINE_CURVE_POS 12*FW+2
|
||||
@@ -3410,6 +3417,97 @@ void displayHeaderChannelName(uint8_t ch)
|
||||
}
|
||||
#endif
|
||||
|
||||
void displayMixInfos(uint8_t y, MixData *md)
|
||||
{
|
||||
#if defined(PCBTARANIS)
|
||||
putsCurveRef(MIX_LINE_CURVE_POS, y, md->curve, 0);
|
||||
#else
|
||||
if (md->curveParam) {
|
||||
if (md->curveMode == MODE_CURVE)
|
||||
putsCurve(MIX_LINE_CURVE_POS, y, md->curveParam);
|
||||
else
|
||||
displayGVar(MIX_LINE_CURVE_POS+3*FW, y, md->curveParam, -100, 100);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (md->swtch) {
|
||||
putsSwitches(MIX_LINE_SWITCH_POS, y, md->swtch);
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(PCBTARANIS)
|
||||
void displayMixLine(uint8_t y, MixData *md)
|
||||
{
|
||||
if (md->name[0]) {
|
||||
lcd_putsnAtt(EXPO_LINE_NAME_POS, y, md->name, sizeof(md->name), ZCHAR);
|
||||
}
|
||||
|
||||
if (!md->flightModes || ((md->curve.value || md->swtch) && ((get_tmr10ms() / 200) & 1)))
|
||||
displayMixInfos(y, md);
|
||||
else
|
||||
displayFlightModes(MIX_LINE_FM_POS, y, md->flightModes);
|
||||
}
|
||||
#elif defined(CPUARM)
|
||||
void displayMixLine(uint8_t y, MixData *md)
|
||||
{
|
||||
if (md->name[0]) {
|
||||
lcd_putsnAtt(EXPO_LINE_NAME_POS, y, md->name, sizeof(md->name), ZCHAR);
|
||||
}
|
||||
else {
|
||||
displayMixInfos(y, md);
|
||||
}
|
||||
}
|
||||
#else
|
||||
#define displayMixLine(y, md) displayMixInfos(y, md)
|
||||
#endif
|
||||
|
||||
void displayExpoInfos(uint8_t y, ExpoData *ed)
|
||||
{
|
||||
#if defined(PCBTARANIS)
|
||||
putsCurveRef(EXPO_LINE_CURVE_POS, y, ed->curve, 0);
|
||||
#else
|
||||
if (ed->curveMode == MODE_CURVE)
|
||||
putsCurve(EXPO_LINE_EXPO_POS-3*FW, y, ed->curveParam);
|
||||
else
|
||||
displayGVar(EXPO_LINE_EXPO_POS, y, ed->curveParam, -100, 100);
|
||||
#endif
|
||||
|
||||
putsSwitches(EXPO_LINE_SWITCH_POS, y, ed->swtch, 0);
|
||||
}
|
||||
|
||||
#if defined(PCBTARANIS)
|
||||
void displayExpoLine(uint8_t y, ExpoData *ed)
|
||||
{
|
||||
putsMixerSource(EXPO_LINE_SRC_POS, y, ed->srcRaw, 0);
|
||||
|
||||
if (ed->carryTrim != TRIM_ON) {
|
||||
lcd_putc(EXPO_LINE_TRIM_POS, y, ed->carryTrim > 0 ? '-' : STR_RETA123[-ed->carryTrim]);
|
||||
}
|
||||
|
||||
if (!ed->flightModes || ((ed->curve.value || ed->swtch) && ((get_tmr10ms() / 200) & 1)))
|
||||
displayExpoInfos(y, ed);
|
||||
else
|
||||
displayFlightModes(EXPO_LINE_FM_POS, y, ed->flightModes);
|
||||
|
||||
if (ed->name[0]) {
|
||||
lcd_putsnAtt(EXPO_LINE_NAME_POS, y, ed->name, sizeof(ed->name), ZCHAR);
|
||||
}
|
||||
}
|
||||
#elif defined(CPUARM)
|
||||
void displayExpoLine(uint8_t y, ExpoData *ed)
|
||||
{
|
||||
displayExpoInfos(y, ed);
|
||||
|
||||
if (ed->name[0]) {
|
||||
lcd_putsnAtt(EXPO_LINE_NAME_POS, y, ed->name, sizeof(ed->name), ZCHAR);
|
||||
}
|
||||
}
|
||||
#else
|
||||
#define displayExpoLine(y, ed) \
|
||||
displayExpoInfos(y, ed); \
|
||||
displayFlightModes(EXPO_LINE_FM_POS, y, ed->flightModes)
|
||||
#endif
|
||||
|
||||
void menuModelExpoMix(uint8_t expo, uint8_t event)
|
||||
{
|
||||
uint8_t sub = m_posVert;
|
||||
@@ -3609,34 +3707,10 @@ void menuModelExpoMix(uint8_t expo, uint8_t event)
|
||||
uint8_t attr = ((s_copyMode || sub != cur) ? 0 : INVERS);
|
||||
if (expo) {
|
||||
ed->weight = GVAR_MENU_ITEM(EXPO_LINE_WEIGHT_POS, y, ed->weight, MIN_EXPO_WEIGHT, 100, attr | (isExpoActive(i) ? BOLD : 0), 0, event);
|
||||
|
||||
#if defined(PCBTARANIS)
|
||||
putsMixerSource(EXPO_LINE_SRC_POS, y, ed->srcRaw, 0);
|
||||
#endif
|
||||
|
||||
#if defined(PCBTARANIS)
|
||||
if (ed->carryTrim != TRIM_ON)
|
||||
lcd_putc(EXPO_LINE_TRIM_POS, y, ed->carryTrim > 0 ? '-' : STR_RETA123[-ed->carryTrim]);
|
||||
putsCurveRef(EXPO_LINE_CURVE_POS, y, ed->curve, 0);
|
||||
#else
|
||||
if (ed->curveMode == MODE_CURVE)
|
||||
putsCurve(EXPO_LINE_EXPO_POS-3*FW, y, ed->curveParam);
|
||||
else
|
||||
displayGVar(EXPO_LINE_EXPO_POS, y, ed->curveParam, -100, 100);
|
||||
#endif
|
||||
|
||||
putsSwitches(EXPO_LINE_SWITCH_POS, y, ed->swtch, 0);
|
||||
|
||||
if (ed->mode!=3) lcd_putc(EXPO_LINE_SIDE_POS, y, ed->mode == 2 ? 126 : 127);
|
||||
|
||||
#if defined(CPUARM) && LCD_W >= 212
|
||||
if (ed->flightModes) lcd_puts(EXPO_LINE_FM_POS, y, STR_FP);
|
||||
if (ed->name[0]) lcd_putsnAtt(EXPO_LINE_NAME_POS, y, ed->name, sizeof(ed->name), ZCHAR | (isExpoActive(i) ? BOLD : 0));
|
||||
#elif defined(CPUARM)
|
||||
if (ed->name[0]) lcd_putsnAtt(EXPO_LINE_NAME_POS, y, ed->name, sizeof(ed->name), ZCHAR | (isExpoActive(i) ? BOLD : 0));
|
||||
#else
|
||||
displayFlightModes(EXPO_LINE_FM_POS, y, ed->flightModes);
|
||||
#endif
|
||||
displayExpoLine(y, ed);
|
||||
if (ed->mode!=3) {
|
||||
lcd_putc(EXPO_LINE_SIDE_POS, y, ed->mode == 2 ? 126 : 127);
|
||||
}
|
||||
}
|
||||
else {
|
||||
#if LCD_W >= 212
|
||||
@@ -3651,37 +3725,14 @@ void menuModelExpoMix(uint8_t expo, uint8_t event)
|
||||
|
||||
gvarWeightItem(MIX_LINE_WEIGHT_POS, y, md, attr | (isMixActive(i) ? BOLD : 0), event);
|
||||
|
||||
#if defined(CPUARM)
|
||||
if (md->name[0]) {
|
||||
lcd_putsnAtt(EXPO_LINE_NAME_POS, y, md->name, sizeof(md->name), ZCHAR | (isMixActive(i) ? BOLD : 0));
|
||||
}
|
||||
#if LCD_W < 212
|
||||
else
|
||||
#endif
|
||||
#endif
|
||||
{
|
||||
#if defined(PCBTARANIS)
|
||||
putsCurveRef(MIX_LINE_CURVE_POS, y, md->curve, 0);
|
||||
if (md->flightModes) lcd_puts(MIX_LINE_FM_POS, y, STR_FP);
|
||||
#else
|
||||
if (md->curveParam) {
|
||||
if (md->curveMode == MODE_CURVE)
|
||||
putsCurve(MIX_LINE_CURVE_POS, y, md->curveParam);
|
||||
else
|
||||
displayGVar(MIX_LINE_CURVE_POS+3*FW, y, md->curveParam, -100, 100);
|
||||
}
|
||||
#endif
|
||||
if (md->swtch) {
|
||||
putsSwitches(MIX_LINE_SWITCH_POS, y, md->swtch);
|
||||
}
|
||||
|
||||
char cs = ' ';
|
||||
if (md->speedDown || md->speedUp)
|
||||
cs = 'S';
|
||||
if ((md->delayUp || md->delayDown))
|
||||
cs = (cs =='S' ? '*' : 'D');
|
||||
lcd_putc(MIX_LINE_DELAY_POS, y, cs);
|
||||
}
|
||||
displayMixLine(y, md);
|
||||
|
||||
char cs = ' ';
|
||||
if (md->speedDown || md->speedUp)
|
||||
cs = 'S';
|
||||
if (md->delayUp || md->delayDown)
|
||||
cs = (cs =='S' ? '*' : 'D');
|
||||
lcd_putc(MIX_LINE_DELAY_POS, y, cs);
|
||||
}
|
||||
if (s_copyMode) {
|
||||
if ((s_copyMode==COPY_MODE || s_copyTgtOfs == 0) && s_copySrcCh == ch && i == (s_copySrcIdx + (s_copyTgtOfs<0))) {
|
||||
|
||||
@@ -48,7 +48,6 @@ bar_threshold_t barsThresholds[THLD_MAX];
|
||||
#endif
|
||||
|
||||
enum FrskyViews {
|
||||
TELEMETRY_VOLTAGES_SCREEN,
|
||||
CASE_LUA(TELEMETRY_LUA_SCREEN_1)
|
||||
CASE_LUA(TELEMETRY_LUA_SCREEN_2)
|
||||
CASE_LUA(TELEMETRY_LUA_SCREEN_3)
|
||||
@@ -59,11 +58,12 @@ enum FrskyViews {
|
||||
TELEMETRY_CUSTOM_SCREEN_1,
|
||||
TELEMETRY_CUSTOM_SCREEN_2,
|
||||
CASE_CPUARM(TELEMETRY_CUSTOM_SCREEN_3)
|
||||
TELEMETRY_VOLTAGES_SCREEN,
|
||||
TELEMETRY_AFTER_FLIGHT_SCREEN,
|
||||
FRSKY_VIEW_MAX = TELEMETRY_AFTER_FLIGHT_SCREEN
|
||||
};
|
||||
|
||||
uint8_t s_frsky_view = TELEMETRY_VOLTAGES_SCREEN;
|
||||
uint8_t s_frsky_view = 0;
|
||||
|
||||
#if LCD_W >= 212
|
||||
#define BAR_LEFT 26
|
||||
|
||||
+12
-10
@@ -52,8 +52,8 @@ extern "C" {
|
||||
#define lua_pushtablenil(L, k) (lua_pushstring(L, (k)), lua_pushnil(L), lua_settable(L, -3))
|
||||
#define lua_pushtableboolean(L, k, v) (lua_pushstring(L, (k)), lua_pushboolean(L, (v)), lua_settable(L, -3))
|
||||
#define lua_pushtablenumber(L, k, v) (lua_pushstring(L, (k)), lua_pushinteger(L, (v)), lua_settable(L, -3))
|
||||
#define lua_pushtablestring(L, k, v) (lua_pushstring(L, (k)), lua_pushstring(L, (v)), lua_settable(L, -3))
|
||||
#define lua_pushtablezstring(L, k, v) { char _zz[sizeof(v)+1]; zchar2str(_zz, (v), sizeof(v)); lua_pushstring(L, (k)); lua_pushstring(L, _zz); lua_settable(L, -3); }
|
||||
#define lua_pushtablestring(L, k, v) { char tmp[sizeof(v)+1]; strncpy(tmp, (v), sizeof(v)); tmp[sizeof(v)] = '\0'; lua_pushstring(L, (k)); lua_pushstring(L, tmp); lua_settable(L, -3); }
|
||||
#define lua_pushtablezstring(L, k, v) { char tmp[sizeof(v)+1]; zchar2str(tmp, (v), sizeof(v)); lua_pushstring(L, (k)); lua_pushstring(L, tmp); lua_settable(L, -3); }
|
||||
#define lua_registerlib(L, name, tab) (luaL_newmetatable(L, name), luaL_setfuncs(L, tab, 0), lua_setglobal(L, name))
|
||||
|
||||
lua_State *L = NULL;
|
||||
@@ -714,7 +714,7 @@ static int luaModelGetLogicalSwitch(lua_State *L)
|
||||
if (idx < NUM_LOGICAL_SWITCH) {
|
||||
LogicalSwitchData * sw = lswAddress(idx);
|
||||
lua_newtable(L);
|
||||
lua_pushtablenumber(L, "function", sw->func);
|
||||
lua_pushtablenumber(L, "func", sw->func);
|
||||
lua_pushtablenumber(L, "v1", sw->v1);
|
||||
lua_pushtablenumber(L, "v2", sw->v2);
|
||||
lua_pushtablenumber(L, "v3", sw->v3);
|
||||
@@ -733,11 +733,12 @@ static int luaModelSetLogicalSwitch(lua_State *L)
|
||||
int idx = luaL_checkunsigned(L, 1);
|
||||
if (idx < NUM_LOGICAL_SWITCH) {
|
||||
LogicalSwitchData * sw = lswAddress(idx);
|
||||
memclear(sw, sizeof(LogicalSwitchData));
|
||||
luaL_checktype(L, -1, LUA_TTABLE);
|
||||
for (lua_pushnil(L); lua_next(L, -2); lua_pop(L, 1)) {
|
||||
luaL_checktype(L, -2, LUA_TSTRING); // key is string
|
||||
const char * key = luaL_checkstring(L, -2);
|
||||
if (!strcmp(key, "function")) {
|
||||
if (!strcmp(key, "func")) {
|
||||
sw->func = luaL_checkinteger(L, -1);
|
||||
}
|
||||
else if (!strcmp(key, "v1")) {
|
||||
@@ -771,9 +772,9 @@ static int luaModelGetCustomFunction(lua_State *L)
|
||||
CustomFnData * cfn = &g_model.funcSw[idx];
|
||||
lua_newtable(L);
|
||||
lua_pushtablenumber(L, "switch", CFN_SWITCH(cfn));
|
||||
lua_pushtablenumber(L, "function", CFN_FUNC(cfn));
|
||||
lua_pushtablenumber(L, "func", CFN_FUNC(cfn));
|
||||
if (CFN_FUNC(cfn) == FUNC_PLAY_TRACK || CFN_FUNC(cfn) == FUNC_BACKGND_MUSIC || CFN_FUNC(cfn) == FUNC_PLAY_SCRIPT) {
|
||||
lua_pushtablezstring(L, "name", cfn->play.name);
|
||||
lua_pushtablestring(L, "name", cfn->play.name);
|
||||
}
|
||||
else {
|
||||
lua_pushtablenumber(L, "value", cfn->all.val);
|
||||
@@ -793,6 +794,7 @@ static int luaModelSetCustomFunction(lua_State *L)
|
||||
int idx = luaL_checkunsigned(L, 1);
|
||||
if (idx < NUM_CFN) {
|
||||
CustomFnData * cfn = &g_model.funcSw[idx];
|
||||
memclear(cfn, sizeof(CustomFnData));
|
||||
luaL_checktype(L, -1, LUA_TTABLE);
|
||||
for (lua_pushnil(L); lua_next(L, -2); lua_pop(L, 1)) {
|
||||
luaL_checktype(L, -2, LUA_TSTRING); // key is string
|
||||
@@ -800,12 +802,12 @@ static int luaModelSetCustomFunction(lua_State *L)
|
||||
if (!strcmp(key, "switch")) {
|
||||
CFN_SWITCH(cfn) = luaL_checkinteger(L, -1);
|
||||
}
|
||||
else if (!strcmp(key, "function")) {
|
||||
else if (!strcmp(key, "func")) {
|
||||
CFN_FUNC(cfn) = luaL_checkinteger(L, -1);
|
||||
}
|
||||
else if (!strcmp(key, "name")) {
|
||||
const char * name = luaL_checkstring(L, -1);
|
||||
str2zchar(cfn->play.name, name, sizeof(cfn->play.name));
|
||||
strncpy(cfn->play.name, name, sizeof(cfn->play.name));
|
||||
}
|
||||
else if (!strcmp(key, "value")) {
|
||||
cfn->all.val = luaL_checkinteger(L, -1);
|
||||
@@ -1282,7 +1284,7 @@ bool isTelemetryScriptAvailable(uint8_t index)
|
||||
{
|
||||
for (int i=0; i<luaScriptsCount; i++) {
|
||||
ScriptInternalData & sid = scriptInternalData[i];
|
||||
if (sid.reference == SCRIPT_TELEMETRY_FIRST+index) {
|
||||
if (sid.reference == SCRIPT_TELEMETRY_FIRST+index+1) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -1495,7 +1497,7 @@ void luaTask(uint8_t evt)
|
||||
#if defined(SIMU) || defined(DEBUG)
|
||||
filename = "[telem]";
|
||||
#endif
|
||||
if (g_menuStack[0]==menuTelemetryFrsky && sid.reference==SCRIPT_TELEMETRY_FIRST+s_frsky_view) {
|
||||
if (g_menuStack[0]==menuTelemetryFrsky && sid.reference==SCRIPT_TELEMETRY_FIRST+s_frsky_view+1) {
|
||||
lua_rawgeti(L, LUA_REGISTRYINDEX, sid.run);
|
||||
lua_pushinteger(L, evt);
|
||||
inputsCount = 1;
|
||||
|
||||
@@ -44,7 +44,13 @@
|
||||
#define DEBUG_STACK_SIZE 500
|
||||
|
||||
OS_TID menusTaskId;
|
||||
#if !defined(SIMU)
|
||||
// stack must be alligned to 8 bytes otherwise printf for %f does not work!
|
||||
OS_STK __attribute__((aligned(8))) menusStack[MENUS_STACK_SIZE];
|
||||
#else
|
||||
// but VC++ doesn't like the aligned keyword, so keep it as is on simu (which works)
|
||||
OS_STK menusStack[MENUS_STACK_SIZE];
|
||||
#endif
|
||||
|
||||
OS_TID mixerTaskId;
|
||||
OS_STK mixerStack[MIXER_STACK_SIZE];
|
||||
@@ -2713,7 +2719,7 @@ void perMain()
|
||||
usbStarted = true;
|
||||
}
|
||||
|
||||
#if defined(USB_JOYTICK)
|
||||
#if defined(USB_JOYSTICK)
|
||||
if (usbStarted) {
|
||||
if (!usbPlugged()) {
|
||||
//disable USB
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* German checked 30.05.2014 Test 016 kleine Änderungen
|
||||
/* German checked 26.06.2014 Test 019 Taranis, Th9, 9XR, 9XR-Pro
|
||||
* Authors (alphabetical order)
|
||||
* - Bertrand Songis <bsongis@gmail.com>
|
||||
* - Bernet Andre <bernet.andre@gmail.com>
|
||||
@@ -315,7 +315,7 @@
|
||||
#if defined(PCBTARANIS)
|
||||
#define TR_TELEM_RSSI_RX "RSSI\0"
|
||||
#else
|
||||
#define TR_TELEM_RSSI_RX TR("Rx\0 ", "Rx\0 ")
|
||||
#define TR_TELEM_RSSI_RX TR("Rx\0 ", "Rx\0 ")
|
||||
#endif
|
||||
|
||||
#if LCD_W >= 212
|
||||
@@ -500,14 +500,14 @@
|
||||
#endif
|
||||
#define TR_BITMAP "Modell Bild"
|
||||
#define TR_TIMER TR("Timer","Timer ")
|
||||
#define TR_ELIMITS TR("Erw.Limit","Erw. Wege auf 150%")
|
||||
#define TR_ETRIMS TR("Erw.Trims","Erw. Trim auf 100%")
|
||||
#define TR_ELIMITS TR("Erw. Limit","Erw. Wege auf 150%")
|
||||
#define TR_ETRIMS TR("Erw. Trims","Erw. Trim auf 100%")
|
||||
#define TR_TRIMINC TR("Trim Schr.","Trimm Schritte")
|
||||
#define TR_TTRACE TR("Gasquelle", INDENT "Gas TimerQuelle")
|
||||
#define TR_TTRIM TR("Gastrim", INDENT "Gas Leerlauf Trim")
|
||||
#define TR_BEEPCTR TR("Mitt.Piep","Mittelst. Pieps")
|
||||
#define TR_PROTO TR(INDENT"Proto.",INDENT"Protokoll")
|
||||
#define TR_PPMFRAME "PPM Einst."
|
||||
#define TR_PROTO TR(INDENT"Protok.",INDENT"Protokoll")
|
||||
#define TR_PPMFRAME " PPM Einst."
|
||||
#define TR_MS "ms"
|
||||
#define TR_SWITCH TR("Schalt.","Schalter")
|
||||
#define TR_TRIMS "Trims"
|
||||
@@ -548,24 +548,24 @@
|
||||
#define TR_MIXER "MISCHER"
|
||||
#define TR_CV "KV"
|
||||
#define TR_GV "GV"
|
||||
#define TR_ACHANNEL "A\004Kanal gemessen =>"
|
||||
#define TR_RANGE INDENT"Messbereich"
|
||||
#define TR_ACHANNEL TR("A\004gemessen","A\004Kanal gemessen =>") //9XR-Pro
|
||||
#define TR_RANGE TR(INDENT"Bereich",INDENT"Messbereich") //9XR-Pro
|
||||
#define TR_BAR "Streifen"
|
||||
#define TR_ALARM INDENT"Alarm"
|
||||
#define TR_USRDATA "Daten berechnen aus"
|
||||
#define TR_BLADES INDENT"Prop-Blätter"
|
||||
#define TR_BLADES TR(INDENT"Prop",INDENT"Prop-Blätter") //9XR-Pro
|
||||
#define TR_SCREEN "Telm-Bild "
|
||||
#define TR_SOUND_LABEL "----Töne---------"
|
||||
#define TR_LENGTH INDENT"Dauer"
|
||||
#define TR_BEEP_LENGTH INDENT "Beep Länge"
|
||||
#define TR_SPKRPITCH INDENT"Beep Freq. +/-"
|
||||
#define TR_HAPTIC_LABEL TR("Haptik","----Haptik-------")
|
||||
#define TR_HAPTIC_LABEL "----Haptik-------" //9XR-Pro
|
||||
#define TR_HAPTICSTRENGTH INDENT"Stärke"
|
||||
#define TR_CONTRAST "LCD Kontrast"
|
||||
#define TR_ALARMS_LABEL "----Alarm wenn---"
|
||||
#define TR_BATTERY_RANGE TR("Akku Bereich","Akku Spg-Bereich") // Symbol Akku Ladezustand
|
||||
#define TR_BATTERYWARNING INDENT"Akku Spg kleiner"
|
||||
#define TR_INACTIVITYALARM TR(INDENT"Inaktiv warnen",INDENT"Inaktivität nach")
|
||||
#define TR_INACTIVITYALARM TR(INDENT"Inaktivität",INDENT"Inaktivität nach") //9XR-Pro
|
||||
#define TR_MEMORYWARNING INDENT"Speicher voll"
|
||||
#define TR_ALARMWARNING INDENT"Töne ganz aus ?"
|
||||
#define TR_RENAVIG "Drehgeb. Navig."
|
||||
@@ -585,9 +585,9 @@
|
||||
#define TR_POTWARNING TR("Pot Warn.", INDENT "Poti Warnung")
|
||||
#define TR_TIMEZONE TR("Zeitzone","GPS Zeit Zone")
|
||||
#define TR_RXCHANNELORD TR("Kanalanordnung","Kanalvoreinstellung")
|
||||
#define TR_SWITCHES_DELAY "Switches Delay"
|
||||
#define TR_SWITCHES_DELAY TR("Sw. Mitte Delay","Schalter Mitte Verz.") //Schalter Mitten verzögern Anpassung
|
||||
#define TR_SLAVE TR("Schüler PPM1-16","Schüler PPM1-16 als Ausgang")
|
||||
#define TR_MODESRC " Modus\002% Quelle"
|
||||
#define TR_MODESRC " Modus\003% Quelle"
|
||||
#define TR_MULTIPLIER "Multiplikator"
|
||||
#define TR_CAL "Kal."
|
||||
#define TR_VTRIM "Trim- +"
|
||||
@@ -631,14 +631,14 @@
|
||||
#define TR_EEPROMOVERFLOW "EEPROM Überlauf"
|
||||
#define TR_MENURADIOSETUP TR("SENDER EINST.","SENDER GRUNDEINSTELLUNGEN")
|
||||
#define TR_MENUDATEANDTIME "DATUM UND ZEIT"
|
||||
#define TR_MENUTRAINER TR("Lehr./Schül.","LEHRER/SCHÜLER")
|
||||
#define TR_MENUTRAINER TR("LEHRER/SCHÜLER","LEHRER/SCHÜLER")
|
||||
#define TR_MENUVERSION "VERSION"
|
||||
#define TR_MENUDIAG TR("Schalt.","Schalter Test")
|
||||
#define TR_MENUANA "Analog Test"
|
||||
#define TR_MENUCALIBRATION TR("KALIB. ANALOG","KALIBRIERUNG STICKS+POTIS")
|
||||
#define TR_TRIMS2OFFSETS "Kopie Trim to Servo-Mitte" // "Trims => Offset"
|
||||
#define TR_MENUMODELSEL TR("MODELLE","MODELL WÄHLEN")
|
||||
#define TR_MENUSETUP TR("KONF.","MODELL EINSTELLUNGEN")
|
||||
#define TR_MENUSETUP TR("MODELL EINST.","MODELL EINSTELLUNGEN")
|
||||
#define TR_MENUFLIGHTPHASE "FLUGPHASE"
|
||||
#define TR_MENUFLIGHTPHASES "FLUGPHASEN"
|
||||
#define TR_MENUHELISETUP "HUBSCHRAUBER"
|
||||
@@ -648,7 +648,7 @@
|
||||
#define TR_MENULIMITS "SERVO WEG"
|
||||
#elif defined(PPM_CENTER_ADJUSTABLE) || defined(PPM_LIMITS_SYMETRICAL) // The right menu titles for the gurus ... #define TR_MENUDREXPO "KNÜPPEL"
|
||||
#define TR_MENUINPUTS "INPUTS"
|
||||
#define TR_MENULIMITS "Servo Weg"
|
||||
#define TR_MENULIMITS "SERVO WEG"
|
||||
#else
|
||||
#define TR_MENUINPUTS TR("DR/EXPO","DUALRATE/EXPO")
|
||||
#define TR_MENULIMITS TR("GRENZEN","SERVO WEG")
|
||||
@@ -667,29 +667,29 @@
|
||||
#define TR_MENUDEBUG "DEBUG"
|
||||
#define TR_RXNUM TR("Rx Nummer",INDENT"Empfänger Nr.")
|
||||
#define TR_SYNCMENU "Sync [MENU]"
|
||||
#define TR_LIMIT INDENT"Grenzen"
|
||||
#define TR_LIMIT INDENT"Grenzen"
|
||||
#define TR_MINRSSI "Min. RSSI"
|
||||
#define TR_LATITUDE "Breite:"
|
||||
#define TR_LONGITUDE "Länge:"
|
||||
#define TR_GPSCOORD TR("Gps Koord.","GPS Koordinaten Format")
|
||||
#define TR_VARIO TR("Vario","----Variometer----")
|
||||
#define TR_VARIO TR("----Vario--------","----Variometer----") //9XR-Pro
|
||||
#define TR_PITCH_AT_ZERO INDENT "Niedrigster Ton"
|
||||
#define TR_PITCH_AT_MAX INDENT "Höchster Ton"
|
||||
#define TR_REPEAT_AT_ZERO INDENT "Wiederholrate"
|
||||
#define TR_SHUTDOWN "Herunterfahren"
|
||||
#define TR_BATT_CALIB "Akku abgleichen"
|
||||
#define TR_CURRENT_CALIB "Stromkalib."
|
||||
#define TR_VOLTAGE TR(INDENT "Spannung",INDENT "Spannung Quelle")
|
||||
#define TR_CURRENT_CALIB "Strom abgl."
|
||||
#define TR_VOLTAGE TR(INDENT "Spg",INDENT "Spannung Quelle") //9XR-Pro
|
||||
#define TR_CURRENT TR(INDENT "Strom",INDENT "Strom Quelle")
|
||||
#define TR_SELECT_MODEL "Modell Wählen"
|
||||
#define TR_CREATE_MODEL "Neues Modell"
|
||||
#define TR_COPY_MODEL "Kopiere Modell"
|
||||
#define TR_MOVE_MODEL "Verschiebe Modell"
|
||||
#define TR_BACKUP_MODEL "Modell Backup auf SD"
|
||||
#define TR_BACKUP_MODEL "Modell auf SD card" //9XR-Pro
|
||||
#define TR_DELETE_MODEL "Modell Löschen" // TODO merged into DELETEMODEL?
|
||||
#define TR_RESTORE_MODEL "Modell Restore"
|
||||
#define TR_SDCARD_ERROR "SDcard Fehler"
|
||||
#define TR_NO_SDCARD "Keine SDcard"
|
||||
#define TR_SDCARD_ERROR "SD card Fehler"
|
||||
#define TR_NO_SDCARD "Keine SD card"
|
||||
#define TR_INCOMPATIBLE "Nicht kompatibel"
|
||||
#define TR_WARNING "WARNUNG"
|
||||
#define TR_EEPROMWARN "EEPROM"
|
||||
@@ -697,7 +697,7 @@
|
||||
#define TR_THROTTLEWARN "GAS"
|
||||
#define TR_ALARMSWARN "ALARM"
|
||||
#define TR_SWITCHWARN "SCHALTER"
|
||||
#define TR_INVERT_THR TR("Gas umkehren?","Vollgas hinten?") //Änderung wg Th9x
|
||||
#define TR_INVERT_THR TR("Gas umkehren?","Vollgas hinten?") // Th9x 9XR
|
||||
#define TR_SPEAKER_VOLUME INDENT "Lautstärke"
|
||||
#define TR_LCD "Bildschirm"
|
||||
#define TR_BRIGHTNESS INDENT "Helligkeit"
|
||||
@@ -706,8 +706,8 @@
|
||||
#define TR_CPU_MAH "Verbrauch"
|
||||
#define TR_COPROC "CoProz."
|
||||
#define TR_COPROC_TEMP "MB Temp. \016>"
|
||||
#define TR_CAPAWARNING INDENT "Kapaz. niedrig"
|
||||
#define TR_TEMPWARNING INDENT "Temperatur größer"
|
||||
#define TR_CAPAWARNING INDENT "Kapaz. niedrig" // wg 9XR-Pro
|
||||
#define TR_TEMPWARNING INDENT "Temp. größer" //wg 9XR-Pro
|
||||
#define TR_FUNC "Funktion"
|
||||
#define TR_V1 "V1"
|
||||
#define TR_V2 "V2"
|
||||
@@ -716,7 +716,7 @@
|
||||
#define TR_SD_CARD "SD Karte"
|
||||
#define TR_SDHC_CARD "SD-HC Karte"
|
||||
#define TR_NO_SOUNDS_ON_SD "Keine Töne auf SD"
|
||||
#define TR_NO_MODELS_ON_SD "Keine Modelle auf SD"
|
||||
#define TR_NO_MODELS_ON_SD "Kein Modell auf SD"
|
||||
#define TR_NO_BITMAPS_ON_SD "Keine Bitmaps auf SD"
|
||||
#define TR_NO_SCRIPTS_ON_SD "No Scripts on SD"
|
||||
#define TR_PLAY_FILE "Spielen"
|
||||
@@ -731,7 +731,7 @@
|
||||
#define TR_NA "N/V" //NV=Nicht Verfügbar Kurz-Meldung
|
||||
#define TR_HARDWARE "Hardware einstellen"
|
||||
#define TR_FORMATTING "Formattierung..."
|
||||
#define TR_TEMP_CALIB "Temp. Kalib."
|
||||
#define TR_TEMP_CALIB "Temp. abgl."
|
||||
#define TR_TIME "Uhrzeit:"
|
||||
#define TR_BAUDRATE "Baudrate"
|
||||
#define TR_SD_INFO_TITLE "SD INFO"
|
||||
@@ -754,11 +754,11 @@
|
||||
#define TR_WRITING "\032Writing..."
|
||||
#define TR_CONFIRM_FORMAT "Confirm Format?"
|
||||
#define TR_INTERNALRF "----Internes HF Modul----------"
|
||||
#define TR_EXTERNALRF "----Externes HF Modul----------"
|
||||
#define TR_EXTERNALRF TR("----Externes HF Modul---","----Externes HF Modul----------") //9XR-Pro
|
||||
#define TR_FAILSAFE "Failsafe Mode"
|
||||
#define TR_FAILSAFESET "Failsafe Einst."
|
||||
#define TR_COUNTRYCODE "Länder Code"
|
||||
#define TR_VOICELANG "Sprach-Ansagen"
|
||||
#define TR_VOICELANG "Sprach-Ansage"
|
||||
#define TR_UNITSSYSTEM "Einheiten"
|
||||
#define TR_EDIT "Zeile Editieren"
|
||||
#define TR_INSERT_BEFORE "Neue Zeile davor"
|
||||
@@ -788,7 +788,7 @@
|
||||
#define TR_MODELIDUSED TR("ID schon benutzt","Modell ID schon benutzt")
|
||||
#define TR_MODULE INDENT "Modul-Typ"
|
||||
#define TR_TELEMETRY_TYPE TR("Type", "Telemetry Type")
|
||||
#define TR_CHANNELRANGE INDENT "Ausgangs Kanäle"
|
||||
#define TR_CHANNELRANGE TR(INDENT "Kanäle", INDENT " Ausgangs Kanäle") //wg 9XR-Pro
|
||||
#define TR_LOWALARM INDENT "Vor-Alarm bei"
|
||||
#define TR_CRITICALALARM INDENT "Kritisch Alarm"
|
||||
#define TR_ENABLE_POPUP "Enable Popup"
|
||||
@@ -798,16 +798,16 @@
|
||||
#define TR_MIRROR "Spiegeln"
|
||||
#define TR_CLEAR "Löschen"
|
||||
#define TR_RESET "Reset Servowerte"
|
||||
#define TR_RESET_SUBMENU "Reset=>Timer Flug Telem"
|
||||
#define TR_RESET_SUBMENU TR("Reset Werte ==>","Reset=>Timer Flug Telem")
|
||||
#define TR_COUNT "Punkte"
|
||||
#define TR_PT "Pt"
|
||||
#define TR_PTS "Pts"
|
||||
#define TR_SMOOTH "Runden"
|
||||
#define TR_COPY_STICKS_TO_OFS "Kopie Stick to Servo-Mitte" // "Trims => Offset"
|
||||
#define TR_COPY_TRIMS_TO_OFS "Copy trims to subtrim"
|
||||
#define TR_PERSISTENT_MAH INDENT "Speichern mAh"
|
||||
#define TR_PERSISTENT_MAH TR(INDENT"Spr. mAh",INDENT "Speichern mAh") //9XR-Pro
|
||||
#define TR_PREFLIGHT "----Preflight Checks----"
|
||||
#define TR_CHECKLIST INDENT "Display Checklist"
|
||||
#define TR_CHECKLIST TR(INDENT "Checklist",INDENT "Display Checklist") //9XR-Pro
|
||||
#define TR_FAS_OFFSET TR(INDENT "FAS Ofs", INDENT "FAS Offset")
|
||||
#define TR_UART3MODE "Serial Port"
|
||||
#define TR_SCRIPT "Lua-Script"
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
#define TR_TRNCHN "ch1ch2ch3ch4"
|
||||
|
||||
#define LEN_UART3MODES "\017"
|
||||
#define TR_UART3MODES "OFF\0 ""Replica Porta-S""Telemetry\0 ""Debug\0 "
|
||||
#define TR_UART3MODES "OFF\0 ""Replica Porta-S""Telemetria\0 ""Debug\0 "
|
||||
|
||||
#define LEN_POTTYPES "\017"
|
||||
#define TR_POTTYPES "None\0 ""Potenziometro\0 ""Inter. Multipos"
|
||||
@@ -483,7 +483,7 @@
|
||||
#define OFS_EXIT sizeof(TR_ENTER)
|
||||
|
||||
#define TR_MENUWHENDONE CENTER "\007" TR_ENTER " Conferma"
|
||||
#define TR_FREE " Disp."
|
||||
#define TR_FREE "disp"
|
||||
#define TR_DELETEMODEL "Elimina modello?"
|
||||
#define TR_COPYINGMODEL "Copia in corso.."
|
||||
#define TR_MOVINGMODEL "Spostamento..."
|
||||
@@ -659,8 +659,8 @@
|
||||
#define TR_MENULOGICALSWITCH "INTER. PERSON."
|
||||
#define TR_MENULOGICALSWITCHES TR("INTER. LOGICI","INTERRUTTORI LOGICI")
|
||||
#define TR_MENUCUSTOMFUNC TR("FUNZ. SPECIALI","FUNZIONI SPECIALI")
|
||||
#define TR_MENUCUSTOMSCRIPTS "SCRIPTS PERSONALI"
|
||||
#define TR_MENUCUSTOMSCRIPT "SCRIPT PERSONALE"
|
||||
#define TR_MENUCUSTOMSCRIPTS "SCRIPTS UTENTE"
|
||||
#define TR_MENUCUSTOMSCRIPT "SCRIPT UTENTE"
|
||||
#define TR_MENUTELEMETRY "TELEMETRIA"
|
||||
#define TR_MENUTEMPLATES "ESEMPI GUIDA"
|
||||
#define TR_MENUSTAT "STATO"
|
||||
@@ -778,7 +778,7 @@
|
||||
#define TR_CF "CF"
|
||||
#define TR_SPEAKER INDENT"Speaker"
|
||||
#define TR_BUZZER INDENT"Buzzer"
|
||||
#define TR_BYTES "bytes"
|
||||
#define TR_BYTES "Bytes"
|
||||
#define TR_MODULE_BIND "[Bind]"
|
||||
#define TR_MODULE_RANGE "[Range]"
|
||||
#define TR_RESET_BTN "[Reset]"
|
||||
|
||||
Reference in New Issue
Block a user