diff options
author | Paweł Spychalski <pspychalski@gmail.com> | 2020-04-26 12:29:50 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-26 12:29:50 +0300 |
commit | 5f2db23d1c6a233e87462e7563fadf8bca660a4f (patch) | |
tree | 19bf93ef60d4dc0a8eaf316ae4105243ce69ad20 /js | |
parent | 6f87fde9f9f8ec5c8d7531b2012338cdf1e4d077 (diff) | |
parent | a23a3fe1e309f3ded7a1d27ad1906ce23c1fbeba (diff) |
Merge pull request #967 from iNavFlight/dzikuvx-improved-defaults-dialog
Improved defaults dialog
Diffstat (limited to 'js')
-rw-r--r-- | js/defaults_dialog.js | 62 |
1 files changed, 62 insertions, 0 deletions
diff --git a/js/defaults_dialog.js b/js/defaults_dialog.js index cc047579..eff60c3e 100644 --- a/js/defaults_dialog.js +++ b/js/defaults_dialog.js @@ -12,6 +12,7 @@ helper.defaultsDialog = (function() { let data = [{ "title": 'Mini Quad with 3"-7" propellers', + "notRecommended": false, "settings": [ /* System @@ -161,6 +162,10 @@ helper.defaultsDialog = (function() { value: 80 }, { + key: "platform_type", + value: "MULTIROTOR" + }, + { key: "applied_defaults", value: 2 } @@ -168,6 +173,7 @@ helper.defaultsDialog = (function() { }, { "title": 'Airplane', + "notRecommended": false, "id": 3, "settings": [ { @@ -195,6 +201,10 @@ helper.defaultsDialog = (function() { value: 180 }, { + key: "platform_type", + value: "AIRPLANE" + }, + { key: "applied_defaults", value: 3 } @@ -207,7 +217,54 @@ helper.defaultsDialog = (function() { ] }, { + "title": 'Rovers & Boats', + "notRecommended": false, + "settings": [ + { + key: "applied_defaults", + value: 1 + }, + { + key: "failsafe_procedure", + value: "DROP" + }, + { + key: "platform_type", + value: "ROVER" + }, + { + key: "nav_wp_safe_distance", + value: 50000 + }, + { + key: "nav_fw_loiter_radius", + value: 100 + }, + { + key: "nav_fw_yaw_deadband", + value: 5 + }, + { + key: "pidsum_limit_yaw", + value: 500 + }, + { + key: "nav_fw_pos_hdg_p", + value: 60 + }, + { + key: "nav_fw_pos_hdg_i", + value: 2 + }, + { + key: "nav_fw_pos_hdg_d", + value: 0 + } + ] + }, + { "title": 'Custom UAV - INAV legacy defaults (Not recommended)', + "notRecommended": true, "settings": [ { key: "applied_defaults", @@ -217,6 +274,7 @@ helper.defaultsDialog = (function() { }, { "title": 'Keep current settings (Not recommended)', + "notRecommended": true, "settings": [ { key: "applied_defaults", @@ -298,6 +356,10 @@ helper.defaultsDialog = (function() { <a class='confirm' href='#'></a>\ </div>") + if (preset.notRecommended) { + $element.addClass("defaults_btn--not-recommended"); + } + $element.find("a").html(preset.title); $element.data("index", i).click(privateScope.onPresetClick) $element.appendTo($place); |