SchmengieMoTahHah.xml 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744
  1. <?xml version="1.0"?>
  2. <!-- Rockwell B-1B (basic taken from 787 and modified) Autopilot Configuration -->
  3. <!-- Each component is evaluated in the order specified. You can make up -->
  4. <!-- property names to pass the result of one component on to a subsequent -->
  5. <!-- component. -->
  6. <PropertyList>
  7. <!-- =============================================================== -->
  8. <!-- Prediction filters -->
  9. <!-- =============================================================== -->
  10. <predict-simple>
  11. <input>/autopilot/internal/nav1-track-error-deg</input>
  12. <output>/autopilot/internal/nav1-track-error-lookahead-deg</output>
  13. <seconds>10</seconds>
  14. <filter-gain>0.0</filter-gain>
  15. </predict-simple>
  16. <!-- =============================================================== -->
  17. <!-- Roll Axis Modes -->
  18. <!-- =============================================================== -->
  19. <!-- Wing leveler -->
  20. <pid-controller>
  21. <name>Wing Leveler (Turn Coordinator based)</name>
  22. <debug>false</debug>
  23. <enable>
  24. <prop>/autopilot/locks/heading</prop>
  25. <value>wing-leveler</value>
  26. </enable>
  27. <input>
  28. <prop>/instrumentation/turn-indicator/indicated-turn-rate</prop>
  29. </input>
  30. <reference>
  31. <value>0.0</value>
  32. </reference>
  33. <output>
  34. <prop>/controls/flight/aileron</prop>
  35. </output>
  36. <config>
  37. <Kp>0.5</Kp> <!-- proportional gain -->
  38. <beta>1.0</beta> <!-- input value weighing factor -->
  39. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  40. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  41. <!-- unfiltered derivative error -->
  42. <Ti>10.0</Ti> <!-- integrator time -->
  43. <Td>0.00001</Td> <!-- derivator time -->
  44. <u_min>-4.8</u_min> <!-- minimum output clamp -->
  45. <u_max>4.8</u_max> <!-- maximum output clamp -->
  46. </config>
  47. </pid-controller>
  48. <!-- Heading Bug Hold. 2 stage cascade controller. -->
  49. <!-- Stage #1 sets target roll based on diff between current heading -->
  50. <!-- and heading bug. -->
  51. <pid-controller>
  52. <name>Heading Bug Hold (FDM mag heading based) Stage 1</name>
  53. <debug>false</debug>
  54. <enable>
  55. <prop>/autopilot/locks/heading</prop>
  56. <value>dg-heading-hold</value>
  57. </enable>
  58. <input>
  59. <prop>/autopilot/internal/fdm-heading-bug-error-deg</prop>
  60. </input>
  61. <reference>
  62. <value>0.0</value>
  63. </reference>
  64. <output>
  65. <prop>/autopilot/internal/target-roll-deg</prop>
  66. </output>
  67. <config>
  68. <Kp>-8.0</Kp> <!-- proportional gain -->
  69. <beta>1.0</beta> <!-- input value weighing factor -->
  70. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  71. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  72. <!-- unfiltered derivative error -->
  73. <Ti>10.0</Ti> <!-- integrator time -->
  74. <Td>0.005</Td> <!-- derivator time -->
  75. <u_min>-66.0</u_min> <!-- minimum output clamp -->
  76. <u_max>66.0</u_max> <!-- maximum output clamp -->
  77. </config>
  78. </pid-controller>
  79. <!-- Stage #2 drives the ailerons to achieve the desired roll deg. -->
  80. <pid-controller>
  81. <name>Heading Bug Hold (DG based) Stage 2</name>
  82. <debug>false</debug>
  83. <enable>
  84. <prop>/autopilot/locks/heading</prop>
  85. <value>dg-heading-hold</value>
  86. </enable>
  87. <input>
  88. <prop>/orientation/roll-deg</prop>
  89. </input>
  90. <reference>
  91. <prop>/autopilot/internal/target-roll-deg</prop>
  92. </reference>
  93. <output>
  94. <prop>/controls/flight/aileron</prop>
  95. </output>
  96. <config>
  97. <Kp>0.02</Kp> <!-- proportional gain -->
  98. <beta>1.0</beta> <!-- input value weighing factor -->
  99. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  100. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  101. <!-- unfiltered derivative error -->
  102. <Ti>10.0</Ti> <!-- integrator time -->
  103. <Td>0.00001</Td> <!-- derivator time -->
  104. <u_min>-5.00</u_min> <!-- minimum output clamp -->
  105. <u_max>5.00</u_max> <!-- maximum output clamp -->
  106. </config>
  107. </pid-controller>
  108. <!-- True Heading hold. 2 stage cascade controller. -->
  109. <!-- Stage #1 sets target roll based on diff between current heading -->
  110. <!-- and target heading. -->
  111. <pid-controller>
  112. <name>True Heading Hold (DG based) Stage 1</name>
  113. <debug>false</debug>
  114. <enable>
  115. <prop>/autopilot/locks/heading</prop>
  116. <value>true-heading-hold</value>
  117. </enable>
  118. <input>
  119. <prop>/autopilot/internal/true-heading-error-deg</prop>
  120. </input>
  121. <reference>
  122. <value>0.0</value>
  123. </reference>
  124. <output>
  125. <prop>/autopilot/internal/target-roll-deg</prop>
  126. </output>
  127. <config>
  128. <Kp>-1.0</Kp> <!-- proportional gain -->
  129. <beta>1.0</beta> <!-- input value weighing factor -->
  130. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  131. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  132. <!-- unfiltered derivative error -->
  133. <Ti>10.0</Ti> <!-- integrator time -->
  134. <Td>0.00001</Td> <!-- derivator time -->
  135. <u_min>-66.0</u_min> <!-- minimum output clamp -->
  136. <u_max>66.0</u_max> <!-- maximum output clamp -->
  137. </config>
  138. </pid-controller>
  139. <!-- Stage #2 drives the ailerons to achieve the desired roll deg. -->
  140. <pid-controller>
  141. <name>True Heading Hold (DG based) Stage 2</name>
  142. <debug>false</debug>
  143. <enable>
  144. <prop>/autopilot/locks/heading</prop>
  145. <value>true-heading-hold</value>
  146. </enable>
  147. <input>
  148. <prop>/orientation/roll-deg</prop>
  149. </input>
  150. <reference>
  151. <prop>/autopilot/internal/target-roll-deg</prop>
  152. </reference>
  153. <output>
  154. <prop>/controls/flight/aileron</prop>
  155. </output>
  156. <config>
  157. <Kp>0.02</Kp> <!-- proportional gain -->
  158. <beta>1.0</beta> <!-- input value weighing factor -->
  159. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  160. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  161. <!-- unfiltered derivative error -->
  162. <Ti>10.0</Ti> <!-- integrator time -->
  163. <Td>0.00001</Td> <!-- derivator time -->
  164. <u_min>-5.0</u_min> <!-- minimum output clamp -->
  165. <u_max>5.0</u_max> <!-- maximum output clamp -->
  166. </config>
  167. </pid-controller>
  168. <!-- Nav1 hold. 2 stage cascade controller. -->
  169. <!-- Stage #1 sets target roll based on diff between current heading -->
  170. <!-- and target heading. -->
  171. <pid-controller>
  172. <name>Nav1 Hold Stage 1</name>
  173. <debug>false</debug>
  174. <enable>
  175. <prop>/autopilot/locks/heading</prop>
  176. <value>nav1-hold</value>
  177. </enable>
  178. <input>
  179. <prop>/autopilot/internal/nav1-track-error-deg</prop>
  180. </input>
  181. <reference>
  182. <value>0.0</value>
  183. </reference>
  184. <output>
  185. <prop>/autopilot/internal/target-roll-deg</prop>
  186. </output>
  187. <config>
  188. <Kp>-1.0</Kp> <!-- proportional gain -->
  189. <beta>1.0</beta> <!-- input value weighing factor -->
  190. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  191. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  192. <!-- unfiltered derivative error -->
  193. <Ti>10.0</Ti> <!-- integrator time -->
  194. <Td>0.00001</Td>
  195. <u_min>-74.0</u_min> <!-- minimum output clamp -->
  196. <u_max>74.0</u_max> <!-- maximum output clamp -->
  197. </config>
  198. </pid-controller>
  199. <!-- Stage #2 drives the ailerons to achieve the desired roll deg. -->
  200. <pid-controller>
  201. <name>Nav1 Hold Stage 2</name>
  202. <debug>false</debug>
  203. <enable>
  204. <prop>/autopilot/locks/heading</prop>
  205. <value>nav1-hold</value>
  206. </enable>
  207. <input>
  208. <prop>/orientation/roll-deg</prop>
  209. </input>
  210. <reference>
  211. <prop>/autopilot/internal/target-roll-deg</prop>
  212. </reference>
  213. <output>
  214. <prop>/controls/flight/aileron</prop>
  215. </output>
  216. <config>
  217. <Kp>0.02</Kp> <!-- proportional gain -->
  218. <beta>1.0</beta> <!-- input value weighing factor -->
  219. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  220. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  221. <!-- unfiltered derivative error -->
  222. <Ti>10.0</Ti> <!-- integrator time -->
  223. <Td>0.00001</Td> <!-- derivator time -->
  224. <u_min>-5.0</u_min> <!-- minimum output clamp -->
  225. <u_max>5.0</u_max> <!-- maximum output clamp -->
  226. </config>
  227. </pid-controller>
  228. <!-- Second Stage #2 drives the rudder. -->
  229. <pid-controller>
  230. <name>Nav1 Hold Stage 2</name>
  231. <debug>false</debug>
  232. <enable>
  233. <prop>/autopilot/locks/heading</prop>
  234. <value>nav1-hold</value>
  235. </enable>
  236. <input>
  237. <prop>/orientation/roll-deg</prop>
  238. </input>
  239. <reference>
  240. <prop>/autopilot/internal/target-roll-deg</prop>
  241. </reference>
  242. <output>
  243. <prop>/controls/flight/rudder</prop>
  244. </output>
  245. <config>
  246. <Kp>0.005</Kp> <!-- proportional gain -->
  247. <beta>1.0</beta> <!-- input value weighing factor -->
  248. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  249. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  250. <!-- unfiltered derivative error -->
  251. <Ti>10.0</Ti> <!-- integrator time -->
  252. <Td>0.000000001</Td> <!-- derivator time -->
  253. <u_min>-1.10</u_min> <!-- minimum output clamp -->
  254. <u_max>1.10</u_max> <!-- maximum output clamp -->
  255. </config>
  256. </pid-controller>
  257. <!-- Tacan hold. 2 stage cascade controller. -->
  258. <!-- Stage #1 sets target roll based on diff between current heading -->
  259. <!-- and target heading. -->
  260. <pid-controller>
  261. <name>Tacan Hold (DG based) Stage 1</name>
  262. <debug>false</debug>
  263. <enable>
  264. <prop>/autopilot/locks/heading</prop>
  265. <value>tacan-hold</value>
  266. </enable>
  267. <input>
  268. <prop>/autopilot/internal/fdm-heading-bug-error-deg</prop>
  269. </input>
  270. <reference>
  271. <value>0.0</value>
  272. </reference>
  273. <output>
  274. <prop>/autopilot/internal/target-roll-deg</prop>
  275. </output>
  276. <config>
  277. <Kp>-1.0</Kp> <!-- proportional gain -->
  278. <beta>1.0</beta> <!-- input value weighing factor -->
  279. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  280. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  281. <!-- unfiltered derivative error -->
  282. <Ti>10.0</Ti> <!-- integrator time -->
  283. <Td>0.00001</Td> <!-- derivator time -->
  284. <u_min>-74.0</u_min> <!-- minimum output clamp -->
  285. <u_max>74.0</u_max> <!-- maximum output clamp -->
  286. </config>
  287. </pid-controller>
  288. <!-- Stage #2 drives the ailerons to achieve the desired roll deg. -->
  289. <pid-controller>
  290. <name>Tacan Hold (DG based) Stage 2</name>
  291. <debug>false</debug>
  292. <enable>
  293. <prop>/autopilot/locks/heading</prop>
  294. <value>tacan-hold</value>
  295. </enable>
  296. <input>
  297. <prop>/orientation/roll-deg</prop>
  298. </input>
  299. <reference>
  300. <prop>/autopilot/internal/target-roll-deg</prop>
  301. </reference>
  302. <output>
  303. <prop>/controls/flight/aileron</prop>
  304. </output>
  305. <config>
  306. <Kp>0.05</Kp> <!-- proportional gain -->
  307. <beta>1.0</beta> <!-- input value weighing factor -->
  308. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  309. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  310. <!-- unfiltered derivative error -->
  311. <Ti>10.0</Ti> <!-- integrator time -->
  312. <Td>0.00001</Td> <!-- derivator time -->
  313. <u_min>-5.0</u_min> <!-- minimum output clamp -->
  314. <u_max>5.0</u_max> <!-- maximum output clamp -->
  315. </config>
  316. </pid-controller>
  317. <!-- =============================================================== -->
  318. <!-- Pitch Axis Modes -->
  319. <!-- =============================================================== -->
  320. <!-- Simple pitch hold -->
  321. <pid-controller>
  322. <name>Pitch hold</name>
  323. <debug>false</debug>
  324. <enable>
  325. <prop>/autopilot/locks/altitude</prop>
  326. <value>pitch-hold</value>
  327. </enable>
  328. <input>
  329. <prop>/orientation/pitch-deg</prop>
  330. </input>
  331. <reference>
  332. <prop>/autopilot/settings/target-pitch-deg</prop>
  333. </reference>
  334. <output>
  335. <prop>/controls/flight/elevator-trim</prop>
  336. </output>
  337. <config>
  338. <Kp>-0.005</Kp> <!-- proportional gain -->
  339. <beta>1.0</beta> <!-- input value weighing factor -->
  340. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  341. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  342. <!-- unfiltered derivative error -->
  343. <Ti>1.0</Ti> <!-- integrator time 1.0 -->
  344. <Td>0.00001</Td> <!-- derivator time 0.00001 -->
  345. <u_min>-0.5</u_min> <!-- minimum output clamp -->
  346. <u_max>0.5</u_max> <!-- maximum output clamp -->
  347. </config>
  348. </pid-controller>
  349. <!-- Simple angle of attack hold -->
  350. <pid-controller>
  351. <name>AOA hold</name>
  352. <debug>false</debug>
  353. <enable>
  354. <prop>/autopilot/locks/altitude</prop>
  355. <value>aoa-hold</value>
  356. </enable>
  357. <input>
  358. <prop>/orientation/alpha-deg</prop>
  359. </input>
  360. <reference>
  361. <prop>/autopilot/settings/target-aoa-deg</prop>
  362. </reference>
  363. <output>
  364. <prop>/controls/flight/elevator-trim</prop>
  365. </output>
  366. <config>
  367. <Kp>-0.005</Kp> <!-- proportional gain -->
  368. <beta>1.0</beta> <!-- input value weighing factor -->
  369. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  370. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  371. <!-- unfiltered derivative error -->
  372. <Ti>0.5</Ti> <!-- integrator time -->
  373. <Td>0.00001</Td> <!-- derivator time -->
  374. <u_min>-0.5</u_min> <!-- minimum output clamp -->
  375. <u_max>0.5</u_max> <!-- maximum output clamp -->
  376. </config>
  377. </pid-controller>
  378. <!-- Altitude hold. 2 stage cascade controller. -->
  379. <!-- Stage #1 sets target rate of climb based on diff between current alt -->
  380. <!-- and target altitude. -->
  381. <pi-simple-controller>
  382. <name>Altitude Hold (Altimeter based) Stage 1</name>
  383. <debug>false</debug>
  384. <enable>
  385. <prop>/autopilot/locks/altitude</prop>
  386. <value>altitude-hold</value>
  387. </enable>
  388. <input>
  389. <prop>/instrumentation/altimeter/indicated-altitude-ft</prop>
  390. </input>
  391. <reference>
  392. <prop>/autopilot/settings/target-altitude-ft</prop>
  393. </reference>
  394. <output>
  395. <prop>/autopilot/internal/target-climb-rate-fps</prop>
  396. </output>
  397. <config>
  398. <Kp>0.25</Kp> <!-- proportional gain -->
  399. <Ki>0.0</Ki> <!-- integral gain -->
  400. <u_min>-35.0</u_min> <!-- minimum output clamp -16.67-->
  401. <u_max>35.0</u_max> <!-- maximum output clamp 33.33-->
  402. </config>
  403. </pi-simple-controller>
  404. <!-- Stage #2 drives the elevator-trim to achieve the desired climb rate. -->
  405. <pid-controller>
  406. <name>Altitude Hold (Altimeter based) Stage 2</name>
  407. <debug>false</debug>
  408. <enable>
  409. <prop>/autopilot/locks/altitude</prop>
  410. <value>altitude-hold</value>
  411. </enable>
  412. <input>
  413. <prop>/velocities/vertical-speed-fps</prop>
  414. </input>
  415. <reference>
  416. <prop>/autopilot/internal/target-climb-rate-fps</prop>
  417. </reference>
  418. <output>
  419. <prop>/controls/flight/elevator-trim</prop>
  420. </output>
  421. <config>
  422. <Kp>-0.0025</Kp> <!-- proportional gain -0.01 -->
  423. <beta>1.0</beta> <!-- input value weighing factor -->
  424. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  425. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  426. <!-- unfiltered derivative error -->
  427. <Ti>10.0</Ti> <!-- integrator time 10.0 -->
  428. <Td>0.00001</Td> <!-- derivator time -->
  429. <u_min>-0.6</u_min> <!-- minimum output clamp -->
  430. <u_max>0.6</u_max> <!-- maximum output clamp -->
  431. </config>
  432. </pid-controller>
  433. <!-- AGL hold. 2 stage cascade controller. -->
  434. <!-- Stage #1 sets target rate of climb based on diff between current agl -->
  435. <!-- and target agl. -->
  436. <pid-controller>
  437. <name>AGL Hold (Altimeter based) Stage 1</name>
  438. <debug>false</debug>
  439. <enable>
  440. <prop>/autopilot/locks/altitude</prop>
  441. <value>agl-hold</value>
  442. </enable>
  443. <input>
  444. <prop>/position/altitude-agl-ft</prop>
  445. </input>
  446. <reference>
  447. <prop>/autopilot/settings/target-agl-ft</prop>
  448. </reference>
  449. <output>
  450. <prop>/autopilot/internal/target-climb-rate-fps</prop>
  451. </output>
  452. <config>
  453. <Kp>1.0</Kp> <!-- proportional gain -->
  454. <beta>1.0</beta> <!-- input value weighing factor -->
  455. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  456. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  457. <!-- unfiltered derivative error -->
  458. <Ti>25.0</Ti> <!-- integrator time -->
  459. <Td>0.00000001</Td> <!-- derivator time -->
  460. <u_min>-26.0</u_min> <!-- minimum output clamp -->
  461. <u_max>26.0</u_max> <!-- maximum output clamp -->
  462. </config>
  463. </pid-controller>
  464. <!-- Stage #2 drives the elevator-trim to achieve the desired climb rate. -->
  465. <pid-controller>
  466. <name>Altitude Hold (Altimeter based) Stage 2</name>
  467. <debug>false</debug>
  468. <enable>
  469. <prop>/autopilot/locks/altitude</prop>
  470. <value>agl-hold</value>
  471. </enable>
  472. <input>
  473. <prop>/velocities/vertical-speed-fps</prop>
  474. </input>
  475. <reference>
  476. <prop>/autopilot/internal/target-climb-rate-fps</prop>
  477. </reference>
  478. <output>
  479. <prop>/controls/flight/elevator-trim</prop>
  480. </output>
  481. <config>
  482. <Kp>-0.0025</Kp> <!-- proportional gain -->
  483. <beta>1.0</beta> <!-- input value weighing factor -->
  484. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  485. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  486. <!-- unfiltered derivative error -->
  487. <Ti>10.0</Ti> <!-- integrator time -->
  488. <Td>0.00001</Td> <!-- derivator time -->
  489. <u_min>-1.1</u_min> <!-- minimum output clamp -->
  490. <u_max>1.1</u_max> <!-- maximum output clamp -->
  491. </config>
  492. </pid-controller>
  493. <!-- Glideslope hold. -->
  494. <!-- Stage #2 drives the elevator-trim to achieve the desired climb rate. -->
  495. <pid-controller>
  496. <name>Glideslop Hold</name>
  497. <debug>false</debug>
  498. <enable>
  499. <prop>/autopilot/locks/altitude</prop>
  500. <value>gs1-hold</value>
  501. </enable>
  502. <input>
  503. <prop>/velocities/vertical-speed-fps</prop>
  504. </input>
  505. <reference>
  506. <prop>/instrumentation/nav[0]/gs-rate-of-climb</prop>
  507. </reference>
  508. <output>
  509. <prop>/controls/flight/elevator-trim</prop>
  510. </output>
  511. <config>
  512. <Kp>-0.005</Kp> <!-- proportional gain -->
  513. <beta>1.0</beta> <!-- input value weighing factor -->
  514. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  515. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  516. <!-- unfiltered derivative error -->
  517. <Ti>10.0</Ti> <!-- integrator time -->
  518. <Td>0.00001</Td> <!-- derivator time -->
  519. <u_min>-1.1</u_min> <!-- minimum output clamp -->
  520. <u_max>1.1</u_max> <!-- maximum output clamp -->
  521. </config>
  522. </pid-controller>
  523. <!-- vertical speed hold -->
  524. <pid-controller>
  525. <name>Vertical Speed Hold</name>
  526. <debug>false</debug>
  527. <enable>
  528. <prop>/autopilot/locks/altitude</prop>
  529. <value>vertical-speed-hold</value>
  530. </enable>
  531. <input>
  532. <prop>/velocities/vertical-speed-fps</prop>
  533. </input>
  534. <reference>
  535. <prop>/autopilot/settings/vertical-speed-fpm</prop>
  536. <scale>0.01667</scale>
  537. </reference>
  538. <output>
  539. <prop>/controls/flight/elevator-trim</prop>
  540. </output>
  541. <config>
  542. <Kp>-0.0025</Kp> <!-- proportional gain -->
  543. <beta>1.0</beta> <!-- input value weighing factor -->
  544. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  545. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  546. <!-- unfiltered derivative error -->
  547. <Ti>10.0</Ti> <!-- integrator time -->
  548. <Td>0.00001</Td> <!-- derivator time -->
  549. <u_min>-1.1</u_min> <!-- minimum output clamp -->
  550. <u_max>1.1</u_max> <!-- maximum output clamp -->
  551. </config>
  552. </pid-controller>
  553. <!-- =============================================================== -->
  554. <!-- Velocity Modes -->
  555. <!-- =============================================================== -->
  556. <!-- Auto throttle -->
  557. <pid-controller>
  558. <name>Auto Throttle (5 sec lookahead)</name>
  559. <debug>false</debug>
  560. <enable>
  561. <prop>/autopilot/locks/speed</prop>
  562. <value>speed-with-throttle</value>
  563. </enable>
  564. <input>
  565. <prop>/autopilot/internal/lookahead-5-sec-airspeed-kt</prop>
  566. </input>
  567. <reference>
  568. <prop>/autopilot/settings/target-speed-kt</prop>
  569. </reference>
  570. <output>
  571. <prop>/controls/engines/engine[0]/throttle</prop>
  572. <prop>/controls/engines/engine[1]/throttle</prop>
  573. </output>
  574. <config>
  575. <Kp>0.1</Kp> <!-- proportional gain -->
  576. <beta>1.0</beta> <!-- input value weighing factor -->
  577. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  578. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  579. <!-- unfiltered derivative error -->
  580. <Ti>10.0</Ti> <!-- integrator time -->
  581. <Td>0.00001</Td> <!-- derivator time -->
  582. <u_min>0.0</u_min> <!-- minimum output clamp -->
  583. <u_max>1.00</u_max> <!-- maximum output clamp -->
  584. </config>
  585. </pid-controller>
  586. <!-- Hold speed by varying pitch (Two stage cascading controller) -->
  587. <pid-controller>
  588. <name>Speed hold (vary pitch) Stage #1</name>
  589. <debug>false</debug>
  590. <enable>
  591. <prop>/autopilot/locks/speed</prop>
  592. <value>speed-with-pitch</value>
  593. </enable>
  594. <input>
  595. <prop>/autopilot/internal/lookahead-5-sec-airspeed-kt</prop>
  596. </input>
  597. <reference>
  598. <prop>/autopilot/settings/target-speed-kt</prop>
  599. </reference>
  600. <output>
  601. <prop>/autopilot/settings/target-pitch-deg</prop>
  602. </output>
  603. <config>
  604. <Kp>-1.0</Kp> <!-- proportional gain -->
  605. <beta>1.0</beta> <!-- input value weighing factor -->
  606. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  607. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  608. <!-- unfiltered derivative error -->
  609. <Ti>1.0</Ti> <!-- integrator time -->
  610. <Td>0.00001</Td> <!-- derivator time -->
  611. <u_min>-15.5</u_min><!-- minimum output clamp -->
  612. <u_max>15.5</u_max> <!-- maximum output clamp -->
  613. </config>
  614. </pid-controller>
  615. <pid-controller>
  616. <name>Speed hold (vary pitch) Stage #2</name>
  617. <debug>false</debug>
  618. <enable>
  619. <prop>/autopilot/locks/speed</prop>
  620. <value>speed-with-pitch</value>
  621. </enable>
  622. <input>
  623. <prop>/orientation/pitch-deg</prop>
  624. </input>
  625. <reference>
  626. <prop>/autopilot/settings/target-pitch-deg</prop>
  627. </reference>
  628. <output>
  629. <prop>/controls/flight/elevator-trim</prop>
  630. </output>
  631. <config>
  632. <Kp>-0.05</Kp> <!-- proportional gain -->
  633. <beta>1.0</beta> <!-- input value weighing factor -->
  634. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  635. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  636. <!-- unfiltered derivative error -->
  637. <Ti>1.0</Ti> <!-- integrator time -->
  638. <Td>0.00001</Td> <!-- derivator time -->
  639. <u_min>-1.1</u_min> <!-- minimum output clamp -->
  640. <u_max>1.1</u_max> <!-- maximum output clamp -->
  641. </config>
  642. </pid-controller>
  643. <!-- Terrain follow. 2 stage cascade controller. -->
  644. <!-- Stage #1 sets target rate of climb based on diff between current alt -->
  645. <!-- and target altitude. -->
  646. <pi-simple-controller>
  647. <name>Altitude Hold (Altimeter based) Stage 1</name>
  648. <debug>false</debug>
  649. <enable>
  650. <prop>/autopilot/locks/altitude</prop>
  651. <value>terrain-follow</value>
  652. </enable>
  653. <input>
  654. <prop>/position/altitude-ft</prop>
  655. </input>
  656. <reference>
  657. <prop>/autopilot/settings/target-follow-altitude-ft</prop>
  658. </reference>
  659. <output>
  660. <prop>/autopilot/internal/target-climb-rate-fps</prop>
  661. </output>
  662. <config>
  663. <Kp>0.25</Kp> <!-- proportional gain -->
  664. <Ki>0.0</Ki> <!-- integral gain -->
  665. <u_min>-125.00</u_min> <!-- minimum output clamp -16.67-->
  666. <u_max>305.00</u_max> <!-- maximum output clamp 33.33-->
  667. </config>
  668. </pi-simple-controller>
  669. <!-- Stage #2 drives the elevator-trim to achieve the desired climb rate. -->
  670. <pid-controller>
  671. <name>Altitude Hold (Altimeter based) Stage 2</name>
  672. <debug>false</debug>
  673. <enable>
  674. <prop>/autopilot/locks/altitude</prop>
  675. <value>terrain-follow</value>
  676. </enable>
  677. <input>
  678. <prop>/velocities/vertical-speed-fps</prop>
  679. </input>
  680. <reference>
  681. <prop>/autopilot/internal/target-climb-rate-fps</prop>
  682. </reference>
  683. <output>
  684. <prop>/controls/flight/elevator-trim</prop>
  685. </output>
  686. <config>
  687. <Kp>-0.0025</Kp> <!-- proportional gain -0.01 -->
  688. <beta>1.0</beta> <!-- input value weighing factor -->
  689. <alpha>0.1</alpha> <!-- low pass filter weighing factor -->
  690. <gamma>0.0</gamma> <!-- input value weighing factor for -->
  691. <!-- unfiltered derivative error -->
  692. <Ti>10.0</Ti> <!-- integrator time 10.0 -->
  693. <Td>0.00001</Td> <!-- derivator time -->
  694. <u_min>-1.2</u_min> <!-- minimum output clamp -->
  695. <u_max>1.2</u_max> <!-- maximum output clamp -->
  696. </config>
  697. </pid-controller>
  698. </PropertyList>