April 26, 20206 yr Hello, I am looking for some help to write a small function that calls upon default FSX autopilot behaviour. Here is how the sim behaves right now for ATT (attitude hold mode). When ATT hold is entered, the Autopilot reverts to roll hold for lateral control. I am looking for a way to keep the existing lateral mode when ATT hold is entered - so it can be used for enroute climbs and descents. It is possible to manually re-engage NAV or HDG mode. However, I would like to create a custom function that goes something like this: function flight_level_change () is NAV mode engaged? if yes - AP_ATT_HOLD AP_NAV_HOLD else - AP_ATT_HOLD AP_HDG_HOLD end is someone able to help me out with this? the above assumes that the autopilot is always in either HDG or NAV (true for me). It could use some kind of nested IF to also include roll_hold mode but I dont think its necessary... thanks so much!!!
April 27, 20206 yr Author this is what i have so far function F406_FLCH_ON () if D07C4 == 1 then ipc.control(65722,1) ipc.control(65811,1) else ipc.control(65722,1) ipc.control(66106,1) end end but the conditional always returns false, so either i am reading the wrong offset, or expecting the wrong value or something else? Edited April 27, 20206 yr by clarklidbury typo
Archived
This topic is now archived and is closed to further replies.