Hello,
I am creating a custom made autopilot using XML gauges to a Russian made aircraft. I have managed to make an autopilot VS selection window that works perfectly in ft/min. Now I would need to convert this selection window to show values in meters per second as in this aircraft gauges measure the VS in such manner. The conversion formula from ft/min to m/sec would be: (ft/min) x 0.3048 / 60. How to write this in the XML gauge below? I am a beginner with XML and I cannot find examples in tutorials how to achieve this. Could someone please fix my code below to achieve what I need? I am using FS2004.
I am creating a custom made autopilot using XML gauges to a Russian made aircraft. I have managed to make an autopilot VS selection window that works perfectly in ft/min. Now I would need to convert this selection window to show values in meters per second as in this aircraft gauges measure the VS in such manner. The conversion formula from ft/min to m/sec would be: (ft/min) x 0.3048 / 60. How to write this in the XML gauge below? I am a beginner with XML and I cannot find examples in tutorials how to achieve this. Could someone please fix my code below to achieve what I need? I am using FS2004.
Code:
<Gauge Name="VS_Win" Version="1.0">
<Image Name="Fab_AP_Rolling_Numbers_Mask_5Hole.bmp" ImageSizes="120,38"/>
<Element>
<Visible>(A:ELECTRICAL AVIONICS BUS VOLTAGE,bool)</Visible>
<MaskImage Name="Fab_AP_Rolling_Numbers_Mask_5Hole.bmp" Bright="Yes" ImageSizes="120,38">
<Axis X="1" Y="7"/>
</MaskImage>
<Image Name="Fab_AP_Rolling_Numbers_Signs.bmp" Bright="Yes" ImageSizes="18,58">
<Nonlinearity>
<Item Value="-1" X="0" Y="1"/>
<Item Value="1" X="0" Y="33"/>
</Nonlinearity>
</Image>
<Shift>
<Value>(A:Autopilot vertical hold var, ft/min) -1 max 1 min</Value>
</Shift>
</Element>
<Element>
<Visible>(A:ELECTRICAL AVIONICS BUS VOLTAGE,bool)</Visible>
<MaskImage Name="Fab_AP_Rolling_Numbers_Mask_5Hole.bmp" Bright="Yes" ImageSizes="120,38">
<Axis X="25" Y="7"/>
</MaskImage>
<Image Name="Fab_AP_Rolling_Numbers.bmp" Bright="Yes" ImageSizes="33,343">
<Nonlinearity>
<Item Value="0" X="6" Y="5"/>
<Item Value="9" X="6" Y="284"/>
</Nonlinearity>
</Image>
<Shift>
<Value>(A:Autopilot vertical hold var, ft/min) abs s1 1000 / 10 % flr l1 1000 % 999 > if{ l1 10 % 9 - + }</Value>
</Shift>
</Element>
<Element>
<Visible>(A:ELECTRICAL AVIONICS BUS VOLTAGE,bool)</Visible>
<MaskImage Name="Fab_AP_Rolling_Numbers_Mask_5Hole.bmp" Bright="Yes" ImageSizes="120,38">
<Axis X="50" Y="7"/>
</MaskImage>
<Image Name="Fab_AP_Rolling_Numbers.bmp" Bright="Yes" ImageSizes="33,343">
<Nonlinearity>
<Item Value="0" X="6" Y="5"/>
<Item Value="9" X="6" Y="284"/>
</Nonlinearity>
</Image>
<Shift>
<Value>(A:Autopilot vertical hold var, ft/min) abs s1 100 / 10 % flr l1 100 % 99 > if{ l1 10 % 9 - + }</Value>
</Shift>
</Element>
<Element>
<Visible>(A:ELECTRICAL AVIONICS BUS VOLTAGE,bool)</Visible>
<MaskImage Name="Fab_AP_Rolling_Numbers_Mask_5Hole.bmp" Bright="Yes" ImageSizes="120,38">
<Axis X="75" Y="7"/>
</MaskImage>
<Image Name="Fab_AP_Rolling_Numbers.bmp" Bright="Yes" ImageSizes="33,343">
<Nonlinearity>
<Item Value="0" X="6" Y="5"/>
<Item Value="9" X="6" Y="284"/>
</Nonlinearity>
</Image>
<Shift>
<Value>(A:Autopilot vertical hold var, ft/min) abs s1 10 / 10 % flr l1 10 % 9 > if{ l1 10 % 9 - + }</Value>
</Shift>
</Element>
<Element>
<Visible>(A:ELECTRICAL AVIONICS BUS VOLTAGE,bool)</Visible>
<MaskImage Name="Fab_AP_Rolling_Numbers_Mask_5Hole.bmp" Bright="Yes" ImageSizes="120,38">
<Axis X="100" Y="7"/>
</MaskImage>
<Image Name="Fab_AP_Rolling_Numbers.bmp" Bright="Yes" ImageSizes="33,343">
<Nonlinearity>
<Item Value="0" X="6" Y="5"/>
<Item Value="9" X="6" Y="284"/>
</Nonlinearity>
</Image>
<Shift>
<Value>(A:Autopilot vertical hold var, ft/min) abs 10 %</Value>
</Shift>
</Element>
<Mouse>
<Help ID="HELPID_AUTOPILOT_VSI_INDICATOR"/>
<Tooltip ID="TOOLTIPTEXT_AUTOPILOT_VSI_INDICATOR_FTMIN" MetricID="TOOLTIPTEXT_AUTOPILOT_VSI_INDICATOR_MS"/>
<Area Left="0" Top="0" Width="60" Height="38">
<Cursor Type="DownArrow"/>
<Click Event="AP_VS_VAR_DEC" Repeat="Yes"/>
</Area>
<Area Left="61" Top="0" Width="60" Height="38">
<Cursor Type="UpArrow"/>
<Click Event="AP_VS_VAR_INC" Repeat="Yes"/>
</Area>
</Mouse>
</Gauge>