no modifications to motor values in 3d mode if msp 3d isn't supported
parent
e8cc7751af
commit
da4f916f10
|
@ -328,6 +328,7 @@ TABS.motors.initialize = function (callback) {
|
||||||
$('div.sliders input').val(MISC.mincommand);
|
$('div.sliders input').val(MISC.mincommand);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(self.allowTestMode){
|
||||||
// UI hooks
|
// UI hooks
|
||||||
var buffering_set_motor = [],
|
var buffering_set_motor = [],
|
||||||
buffer_delay = false;
|
buffer_delay = false;
|
||||||
|
@ -359,6 +360,7 @@ TABS.motors.initialize = function (callback) {
|
||||||
}, 10);
|
}, 10);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
$('div.sliders input.master').on('input', function () {
|
$('div.sliders input.master').on('input', function () {
|
||||||
var val = $(this).val();
|
var val = $(this).val();
|
||||||
|
@ -385,7 +387,6 @@ TABS.motors.initialize = function (callback) {
|
||||||
$('div.sliders input').val(MISC.mincommand);
|
$('div.sliders input').val(MISC.mincommand);
|
||||||
}
|
}
|
||||||
|
|
||||||
// trigger change event so values are sent to mcu
|
|
||||||
$('div.sliders input').trigger('input');
|
$('div.sliders input').trigger('input');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -394,7 +395,7 @@ TABS.motors.initialize = function (callback) {
|
||||||
var motors_running = false;
|
var motors_running = false;
|
||||||
|
|
||||||
for (var i = 0; i < number_of_valid_outputs; i++) {
|
for (var i = 0; i < number_of_valid_outputs; i++) {
|
||||||
if( ! bit_check(BF_CONFIG.features,12) ){
|
if( !self.feature3DEnabled ){
|
||||||
if (MOTOR_DATA[i] > MISC.mincommand) {
|
if (MOTOR_DATA[i] > MISC.mincommand) {
|
||||||
motors_running = true;
|
motors_running = true;
|
||||||
break;
|
break;
|
||||||
|
@ -408,7 +409,7 @@ TABS.motors.initialize = function (callback) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (motors_running) {
|
if (motors_running) {
|
||||||
if (!self.armed) {
|
if (!self.armed && self.allowTestMode) {
|
||||||
$('#motorsEnableTestMode').prop('checked', true);
|
$('#motorsEnableTestMode').prop('checked', true);
|
||||||
}
|
}
|
||||||
// motors are running adjust sliders to current values
|
// motors are running adjust sliders to current values
|
||||||
|
|
Loading…
Reference in New Issue