Merge pull request #1379 from iNavFlight/mrd_add_precision_to_osd_rpm

Added selectable precision to the OSD RPM
pull/1384/head
Paweł Spychalski 3 years ago committed by GitHub
commit 6022caa650
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -2798,6 +2798,12 @@
"osd_plus_code_short": {
"message" : "Plus Code Remove Leading Digits"
},
"osd_esc_rpm_precision": {
"message": "ESC RPM precision"
},
"osd_esc_rpm_precision_help": {
"message": "The number of digits shown in the RPM display. If the RPM is higher than the number of digits, it will be shown in thousand RPM with as many decimal places as allowed."
},
"osd_crosshairs_style": {
"message" : "Crosshairs Style"
},

@ -75,6 +75,11 @@
<select class="update_preview" data-setting="osd_plus_code_short" data-live="true"></select>
<span data-i18n="osd_plus_code_short"></span>
</label>
<div class="helpicon cf_tip" data-i18n_title="osd_esc_rpm_precision_help"></div>
<label>
<select class="update_preview" data-setting="osd_esc_rpm_precision" data-live="true"></select>
<span data-i18n="osd_esc_rpm_precision"></span>
</label>
<label>
<select class="update_preview" data-setting="osd_crosshairs_style" data-live="true"></select>
<span data-i18n="osd_crosshairs_style"></span>

@ -900,7 +900,10 @@ OSD.constants = {
name: 'ESC_RPM',
id: 106,
min_version: '2.3.0',
preview: FONT.symbol(SYM.RPM) + '983',
preview: function(){
let rpmPreview = '112974'.substr((6 - parseInt(Settings.getInputValue('osd_esc_rpm_precision'))));
return FONT.symbol(SYM.RPM) + rpmPreview;
}
},
{
name: 'GLIDESLOPE',

Loading…
Cancel
Save