|
From: <jj...@gm...> - 2006-07-29 15:25:57
|
Hello Jon First of all, thank you very much for the quick patch. I confirm it works. However, the scientist in me was curious about the autopilot mechanism, so I used your file to further experiment. The experiment is listed below and the result is that it really descends to 7000 after maintaining the 8k level, but later on it is not able to gain altitude to reach 8k (file altitude1.png). I tried in the middle invoking the do_trim, but it does strange things (see weird.png). That strange behavior was obtained by invoking do_trim between two set altitude_point in telnet console. The peak is really strange. I am quite new to this domain, in fact my background is software engineering, so perhaps I am doing things that just do not make sense with JSBSim. In this case, please, let me know. I do not want to waste your time or anybody else's. Thanks in advance for any hint you can provide Regards Jorge ------------- Information about the experiment (images and logs) http://file.uploadr.com/879a Please, hit on the "skip" option to the top right to skip the advertisements. The file will be available until a week has passed since the last download. ---------------------- The script which is not working ---------------------- <?xml version="1.0"?> <runscript name="C172 cruise at 8K, 80% power"> <!-- This run is for testing the C172 altitude hold autopilot and cruise performance --> <use aircraft="c172x"/> <use initialize="reset01"/> <run start=" 0.0" end="1200" dt="0.0083333"> <!-- Start the engine --> <when> <parameter name="sim-time-sec" comparison="ge" value="0.25"/> <parameter name="sim-time-sec" comparison="le" value="0.50"/> <set name="fcs/throttle-cmd-norm" value="1.0" action="FG_RAMP" tc =" 0.05"/> <set name="fcs/mixture-cmd-norm" value="0.85" action="FG_RAMP" tc =" 0.05"/> <set name="propulsion/magneto_cmd" value="3"/> <set name="propulsion/starter_cmd" value="1"/> </when> <when> <parameter name="sim-time-sec" comparison="gt" value="0.50 "/> <parameter name="sim-time-sec" comparison="lt" value="0.51"/> <set name="simulation/do_trim" value="0"/> </when> <when> <!-- Set Heading to 200 degrees and set the altitude --> <!-- hold set point to 8000 ft. --> <parameter name="sim-time-sec" comparison="ge" value="10"/> <set name="ap/heading_setpoint" value="200"/> <set name="ap/heading_hold" value="1"/> <set name="ap/altitude_setpoint" value=" 8000.0"/> <set name="ap/altitude_hold" value="1"/> </when> <when> <!-- hold set point to 7000 ft. --> <parameter name="sim-time-sec" comparison="ge" value="200"/> <set name="ap/altitude_setpoint" value="7000.0"/> <set name="ap/altitude_hold" value="1"/> </when> <when> <!-- hold set point to 8000 ft. --> <parameter name="sim-time-sec" comparison="ge" value="700"/> - Hide quoted text - <set name="ap/altitude_setpoint" value="8000.0"/> <set name="ap/altitude_hold" value="1"/> </when> </run> </runscript> |