hooked up (mostly palceholder) text to various inputs

10.3.x-maintenance
cTn 2014-09-17 16:08:40 +02:00
parent ab8d8e1a56
commit c537616a39
4 changed files with 36 additions and 17 deletions

View File

@ -303,9 +303,27 @@
"configurationBoardAlignment": {
"message": "Board Alignment"
},
"configurationBoardAlignmentRoll": {
"message": "Roll Adjustment [deg]"
},
"configurationBoardAlignmentPitch": {
"message": "Pitch Adjustment [deg]"
},
"configurationBoardAlignmentYaw": {
"message": "Yaw Adjustment [deg]"
},
"configurationAccelTrimMagDec": {
"message": "Accelerometer & Magnetometer"
},
"configurationAccelTrimRoll": {
"message": "Accelerometer Roll Trim"
},
"configurationAccelTrimPitch": {
"message": "Accelerometer Pitch Trim"
},
"configurationMagDeclination": {
"message": "Magnetometer Declination [deg]"
},
"configurationThrottle": {
"message": "Throttle"
},

View File

@ -71,6 +71,7 @@
}
.tab-configuration .number span {
margin-left: 10px;
line-height: 20px;
}
.tab-configuration .buttons {
position: fixed;

View File

@ -21,19 +21,19 @@
<div class="number">
<label>
<input type="number" name="board_align_roll" step="1" min="-180" max="180" />
<span></span>
<span i18n="configurationBoardAlignmentRoll"></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="board_align_pitch" step="1" min="-180" max="180" />
<span></span>
<span i18n="configurationBoardAlignmentPitch"></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="board_align_yaw" step="1" min="-180" max="180" />
<span></span>
<span i18n="configurationBoardAlignmentYaw"></span>
</label>
</div>
</div>
@ -41,20 +41,20 @@
<div class="groupTitle" i18n="configurationAccelTrimMagDec"></div>
<div class="number">
<label>
<input type="number" name="pitch" min="-300" max="300" />
<span></span>
<input type="number" name="roll" min="-300" max="300" />
<span i18n="configurationAccelTrimRoll"></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="roll" min="-300" max="300" />
<span></span>
<input type="number" name="pitch" min="-300" max="300" />
<span i18n="configurationAccelTrimPitch"></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="mag_declination" step="0.1" min="-180" max="180" />
<span></span>
<span i18n="configurationMagDeclination"></span>
</label>
</div>
</div>
@ -64,25 +64,25 @@
<div class="number">
<label>
<input type="number" name="minthrottle" min="0" max="2000" />
<span></span>
<span i18n=""></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="maxthrottle" min="0" max="2000" />
<span></span>
<span i18n=""></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="failsafe_throttle" min="1000" max="2000" />
<span></span>
<span i18n=""></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="mincommand" min="0" max="2000" />
<span></span>
<span i18n=""></span>
</label>
</div>
</div>
@ -91,19 +91,19 @@
<div class="number">
<label>
<input type="number" name="mincellvoltage" step="0.1" min="1" max="5" />
<span></span>
<span i18n=""></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="maxcellvoltage" step="0.1" min="1" max="5" />
<span></span>
<span i18n=""></span>
</label>
</div>
<div class="number">
<label>
<input type="number" name="voltagescale" step="1" min="10" max="200" />
<span></span>
<span i18n=""></span>
</label>
</div>
</div>

View File

@ -125,8 +125,8 @@ TABS.configuration.initialize = function (callback) {
$('input[name="board_align_yaw"]').val(BF_CONFIG.board_align_yaw);
// fill accel trims
$('input[name="pitch"]').val(CONFIG.accelerometerTrims[0]);
$('input[name="roll"]').val(CONFIG.accelerometerTrims[1]);
$('input[name="pitch"]').val(CONFIG.accelerometerTrims[0]);
// fill magnetometer
$('input[name="mag_declination"]').val(MISC.mag_declination / 10);
@ -162,8 +162,8 @@ TABS.configuration.initialize = function (callback) {
BF_CONFIG.board_align_pitch = parseInt($('input[name="board_align_pitch"]').val());
BF_CONFIG.board_align_yaw = parseInt($('input[name="board_align_yaw"]').val());
CONFIG.accelerometerTrims[0] = parseInt($('input[name="pitch"]').val());
CONFIG.accelerometerTrims[1] = parseInt($('input[name="roll"]').val());
CONFIG.accelerometerTrims[0] = parseInt($('input[name="pitch"]').val());
MISC.mag_declination = parseFloat($('input[name="mag_declination"]').val()) * 10;
MISC.minthrottle = parseInt($('input[name="minthrottle"]').val());