• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

ASI-Autopilot Help

Messages
292
Country
unitedkingdom
I could really use some help with my ASI, it uses a rotating bug to set the autopilot airspeed via a
knob on the ASI, the first problem is that when I rotate the bug it takes almost 2 rotations before the
tooltips display shows 400 knots. The second problem is that when I set the bug to any speed & the
autopilot speed hold is set to off & I select the speed hold to on, the bug resets.

Here is the code for the ASI bug, knob & mouse area.
Code:
        <Element id="Element">
            <FloatPosition>220.000,230.000</FloatPosition>
            <Image id="Airspeed_Bug.bmp" Name="Airspeed_Bug.bmp">
                <Transparent>True</Transparent>
                <Axis>12.000,195.000</Axis>
                <Bright>True</Bright>
            </Image>
            <Rotation id="Rotation">
                <PointsTo>NORTH</PointsTo>
                <Expression id="Expression">
                    <Minimum>0.000</Minimum>
                    <Maximum>400.000</Maximum>
                    <Script>(A:Autopilot airspeed hold var, knots)</Script>
                </Expression>
                <NonlinearityTable id="NonlinearityTable">
                    <NonlinearityEntry id="0">
                        <ExpressionResult>0.000</ExpressionResult>
                        <FloatPosition>220.000,65.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="80">
                        <ExpressionResult>80.000</ExpressionResult>
                        <FloatPosition>171.000,83.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="100">
                        <ExpressionResult>100.000</ExpressionResult>
                        <FloatPosition>336.000,112.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="120">
                        <ExpressionResult>120.000</ExpressionResult>
                        <FloatPosition>377.000,179.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="140">
                        <ExpressionResult>140.000</ExpressionResult>
                        <FloatPosition>383.000,256.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="160">
                        <ExpressionResult>160.000</ExpressionResult>
                        <FloatPosition>353.000,328.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="180">
                        <ExpressionResult>180.000</ExpressionResult>
                        <FloatPosition>294.000,377.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="200">
                        <ExpressionResult>200.000</ExpressionResult>
                        <FloatPosition>220.000,395.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="220">
                        <ExpressionResult>220.000</ExpressionResult>
                        <FloatPosition>145.000,377.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="240">
                        <ExpressionResult>240.000</ExpressionResult>
                        <FloatPosition>86.000,327.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="250">
                        <ExpressionResult>250.000</ExpressionResult>
                        <FloatPosition>68.000,293.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="300">
                        <ExpressionResult>300.000</ExpressionResult>
                        <FloatPosition>55.000,230.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="350">
                        <ExpressionResult>350.000</ExpressionResult>
                        <FloatPosition>68.000,167.000</FloatPosition>
                    </NonlinearityEntry>
                    <NonlinearityEntry id="400">
                        <ExpressionResult>400.000</ExpressionResult>
                        <FloatPosition>104.000,114.000</FloatPosition>
                    </NonlinearityEntry>
                </NonlinearityTable>
                <FailureTable id="FailureTable">
                    <Failure id="Failure">
                        <Fail_Key>SYSTEM_PITOT_STATIC</Fail_Key>
                        <Fail_Action>Freeze</Fail_Action>
                    </Failure>
                </FailureTable>
            </Rotation>
        </Element>
        <Element id="Knob">
            <FloatPosition>12.000,374.000</FloatPosition>
            <Image id="ASI_Knob.bmp" Name="ASI_Knob.bmp">
                <Transparent>True</Transparent>
                <Axis>38.000,39.000</Axis>
                <Bright>True</Bright>
            </Image>
            <Rotation id="Rotation">
                <Expression id="Expression">
                    <Minimum>0.000</Minimum>
                    <Maximum>360.000</Maximum>
                    <Script>(A:Autopilot airspeed hold var, knots)</Script>
                </Expression>
            </Rotation>
        </Element>
        <MouseArea id="MouseArea">
            <FloatPosition>20.000,381.000</FloatPosition>
            <Size>60,60</Size>
            <HelpId>HELPID_AUTOPILOT_SPEED_INDICATOR</HelpId>
            <MouseArea id="Dec">
                <FloatPosition>0.000,30.000</FloatPosition>
                <Size>60,30</Size>
                <CursorType>DownArrow</CursorType>
                <MouseClick id="MouseClick">
                    <Script>(L:Mach-IAS select, bool) if{ (&gt;K:AP_MACH_VAR_DEC) } els{

(&gt;K:AP_SPD_VAR_DEC) } </Script>
                    <ClickRepeat>True</ClickRepeat>
                </MouseClick>
            </MouseArea>
            <MouseArea id="Inc">
                <FloatPosition>0.000,0.000</FloatPosition>
                <Size>60,30</Size>
                <CursorType>UpArrow</CursorType>
                <MouseClick id="MouseClick">
                    <Script>(L:Mach-IAS select, bool) if{ (&gt;K:AP_MACH_VAR_INC) } els{

(&gt;K:AP_SPD_VAR_INC) } </Script>
                    <ClickRepeat>True</ClickRepeat>
                </MouseClick>
            </MouseArea>
            <Tooltip id="Tooltip">
                <DefaultId>TOOLTIPTEXT_AUTOPILOT_SPEED_INDICATOR_KNOTS</DefaultId>
            </Tooltip>
        </MouseArea>
    </SimGauge.Gauge>

This is the code for the autopilot speed hold & the IAS-Mach toggle.
Code:
            <MouseArea id="SPD">
                <FloatPosition>550.000,61.000</FloatPosition>
                <Size>35,35</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <KeyEvent>AP_AIRSPEED_HOLD</KeyEvent>
                </MouseClick>
                <Tooltip id="Tooltip">
                    <DefaultId>TOOLTIPTEXT_AUTOPILOT_SPEED_HOLD</DefaultId>
                </Tooltip>
            </MouseArea>
            <MouseArea id="IAS-Mach Sel">
                <FloatPosition>544.000,20.000</FloatPosition>
                <Size>44,24</Size>
                <CursorType>Hand</CursorType>
                <MouseClick id="MouseClick">
                    <Script>(L:Mach-IAS select, bool) ! (&gt;L:Mach-IAS select, bool) (A:AUTOPILOT

AIRSPEED HOLD, bool) if{ 1 (&gt;K:AP_PANEL_MACH_HOLD) } (A:AUTOPILOT MACH HOLD, bool) if{ 1

(&gt;K:AP_PANEL_SPEED_HOLD) }</Script>
                </MouseClick>
            </MouseArea>
        </MouseArea>

I would be very grateful for any help with this.
 
The second problem...
Using "panel hold" commands for the AP will set the current speed/alt etc at the time of engagement..

Use on/off's with their associated read var [A:] to provide a toggle.
(A:AUTOPILOT MACH HOLD, bool) if{ (>K:AP_PANEL_MACH_OFF) } els{ (>K:AP_PANEL_MACH_ON) }
(A:AUTOPILOT AIRSPEED HOLD, bool) if{ (>K:AP_PANEL_SPEED_OFF) } els{ (>K:AP_PANEL_SPEED_ON) }
 
The second problem...
Using "panel hold" commands for the AP will set the current speed/alt etc at the time of engagement..

Use on/off's with their associated read var [A:] to provide a toggle.
(A:AUTOPILOT MACH HOLD, bool) if{ (>K:AP_PANEL_MACH_OFF) } els{ (>K:AP_PANEL_MACH_ON) }
(A:AUTOPILOT AIRSPEED HOLD, bool) if{ (>K:AP_PANEL_SPEED_OFF) } els{ (>K:AP_PANEL_SPEED_ON) }
Also it prevents gauge flooding! Roman teached me both things as well ;)
 
Sorry for the delay in replying.

Thanks Roman, I tried using (A:AUTOPILOT MACH HOLD, bool) if{ (>K:AP_PANEL_MACH_OFF) } els{ (>K:AP_PANEL_MACH_ON) } with the Mach select switch & (A:AUTOPILOT AIRSPEED HOLD, bool) if{ (>K:AP_PANEL_SPEED_OFF) } els{ (>K:AP_PANEL_SPEED_ON) } with the IAS select switch & have changed the SPD hold button <KeyEvent> to AP_PANEL_SPEED_HOLD, but the Mach select switch turns speed hold off & IAS select switch turns speed hold on, the SPD hold button works & no longer resets ASI bug.

I have also tried (%((A:AUTOPILOT AIRSPEED HOLD, BOOL))%{if}on%{else}off%) for the IAS select switch & (%((A:AUTOPILOT MACH HOLD, BOOL))%{if}on%{else}off%) for the Mach select switch which does nothing, sorry if this all a bit basic stuff, but I am a newbie at gauge creation. In my first post I didn't explain what I am trying to do, the autopilot has 3 buttons, Speed Hold, IAS select & Mach select,

I still have the problem with the ASI bug, so if anybody has any ideas of how to fix this, it would much appreciated.
 
Back
Top