+
Change Direction in TX To Match
+
+
+ Name |
+ MID |
+ MIN |
+ MAX |
+ CH-1 |
+ CH-2 |
+ CH-3 |
+ CH-4 |
+ AUX1 |
+ AUX2 |
+ AUX3 |
+ AUX4 |
+ Direction |
+
+
Gyroscope / Accelerometer Direction
-
Change Direction in TX To Match
-
-
- Name |
- MID |
- MIN |
- MAX |
- Throt | Roll | Pitch | Yaw | AUX1 | AUX2 | AUX3 | AUX4 |
- Direction |
-
-
Enable Live mode:
diff --git a/tabs/servos.js b/tabs/servos.js
index e2929494..71755455 100644
--- a/tabs/servos.js
+++ b/tabs/servos.js
@@ -57,16 +57,14 @@ function tab_initialize_servos() {
| \
| \
| \
-
\
- \
- \
- \
- \
- \
- \
- \
- \
- | \
+
| \
+
| \
+
| \
+
| \
+
| \
+
| \
+
| \
+
| \
\
' + name + '\
' + alternate + '\
@@ -76,7 +74,7 @@ function tab_initialize_servos() {
if (SERVO_CONFIG[obj].middle <= 7) {
$('div.tab-servos table.fields tr:last td.middle input').prop('disabled', true);
- $('div.tab-servos table.fields tr:last td.channel').find('input').eq(SERVO_CONFIG[obj].middle).prop('checked', true);
+ $('div.tab-servos table.fields tr:last td.channel input').eq(SERVO_CONFIG[obj].middle).prop('checked', true);
}
if (directions == true) {
@@ -107,10 +105,10 @@ function tab_initialize_servos() {
$('div.tab-servos table.fields tr:last').data('info', {'obj': obj});
// UI hooks
- $('div.tab-servos table.fields tr:last td.channel').find('input').click(function() {
+ $('div.tab-servos table.fields tr:last td.channel input').click(function() {
if($(this).is(':checked')) {
$(this).parent().parent().find('td.middle input').prop('disabled', true);
- $(this).parent().find('input').not($(this)).prop('checked', false);
+ $(this).parent().parent().find('.channel input').not($(this)).prop('checked', false);
} else {
$(this).parent().parent().find('td.middle input').prop('disabled', false).val(1500);
}
@@ -133,7 +131,8 @@ function tab_initialize_servos() {
var info = $(this).data('info');
if ($('.middle input', this).is(':disabled')) {
- var val = $('.channel input:checked', this).index();
+ var selection = $('.channel input', this);
+ var val = selection.index(selection.filter(':checked'));
SERVO_CONFIG[info.obj].middle = parseInt(val);
} else {
|