1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-22 15:55:33 +03:00

Merge pull request #1381 from krzysztofmatula/km-on-arm-timer

OSD: combined ON/ARM timer
This commit is contained in:
Michael Keller 2019-04-19 13:39:25 +12:00 committed by GitHub
commit 2305e15e4d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -272,6 +272,7 @@ OSD.generateTimerPreview = function (osd_data, timer_index) {
var preview = '';
switch (osd_data.timers[timer_index].src) {
case 0:
case 3:
preview += FONT.symbol(SYM.ON_M);
break;
case 1:
@ -380,11 +381,6 @@ OSD.constants = {
'IMPERIAL',
'METRIC'
],
TIMER_TYPES: [
'ON TIME',
'TOTAL ARMED TIME',
'LAST ARMED TIME'
],
TIMER_PRECISION: [
'SECOND',
'HUNDREDTH'
@ -1391,7 +1387,16 @@ OSD.chooseFields = function () {
F.GPS_RESCUE_DISABLED
]);
}
OSD.constants.TIMER_TYPES = [
'ON TIME',
'TOTAL ARMED TIME',
'LAST ARMED TIME'
];
if (semver.gte(CONFIG.apiVersion, "1.42.0")) {
OSD.constants.TIMER_TYPES = OSD.constants.TIMER_TYPES.concat([
'ON/ARM TIME'
]);
OSD.constants.WARNINGS = OSD.constants.WARNINGS.concat([
F.RSSI,
F.LINK_QUALITY