1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-19 14:25:14 +03:00

Added warning when connecting to firmware newer than configurator.

This commit is contained in:
mikeller 2020-03-28 16:20:26 +13:00
parent b00063c36c
commit eb6e269467
16 changed files with 120 additions and 94 deletions

View file

@ -313,7 +313,7 @@ TABS.failsafe.initialize = function (callback, scrollPosition) {
$('input[name="gps_rescue_min_sats"]').val(GPS_RESCUE.minSats);
$('select[name="gps_rescue_sanity_checks"]').val(GPS_RESCUE.sanityChecks);
if (semver.gte(CONFIG.apiVersion, "1.43.0")) {
if (semver.gte(CONFIG.apiVersion, API_VERSION_1_43)) {
$('input[name="gps_rescue_ascend_rate"]').val((GPS_RESCUE.ascendRate / 100).toFixed(2));
$('input[name="gps_rescue_descend_rate"]').val((GPS_RESCUE.descendRate / 100).toFixed(2));
$('input[name="gps_rescue_allow_arming_without_fix"]').prop('checked', GPS_RESCUE.allowArmingWithoutFix > 0);
@ -379,7 +379,7 @@ TABS.failsafe.initialize = function (callback, scrollPosition) {
GPS_RESCUE.sanityChecks = $('select[name="gps_rescue_sanity_checks"]').val();
}
if (semver.gte(CONFIG.apiVersion, "1.43.0")) {
if (semver.gte(CONFIG.apiVersion, API_VERSION_1_43)) {
GPS_RESCUE.ascendRate = $('input[name="gps_rescue_ascend_rate"]').val() * 100;
GPS_RESCUE.descendRate = $('input[name="gps_rescue_descend_rate"]').val() * 100;
GPS_RESCUE.allowArmingWithoutFix = $('input[name="gps_rescue_allow_arming_without_fix"]').prop('checked') ? 1 : 0;