diff --git a/_locales/en/messages.json b/_locales/en/messages.json index ebcfd294..91e33056 100755 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -503,9 +503,18 @@ "configurationBatteryMultiwiiCurrent": { "message": "Enable support for legacy Multiwii MSP current output" }, - "configurationLoopTimeHead": { + "configurationSystem": { + "message": "System configuration" + }, + "configurationLoopTime": { "message": "Flight Controller Loop Time" }, + "configurationCalculatedCyclesSec": { + "message": "Cycles/Sec (Hz)" + }, + "configurationLoopTimeHelp": { + "message": "Note: Changing this may require PID re-tuning." + }, "configurationGPS": { "message": "GPS" }, @@ -519,7 +528,7 @@ "message": "Ground Assistance Type" }, "configurationGPSHelp": { - "message": "Note: Rememer to configure a Serial Port (via Ports tab) when using GPS feature." + "message": "Note: Remember to configure a Serial Port (via Ports tab) when using GPS feature." }, "configurationSerialRX": { diff --git a/changelog.html b/changelog.html index 4a5df904..09720a49 100644 --- a/changelog.html +++ b/changelog.html @@ -6,7 +6,6 @@

2015.05.23 - 0.65.0 - cleanflight

- - Configuration tab supports setting FC loop time - Requires 1.8.0 firmware.
- Support flashing of the SPRacingF3.
- Support manual baud rate configuration for flashing.

diff --git a/tabs/configuration.css b/tabs/configuration.css index 2d8c7434..fe48e434 100644 --- a/tabs/configuration.css +++ b/tabs/configuration.css @@ -99,6 +99,13 @@ border: 1px solid silver; } + +.tab-configuration .number input.disabled { + width: 50px; + padding: 0px 5px; + background-color: #ececec; +} + .tab-configuration .number span { margin-left: 10px; line-height: 20px; @@ -154,27 +161,6 @@ .tab-configuration .disarm .checkbox span { margin-left: 15px; } -.tab-configuration .cycles { - border-bottom: 1px solid #dddddd; - margin-top: 16px; -} -.tab-configuration .block { - float: left; - display: block; - border: 1px solid silver; -} -.tab-configuration .block .head { - display: block; - text-align: center; - line-height: 20px; - font-weight: bold; - border-bottom: 1px solid silver; - background-color: #ececec; -} -.tab-configuration .block.looptime { - width: 200px; - margin-top: 11px; -} .tab-configuration .save { display: block; float: right; diff --git a/tabs/configuration.html b/tabs/configuration.html index 1a82b07c..a53226a0 100644 --- a/tabs/configuration.html +++ b/tabs/configuration.html @@ -131,19 +131,6 @@

-
- - - - - - - - - - - -
@@ -163,8 +150,6 @@ - -
@@ -205,7 +190,7 @@
-
+
@@ -238,14 +223,41 @@ - +
+ +
+
+
+ + + + + + + + + + +
+ +
+
+
+ +
+
+ +
+

+
+
@@ -307,6 +319,7 @@
+
diff --git a/tabs/configuration.js b/tabs/configuration.js index ade7a696..1e5f5e55 100644 --- a/tabs/configuration.js +++ b/tabs/configuration.js @@ -49,6 +49,17 @@ TABS.configuration.initialize = function (callback, scrollPosition) { MSP.send_message(MSP_codes.MSP_IDENT, false, false, load_config); + function recalculate_cycles_sec() { + var looptime = $('input[name="looptime"]').val(); + + var message = 'Max'; + if (looptime > 0) { + message = parseFloat((1 / looptime) * 1000 * 1000).toFixed(0); + } + + $('input[name="looptimehz"]').val(message); + } + function process_html() { // translate to user-selected language localize(); @@ -278,10 +289,8 @@ TABS.configuration.initialize = function (callback, scrollPosition) { // fill FC loop time $('input[name="looptime"]').val(FC_CONFIG.loopTime); - if(FC_CONFIG.loopTime > 0) - $('span.looptimehz').text(parseFloat((1/FC_CONFIG.loopTime)*1000*1000).toFixed(0) + ' Cycles per Sec'); - else - $('span.looptimehz').text('Maximum Cycles per Sec'); + + recalculate_cycles_sec(); $('div.cycles').show(); } @@ -307,11 +316,7 @@ TABS.configuration.initialize = function (callback, scrollPosition) { // UI hooks $('input[name="looptime"]').change(function() { - FC_CONFIG.loopTime = parseInt($('input[name="looptime"]').val()); - if(FC_CONFIG.loopTime > 0) - $('span.looptimehz').text(parseFloat((1/FC_CONFIG.loopTime)*1000*1000).toFixed(0) + ' Cycles per Sec'); - else - $('span.looptimehz').text('Maximum Cycles per Sec'); + recalculate_cycles_sec(); }); $('input[type="checkbox"].feature', features_e).change(function () {