<?xml version="1.0" encoding="ISO-8859-1"?>

<!-- SIAI-Marchetti SF.260 : BARANGER Emmanuel (2015)

     sources          : http://en.wikipedia.org/wiki/SIAI-Marchetti_SF.260

     wingspan         :   8.35 m   (   26 ft 11.75 in )
     length           :   7.10 m   (   23 ft  0    in )
     height           :   2.41 m   (    8 ft  6    in )
     empty weight     : 765.00 kg  ( 1488 lb          )
     engine           : 1 x Lycoming O-540-E4A5 ( 260 hp )
     Cruise speed     :   330 km/h (  178 kt          )
     Max speed        :   441 km/h (  236 kt          )
-->
<airplane mass="1488" version="YASIM_VERSION_CURRENT">

  <!-- Approach configuration -->
  <approach speed="40" aoa="4" fuel="0.2">
    <control-setting axis="/controls/engines/engine[0]/throttle" value="0.2"/>
    <control-setting axis="/controls/engines/engine[0]/mixture" value="1"/>
    <control-setting axis="/controls/flight/flaps" value="1"/>
  </approach>

  <!-- Cruise configuration -->
  <cruise speed="178" alt="6000" fuel="0.5">
    <control-setting axis="/controls/engines/engine[0]/throttle" value="0.7"/>
    <control-setting axis="/controls/engines/engine[0]/mixture" value="0.6"/>
    <control-setting axis="/controls/flight/flaps" value="0"/>
    <control-setting axis="/controls/flight/elevator-trim" value="0.02"/>
  </cruise>

  <cockpit x="1.030" y="0.200" z="0.242"/>
  
  <!-- Fuselage Noze -->
  <fuselage ax=" 3.148" ay=" 0.195" az="-0.220" bx=" 3.097" by=" 0.195" bz="-0.220" width="0.476" taper="0.8" midpoint="1"/>
  <fuselage ax=" 3.148" ay=" 0.000" az="-0.220" bx=" 3.097" by=" 0.000" bz="-0.220" width="0.476" taper="0.8" midpoint="1"/>
  <fuselage ax=" 3.148" ay="-0.195" az="-0.220" bx=" 3.097" by="-0.195" bz="-0.220" width="0.476" taper="0.8" midpoint="1"/>
  <!-- Fuelsage left section -->
  <fuselage ax=" 3.097" ay=" 0.195" az="-0.220" bx=" 2.863" by=" 0.165" bz="-0.303" width="0.631" taper="0.8" midpoint="1"/>
  <fuselage ax=" 2.863" ay=" 0.165" az="-0.303" bx=" 1.915" by=" 0.064" bz="-0.436" width="0.937" taper="0.7" midpoint="1"/>
  <fuselage ax=" 1.915" ay=" 0.064" az="-0.436" bx="-0.507" by=" 0.000" bz="-0.348" width="0.996" taper="0.9" midpoint="1"/>
  <!-- Fuselage right section --> 
  <fuselage ax=" 3.097" ay="-0.195" az="-0.220" bx=" 2.863" by="-0.165" bz="-0.303" width="0.631" taper="0.8" midpoint="1"/>
  <fuselage ax=" 2.863" ay="-0.165" az="-0.303" bx=" 1.915" by="-0.064" bz="-0.436" width="0.937" taper="0.7" midpoint="1"/>
  <fuselage ax=" 1.915" ay="-0.064" az="-0.436" bx="-0.507" by=" 0.000" bz="-0.348" width="0.996" taper="0.9" midpoint="1"/>
  <!-- Fuselage rear section --> 
  <fuselage ax="-0.507" ay=" 0.000" az="-0.348" bx="-3.357" by=" 0.000" bz="-0.348" width="0.996" taper="0.2" midpoint="0"/>
  <!-- Cockpit section --> 
  <fuselage ax=" 1.852" ay=" 0.000" az="-0.396" bx=" 0.971" by=" 0.000" bz="-0.051" width="1.034" taper="0.8" midpoint="1"/>
  <fuselage ax=" 1.154" ay=" 0.000" az="-0.091" bx=" 0.427" by=" 0.000" bz="-0.069" width="1.034" taper="0.9" midpoint="0"/>
  <fuselage ax=" 0.488" ay=" 0.000" az="-0.117" bx="-0.505" by=" 0.000" bz="-0.223" width="1.034" taper="0.7" midpoint="0"/>
  <!-- Tip tanks --> 
  <!-- Left -->
  <fuselage ax=" 1.991" ay=" 3.955" az="-0.407" bx=" 1.619" by=" 3.955" bz="-0.407" width="0.290" taper="0.2" midpoint="1"/>
  <fuselage ax=" 1.619" ay=" 3.955" az="-0.407" bx=" 1.257" by=" 3.955" bz="-0.407" width="0.320" taper="0.9" midpoint="1"/>
  <fuselage ax=" 1.257" ay=" 3.955" az="-0.407" bx=" 0.182" by=" 3.955" bz="-0.407" width="0.320" taper="0.1" midpoint="0"/>
  <!-- Right -->
  <fuselage ax=" 1.991" ay="-3.955" az="-0.407" bx=" 1.619" by="-3.955" bz="-0.407" width="0.290" taper="0.2" midpoint="1"/>
  <fuselage ax=" 1.619" ay="-3.955" az="-0.407" bx=" 1.257" by="-3.955" bz="-0.407" width="0.320" taper="0.9" midpoint="1"/>
  <fuselage ax=" 1.257" ay="-3.955" az="-0.407" bx=" 0.182" by="-3.955" bz="-0.407" width="0.320" taper="0.1" midpoint="0"/>
  
  <wing x="0.888" y="0" z="-0.764" 
        chord="1.723" 
        length="3.998" 
        taper="0.45"
        sweep="-3.5"
        dihedral="5"
        camber="0.005">
        <stall aoa="28" width="1" peak="1.5"/>
        <flap0 start="0.00" end="0.63" lift="1.2" drag="1.25"/>
        <flap1 start="0.63" end="0.97" lift="1.2" drag="1.10"/>

        <control-input axis="/controls/flight/flaps" control="FLAP0"/>
        <control-input axis="/controls/flight/aileron" control="FLAP1" split="true"/>
        <control-input axis="/controls/flight/aileron-trim" control="FLAP1" split="true"/>

        <control-output control="FLAP0" prop="/surface-positions/flap-pos-norm"/>
        <control-output control="FLAP1" side="left" prop="/surface-positions/left-aileron-pos-norm"/>
        <control-output control="FLAP1" side="right" prop="/surface-positions/right-aileron-pos-norm"/>
        <control-output control="FLAP1" prop="/surface-positions/aileron-pos-norm"/>

        <control-speed control="FLAP0" transition-time="4"/>
  </wing>

  <hstab x="-2.826" y="0" z="-0.289" 
         chord="0.945" 
         length="1.474" 
         taper="0.6"
         dihedral="2"
         sweep="8">
         <stall aoa="26" width="1" peak="1.1"/>
         <flap0 start="0" end="1" lift="1.3" drag="1.1"/>

         <control-input axis="/controls/flight/elevator" control="FLAP0"/>
         <control-input axis="/controls/flight/elevator-trim" control="FLAP0"/>

         <control-output control="FLAP0" prop="/surface-positions/elevator-pos-norm"/>
  </hstab>

  <vstab x="-2.356" y="0" z="-0.149" 
         chord="1.441"
         length="1.7"
         taper="0.4"
         sweep="33">
         <stall aoa="22" width="1" peak="1.5"/>
         <flap0 start="0" end="1" lift="1.2" drag="1.1"/>

         <control-input axis="/controls/flight/rudder" control="FLAP0" invert="true"/>
         <control-input axis="/controls/flight/rudder-trim" control="FLAP0" invert="true"/>

         <control-output control="FLAP0" prop="/surface-positions/rudder-pos-norm" min="1" max="-1"/>
  </vstab>

  <!-- Engines   source            : http://en.wikipedia.org/wiki/Lycoming_O-540

                 name              : Lycoming O-540
                 type              : Six-cylinder air-cooled horizontally opposed engine
                 power cruise      : 300 hp at 2700 rpm at sea level
                 weight            : 438 lb    ( 199.0 kg )
                 displacement      : 541.5 in3 (   8.9 L  )
                 compression       : 8.7:1
  -->
  <propeller x="2.7377" y="0" z="-0.2574" 
             mass="438" 
             radius="1.02"
             moment="2.5"  
             cruise-speed="178" 
             cruise-rpm="2575"
             cruise-alt="6000" 
             cruise-power="213"
             takeoff-power="300" 
             takeoff-rpm="2700">
             <actionpt x="3.25427" y="0" z="-0.18689"/>
             <piston-engine eng-rpm="2700" 
                            eng-power="300"
                            displacement="541" 
                            compression="8.7">
                            <control-input control="THROTTLE" axis="/controls/engines/engine[0]/throttle" src0="0.0" src1="1.0" dst0="0.0" dst1="1.0"/>
                            <control-input control="STARTER" axis="/controls/engines/engine[0]/starter" />
                            <control-input control="MAGNETOS" axis="/controls/engines/engine[0]/magnetos" />
                            <control-input control="MIXTURE" axis="/controls/engines/engine[0]/mixture" src0="0.0" src1="1.0" dst0="0.8" dst1="0.8"/>
             </piston-engine>
  </propeller>
  
  <!-- Noze wheel -->
  <gear x="2.58315" y="0" z="-1.57072" 
        compression="0.15" 
        spring="0.8">
        <control-input axis="/controls/flight/rudder" control="STEER" square="false"/>
        <control-input axis="/controls/gear/gear-down" control="EXTEND"/>
        
        <control-output control="EXTEND" prop="/gear/gear[0]/position-norm"/>
        
        <control-speed control="EXTEND" transition-time="7"/>
  </gear>

  <!-- Left wheel -->
  <gear x="1.14678" y="1.20466" z="-1.57882"
        compression="0.2" 
        spring="1.8">
        <control-input axis="/controls/gear/brake-left" control="BRAKE"/>
        <control-input axis="/controls/gear/brake-parking" control="BRAKE"/>
        <control-input axis="/controls/gear/gear-down" control="EXTEND"/>
        
        <control-output control="EXTEND" prop="gear/gear[1]/position-norm"/>
        
        <control-speed control="EXTEND" transition-time="7"/>
  </gear>

  <!-- Right wheel -->
  <gear x="1.14678" y="-1.20466" z="-1.57882"
        compression="0.2" 
        spring="1.8">
        <control-input axis="/controls/gear/brake-right" control="BRAKE"/>
        <control-input axis="/controls/gear/brake-parking" control="BRAKE"/>
        <control-input axis="/controls/gear/gear-down" control="EXTEND"/>
        
        <control-output control="EXTEND" prop="gear/gear[2]/position-norm"/>
        
        <control-speed control="EXTEND" transition-time="7"/>
  </gear>

  <tank x="1.41" y=" 1.8" z="-0.60" capacity="200"/>
  <tank x="1.60" y=" 0.0" z="-0.64" capacity="300"/>
  <tank x="1.41" y="-1.8" z="-0.60" capacity="200"/>

  <!-- Mass distribution -->
  <ballast x="3" y="0" z="-1" mass="400"/>

</airplane>
