Default autopilot tweaks.
This commit is contained in:
parent
065c893dca
commit
a180a0d659
3 changed files with 17 additions and 11 deletions
|
@ -318,7 +318,7 @@
|
||||||
<prop>/autopilot/internal/target-climb-rate-fps</prop>
|
<prop>/autopilot/internal/target-climb-rate-fps</prop>
|
||||||
</output>
|
</output>
|
||||||
<config>
|
<config>
|
||||||
<Kp>1.0</Kp> <!-- proportional gain -->
|
<Kp>0.5</Kp> <!-- proportional gain -->
|
||||||
<beta>1.0</beta> <!-- input value weighing factor -->
|
<beta>1.0</beta> <!-- input value weighing factor -->
|
||||||
<alpha>0.1</alpha> <!-- low pass filter weighing factor -->
|
<alpha>0.1</alpha> <!-- low pass filter weighing factor -->
|
||||||
<gamma>0.0</gamma> <!-- input value weighing factor for -->
|
<gamma>0.0</gamma> <!-- input value weighing factor for -->
|
||||||
|
@ -469,7 +469,8 @@
|
||||||
<value>speed-with-throttle</value>
|
<value>speed-with-throttle</value>
|
||||||
</enable>
|
</enable>
|
||||||
<input>
|
<input>
|
||||||
<prop>/autopilot/internal/lookahead-5-sec-airspeed-kt</prop>
|
<!-- <prop>/autopilot/internal/lookahead-5-sec-airspeed-kt</prop> -->
|
||||||
|
<prop>/velocities/airspeed-kt</prop>
|
||||||
</input>
|
</input>
|
||||||
<reference>
|
<reference>
|
||||||
<prop>/autopilot/settings/target-speed-kt</prop>
|
<prop>/autopilot/settings/target-speed-kt</prop>
|
||||||
|
@ -477,6 +478,12 @@
|
||||||
<output>
|
<output>
|
||||||
<prop>/controls/engines/engine[0]/throttle</prop>
|
<prop>/controls/engines/engine[0]/throttle</prop>
|
||||||
<prop>/controls/engines/engine[1]/throttle</prop>
|
<prop>/controls/engines/engine[1]/throttle</prop>
|
||||||
|
<prop>/controls/engines/engine[2]/throttle</prop>
|
||||||
|
<prop>/controls/engines/engine[3]/throttle</prop>
|
||||||
|
<prop>/controls/engines/engine[4]/throttle</prop>
|
||||||
|
<prop>/controls/engines/engine[5]/throttle</prop>
|
||||||
|
<prop>/controls/engines/engine[6]/throttle</prop>
|
||||||
|
<prop>/controls/engines/engine[7]/throttle</prop>
|
||||||
</output>
|
</output>
|
||||||
<config>
|
<config>
|
||||||
<Kp>0.1</Kp> <!-- proportional gain -->
|
<Kp>0.1</Kp> <!-- proportional gain -->
|
||||||
|
@ -491,13 +498,13 @@
|
||||||
</config>
|
</config>
|
||||||
</pid-controller>
|
</pid-controller>
|
||||||
|
|
||||||
<!-- Hold speed by varying pitch (Two stage cascading controller) -->
|
<!-- Hold speed by varying pitch trim (Two stage cascading controller) -->
|
||||||
<pid-controller>
|
<pid-controller>
|
||||||
<name>Speed hold (vary pitch) Stage #1</name>
|
<name>Speed hold (vary pitch trim) Stage #1</name>
|
||||||
<debug>false</debug>
|
<debug>false</debug>
|
||||||
<enable>
|
<enable>
|
||||||
<prop>/autopilot/locks/speed</prop>
|
<prop>/autopilot/locks/speed</prop>
|
||||||
<value>speed-with-pitch</value>
|
<value>speed-with-pitch-trim</value>
|
||||||
</enable>
|
</enable>
|
||||||
<input>
|
<input>
|
||||||
<prop>/autopilot/internal/lookahead-5-sec-airspeed-kt</prop>
|
<prop>/autopilot/internal/lookahead-5-sec-airspeed-kt</prop>
|
||||||
|
@ -522,11 +529,11 @@
|
||||||
</pid-controller>
|
</pid-controller>
|
||||||
|
|
||||||
<pid-controller>
|
<pid-controller>
|
||||||
<name>Speed hold (vary pitch) Stage #2</name>
|
<name>Speed hold (vary pitch trim) Stage #2</name>
|
||||||
<debug>false</debug>
|
<debug>false</debug>
|
||||||
<enable>
|
<enable>
|
||||||
<prop>/autopilot/locks/speed</prop>
|
<prop>/autopilot/locks/speed</prop>
|
||||||
<value>speed-with-pitch</value>
|
<value>speed-with-pitch-trim</value>
|
||||||
</enable>
|
</enable>
|
||||||
<input>
|
<input>
|
||||||
<prop>/orientation/pitch-deg</prop>
|
<prop>/orientation/pitch-deg</prop>
|
||||||
|
|
|
@ -268,8 +268,7 @@ incElevator = func {
|
||||||
if ( elevator.getValue() > 1.0 ) {
|
if ( elevator.getValue() > 1.0 ) {
|
||||||
elevator.setValue( 1.0 );
|
elevator.setValue( 1.0 );
|
||||||
}
|
}
|
||||||
}
|
} elsif ( auto.getValue() == "altitude-hold" ) {
|
||||||
if ( auto.getValue() == "altitude-hold" ) {
|
|
||||||
node = props.globals.getNode("/autopilot/settings/target-altitude-ft", 1);
|
node = props.globals.getNode("/autopilot/settings/target-altitude-ft", 1);
|
||||||
if ( node.getValue() == nil ) {
|
if ( node.getValue() == nil ) {
|
||||||
node.setValue( 0.0 );
|
node.setValue( 0.0 );
|
||||||
|
|
|
@ -343,7 +343,7 @@
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<input>
|
<input>
|
||||||
<name>autospeed-w-pitch</name>
|
<name>autospeed</name>
|
||||||
<x>150</x>
|
<x>150</x>
|
||||||
<y>130</y>
|
<y>130</y>
|
||||||
<width>150</width>
|
<width>150</width>
|
||||||
|
@ -400,7 +400,7 @@
|
||||||
<command>nasal</command>
|
<command>nasal</command>
|
||||||
<script>
|
<script>
|
||||||
node = props.globals.getNode("/autopilot/locks/speed", 1);
|
node = props.globals.getNode("/autopilot/locks/speed", 1);
|
||||||
node.setValue( "speed-with-pitch" );
|
node.setValue( "speed-with-pitch-trim" );
|
||||||
</script>
|
</script>
|
||||||
</binding>
|
</binding>
|
||||||
<binding>
|
<binding>
|
||||||
|
|
Loading…
Add table
Reference in a new issue