Skip to content

Commit

Permalink
Simplify motor idle config (#3573)
Browse files Browse the repository at this point in the history
  • Loading branch information
haslinghuis authored Sep 16, 2023
1 parent 7c8ba06 commit 4010fe3
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
7 changes: 2 additions & 5 deletions locales/en/messages.json
Original file line number Diff line number Diff line change
Expand Up @@ -1340,11 +1340,8 @@
"configurationDigitalIdlePercent": {
"message": "Motor Idle ( %, static)"
},
"configurationDigitalIdlePercentDisabled": {
"message": "Dynamic Idle is active at {{dynamicIdle}} rpm. See the PID tuning tab."
},
"configurationDigitalIdlePercentHelp": {
"message": "The 'Motor Idle (static)' value is the percent of maximum throttle that is sent to the ESCs when the throttle at minimum stick position and the craft is armed. <br><br>Increase it to gain more idle speed and avoid desyncs. Too high and the craft feels floaty. Too low and the motors can desync or be slow to start up.<br><br>In 4.3, when Dynamic Idle is active, the static idle value is disregarded, because the idle value is continually adjusted to maintain the configured minimum rpm on the slowest motor."
"message": "The 'Motor Idle (static)' value is the percent of maximum throttle that is sent to the ESCs when the throttle at minimum stick position and the craft is armed. <br><br>Increase it to gain more idle speed and avoid desyncs. Too high and the craft feels floaty. Too low and the motors can desync or be slow to start up."
},
"configurationMotorPoles": {
"message": "Motor poles",
Expand Down Expand Up @@ -4526,7 +4523,7 @@
"message": "Dynamic Idle Value [* 100 RPM]"
},
"pidTuningIdleMinRpmHelp": {
"message": "Dynamic Idle improves control at low rpm and reduces risk of motor desyncs. <br /><br /> It improves PID authority, zero throttle stability, inverted hang time, and motor braking.<br /><br />The Dynamic Idle min rpm should be set to around 3000 - 3500 rpm. For 4.2, set the DShot idle value low, eg 1%. There is no need to adjust the DShot Idle value in 4.3. <br /><br />Visit <a href=\"https://betaflight.com/docs/wiki/archive/Tuning-Dynamic-Idle\" target=\"_blank\" rel=\"noopener noreferrer\">this wiki entry</a> for more info."
"message": "Dynamic Idle improves control at low rpm and reduces risk of motor desyncs. <br /><br /> It improves PID authority, zero throttle stability, inverted hang time, and motor braking.<br /><br />The Dynamic Idle min rpm should be set to around 3000 - 3500 rpm. <br /><br />Visit <a href=\"https://betaflight.com/docs/wiki/archive/Tuning-Dynamic-Idle\" target=\"_blank\" rel=\"noopener noreferrer\">this wiki entry</a> for more info."
},
"pidTuningIdleMinRpmDisabled": {
"message": "Dynamic Idle is OFF because Dshot Telemetry is OFF"
Expand Down
10 changes: 7 additions & 3 deletions src/js/tabs/motors.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import FC from "../fc";
import MSP from "../msp";
import { mixerList } from "../model";
import MSPCodes from "../msp/MSPCodes";
import { API_VERSION_1_42, API_VERSION_1_44 } from "../data_storage";
import { API_VERSION_1_42, API_VERSION_1_44, API_VERSION_1_46 } from "../data_storage";
import EscProtocols from "../utils/EscProtocols";
import { updateTabList } from "../utils/updateTabList";
import { isInt, getMixerImageSrc } from "../utils/common";
Expand Down Expand Up @@ -777,8 +777,12 @@ motors.initialize = async function (callback) {
}

if (FC.ADVANCED_TUNING.idleMinRpm && FC.MOTOR_CONFIG.use_dshot_telemetry) {
const dynamicIdle = FC.ADVANCED_TUNING.idleMinRpm * 100;
$('span.digitalIdlePercentDisabled').text(i18n.getMessage('configurationDigitalIdlePercentDisabled', { dynamicIdle }));
if (semver.gte(FC.CONFIG.apiVersion, API_VERSION_1_46)) {
$('div.digitalIdlePercent').hide();
} else {
const dynamicIdle = FC.ADVANCED_TUNING.idleMinRpm * 100;
$('span.digitalIdlePercentDisabled').text(i18n.getMessage('configurationDigitalIdlePercentDisabled', { dynamicIdle }));
}
} else {
$('span.digitalIdlePercentDisabled').text(i18n.getMessage('configurationDigitalIdlePercent'));
}
Expand Down

0 comments on commit 4010fe3

Please sign in to comment.