Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/iNavFlight/inav-configurator.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaweł Spychalski <pspychalski@gmail.com>2018-12-15 16:41:59 +0300
committerGitHub <noreply@github.com>2018-12-15 16:41:59 +0300
commitb2b352794631b784997a4185c26fe381eac7a737 (patch)
treebaa2741f14c5bb7439fd47f4e5a4be9e810287b7
parenta5da3cb7b83b08a878bf2353b9f8eff51a7d1f6b (diff)
parentd398c3a143097a66424613548fde98a81edda78d (diff)
Merge pull request #611 from iNavFlight/dzikuvx-pid-tuning-tab-update
Update for PID Tuning tab
-rwxr-xr-x_locales/en/messages.json18
-rwxr-xr-xtabs/pid_tuning.html25
-rwxr-xr-xtabs/pid_tuning.js12
3 files changed, 53 insertions, 2 deletions
diff --git a/_locales/en/messages.json b/_locales/en/messages.json
index ab7a367b..dc768308 100755
--- a/_locales/en/messages.json
+++ b/_locales/en/messages.json
@@ -2838,5 +2838,23 @@
},
"mapApiKey": {
"message": "Map API key"
+ },
+ "accNotchHz": {
+ "message": "Acc. notch filter freq."
+ },
+ "accNotchHzHelp": {
+ "message": "Allow to set a single notch filter for accelerometer readout. Should be configured in the same way as gyro notch if accelerometer records a noise spike above acc. LPF filter"
+ },
+ "accNotchCutoff": {
+ "message": "Acc. notch filter cutoff freq."
+ },
+ "accNotchCutoffHelp": {
+ "message": "Should be kept below acc. notch filter frequency"
+ },
+ "gyroStage2LpfCutoffFrequency": {
+ "message": "Gyro Stage 2 LPF cutoff frequency"
+ },
+ "gyroStage2LpfCutoffFrequencyHelp": {
+ "message": "Second stage gyro low pass filter that is an equivalent of Betaflight not-Kalman stage2 filter. It has to be setup above first stage gyro LPF. For 5 and 6-inch miniquads, this usually means above 150Hz. 7-inch quads above 125Hz."
}
}
diff --git a/tabs/pid_tuning.html b/tabs/pid_tuning.html
index 8b767c53..efea282b 100755
--- a/tabs/pid_tuning.html
+++ b/tabs/pid_tuning.html
@@ -223,6 +223,13 @@
<div class="helpicon cf_tip" data-i18n_title="gyroLpfCutoffFrequencyHelp"></div>
</td>
</tr>
+ <tr class="requires-v2_1">
+ <th data-i18n="gyroStage2LpfCutoffFrequency"></th>
+ <td>
+ <input type="number" id="gyroStage2LpfCutoffFrequency" data-simple-bind="FILTER_CONFIG.gyroStage2LowpassHz" class="rate-tpa_input" step="1" min="0" max="500" /> Hz
+ <div class="helpicon cf_tip" data-i18n_title="gyroStage2LpfCutoffFrequencyHelp"></div>
+ </td>
+ </tr>
<tr>
<th data-i18n="accLpfCutoffFrequency"></th>
<td>
@@ -294,6 +301,20 @@
<div class="helpicon cf_tip" data-i18n_title="dtermNotchCutoffHelp"></div>
</td>
</tr>
+ <tr class="requires-v2_1">
+ <th data-i18n="accNotchHz"></th>
+ <td>
+ <input type="number" data-simple-bind="FILTER_CONFIG.accNotchHz" id="accNotchHz" class="rate-tpa_input" step="1" min="0" max="255" /> Hz
+ <div class="helpicon cf_tip" data-i18n_title="accNotchHzHelp"></div>
+ </td>
+ </tr>
+ <tr class="requires-v2_1">
+ <th data-i18n="accNotchCutoff"></th>
+ <td>
+ <input type="number" data-simple-bind="FILTER_CONFIG.accNotchCutoff" id="gyroNotchCutoff2" class="rate-tpa_input" step="1" min="0" max="500" /> Hz
+ <div class="helpicon cf_tip" data-i18n_title="accNotchCutoffHelp"></div>
+ </td>
+ </tr>
</tbody>
</table>
</div>
@@ -316,14 +337,14 @@
<div class="helpicon cf_tip" data-i18n_title="yawPLimitHelp"></div>
</td>
</tr>
- <tr>
+ <tr class="deprecated-v2_0">
<th data-i18n="rollPitchItermIgnoreRate"></th>
<td >
<input type="number" id="rollPitchItermIgnoreRate" class="rate-tpa_input" step="5" min="15" max="1000" />
<div class="helpicon cf_tip" data-i18n_title="rollPitchItermIgnoreRateHelp"></div>
</td>
</tr>
- <tr>
+ <tr class="deprecated-v2_0">
<th data-i18n="yawItermIgnoreRate"></th>
<td >
<input type="number" id="yawItermIgnoreRate" class="rate-tpa_input" step="5" min="15" max="1000" />
diff --git a/tabs/pid_tuning.js b/tabs/pid_tuning.js
index 12114333..4e24c32d 100755
--- a/tabs/pid_tuning.js
+++ b/tabs/pid_tuning.js
@@ -207,6 +207,18 @@ TABS.pid_tuning.initialize = function (callback) {
$('.requires-v1_6').hide();
}
+ if (semver.gte(CONFIG.flightControllerVersion, "2.0.0")) {
+ $('.deprecated-v2_0').hide();
+ } else {
+ $('.deprecated-v2_0').show();
+ }
+
+ if (semver.gte(CONFIG.flightControllerVersion, "2.1.0")) {
+ $('.requires-v2_1').show();
+ } else {
+ $('.requires-v2_1').hide();
+ }
+
GUI.simpleBind();
// UI Hooks