FSX RPM Warning Lights (XML)

#1
Hi all,

Well hit the edge of my knowledge I am replicating a Seneca V and need to add warning lights to the gauge. I have added the bmps and correct location but I am at a loss on how to make the work.
Ideally need them off when Battery is off then green on up to 2600 RPM and any then red when over 2600.

Sorry to be a pain I just cant find a similar gauge that I can see how it is achieved. Code and BMPs below

Many thanks
Matt

XML:
<Gauge Name="PA34V RPM Indicator" Version="1.0">
 <Image Name="RPM_Background.bmp"/>
<Element>
 <Position X="150" Y="147"/>
<Image Name="RPM_Needle.bmp" PointsTo="East">
 <Axis X="0" Y="9"/>
 </Image>
<Rotate>
 <Value Minimum="0" Maximum="27">(A:General eng1 rpm,RPM) 100 / </Value>
<Nonlinearity>
 <Item Value="0" X="206" Y="65"/>
 <Item Value="5" X="209" Y="65"/>
 <Item Value="12" X="242" Y="202"/>
 <Item Value="18" X="126" Y="249"/>
 <Item Value="24" X="42" Y="158"/>
 <Item Value="27" X="61" Y="95"/>
 </Nonlinearity>
 </Rotate>
 </Element>
<Element>
 <Position X="0" Y="0"/>
 <Image Name="RPM_cover.bmp"/>
 </Element>
<Element>
 <Position X="144" Y="35"/>
 <Image Name="green.bmp"/>
 </Element>
<Element>
 <Position X="144" Y="35"/>
 <Image Name="red.bmp"/>
 </Element>
<Mouse>
 <Tooltip ID="TOOLTIPTEXT_TACHOMETER_RPM"/>
 </Mouse>
 </Gauge>
RPM_background


RPM_Needle


RPM_cover


green


red
 
#2
Try ,
Code:
    <Element>
        <Position X="144" Y="35"/>
-         <Select>
           <Value>(A:Electrical master battery,bool) 1 == (A:General eng1 rpm,RPM) 2600 &lt; and</Value>
-           <Case Value="1">
             <Image Name="green.bmp"/>
            </Case>
          </Select>
    </Element>
    <Element>
        <Position X="144" Y="35"/>
-         <Select>
           <Value>(A:Electrical master battery,bool) 1 == (A:General eng1 rpm,RPM) 2600 &gt; and</Value>
-           <Case Value="1">
             <Image Name="red.bmp"/>
            </Case>
          </Select>
    </Element>
Cheers
Karol
 
#3
Thank you so so much Karol works perfectly you da man

Finished code below incase any one else needs it at some time


XML:
<Gauge Name="PA34V RPM Indicator" Version="1.0">
<Image Name="RPM_Background.bmp"/>
<Element>
<Position X="150" Y="147"/>
<Image Name="RPM_Needle.bmp" PointsTo="East">
<Axis X="0" Y="9"/>
</Image>
<Rotate>
<Value Minimum="0" Maximum="27">(A:General eng1 rpm,RPM) 100 / </Value>
<Nonlinearity>
<Item Value="0" X="206" Y="65"/>
<Item Value="5" X="209" Y="65"/>
<Item Value="12" X="242" Y="202"/>
<Item Value="18" X="126" Y="249"/>
<Item Value="24" X="42" Y="158"/>
<Item Value="27" X="61" Y="95"/>
</Nonlinearity>
</Rotate>
</Element>
<Element>
<Position X="0" Y="0"/>
<Image Name="RPM_cover.bmp"/>
</Element>
<Element>
<Position X="144" Y="35"/>
<Select>
<Value>(A:Electrical master battery,bool) 1 == (A:General eng1 rpm,RPM) 2600 &lt and</Value>
<Case Value="1">
<Image Name="green.bmp"/>
</Case>
</Select>
</Element>
<Element>
<Position X="144" Y="35"/>
<Select>
<Value>(A:Electrical master battery,bool) 1 == (A:General eng1 rpm,RPM) 2600 &gt and</Value>
<Case Value="1">
<Image Name="red.bmp"/>
</Case>
</Select>
</Element>
<Mouse>
<Tooltip ID="TOOLTIPTEXT_TACHOMETER_RPM"/>
</Mouse>
</Gauge>
 
Last edited:
Top