1
0
Fork 0
mirror of https://github.com/betaflight/betaflight-configurator.git synced 2025-07-26 17:55:24 +03:00

Merge pull request #2993 from haslinghuis/fix-auto-profile-cell-count-range

This commit is contained in:
J Blackman 2022-09-18 09:07:41 +10:00 committed by GitHub
commit 0718559f4f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 50 additions and 5 deletions

View file

@ -517,7 +517,7 @@ pid_tuning.initialize = function (callback) {
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_43)) {
$('.tab-pid_tuning input[name="motorLimit"]').val(FC.ADVANCED_TUNING.motorOutputLimit);
$('.tab-pid_tuning input[name="cellCount"]').val(FC.ADVANCED_TUNING.autoProfileCellCount);
$('.tab-pid_tuning select[name="cellCount"]').val(FC.ADVANCED_TUNING.autoProfileCellCount);
$('input[name="idleMinRpm-number"]').val(FC.ADVANCED_TUNING.idleMinRpm).prop('disabled', !FC.MOTOR_CONFIG.use_dshot_telemetry);
if (FC.MOTOR_CONFIG.use_dshot_telemetry) {
@ -1309,7 +1309,7 @@ pid_tuning.initialize = function (callback) {
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_43)) {
FC.FILTER_CONFIG.dyn_notch_max_hz = parseInt($('.pid_filter input[name="dynamicNotchMaxHz"]').val());
FC.ADVANCED_TUNING.motorOutputLimit = parseInt($('.tab-pid_tuning input[name="motorLimit"]').val());
FC.ADVANCED_TUNING.autoProfileCellCount = parseInt($('.tab-pid_tuning input[name="cellCount"]').val());
FC.ADVANCED_TUNING.autoProfileCellCount = parseInt($('.tab-pid_tuning select[name="cellCount"]').val());
FC.ADVANCED_TUNING.idleMinRpm = parseInt($('input[name="idleMinRpm-number"]').val());
const selectedRatesType = $('select[id="ratesType"]').val(); // send analytics for rates type