[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Paparazzi-devel] flight plan's block change through GCS buttons questio
From: |
chris |
Subject: |
[Paparazzi-devel] flight plan's block change through GCS buttons question supplement(flight plan) |
Date: |
Fri, 10 Apr 2009 12:16:38 +0300 |
User-agent: |
Thunderbird 2.0.0.21 (X11/20090318) |
Just for reference i include my flight plan.
<!DOCTYPE flight_plan SYSTEM "flight_plan.dtd">
<flight_plan alt="50" ground_alt="7" lat0="37.9414" lon0="23.6794"
max_dist_from_home="250" name="SEF_Bomb" qfu="30" security_height="30">
<header>
#include "datalink.h"
#include "bomb.h"
#include "OSAMNav.h"
</header>
<waypoints>
<waypoint name="HOME" x="0" y="0"/>
<waypoint alt="30.0" name="AF" x="36.3" y="-86.9"/>
<waypoint alt="7.0" name="TD" x="55.5" y="6.7"/>
<waypoint alt="30.0" name="AF_NORTH" x="69.8" y="88.2"/>
<waypoint name="BASELEG_NORTH" x="19.2" y="103.0"/>
<waypoint name="BASELEG" x="-12.8" y="-66.9"/>
<waypoint name="START" x="38.9" y="-74.6"/>
<waypoint name="RELEASE" x="49.6" y="-22.8"/>
<waypoint alt="7.0" name="TARGET" x="52.8" y="-5.4"/>
<waypoint name="CLIMB" x="62.2" y="45.7"/>
<waypoint alt="50.0" name="S1" x="-95.7" y="-57.9"/>
<waypoint alt="50.0" name="S2" x="-45.8" y="126.7"/>
<waypoint alt="50.0" name="S3" x="166.3" y="66.9"/>
<waypoint alt="50.0" name="S4" x="88.8" y="-106.0"/>
</waypoints>
<sectors>
<sector name="PolySector">
<corner name="S1"/>
<corner name="S2"/>
<corner name="S3"/>
<corner name="S4"/>
</sector>
</sectors>
<exceptions>
<!-- <exception cond="9.7 > PowerVoltage()" deroute="standby"/> -->
</exceptions>
<blocks>
<block name="Wait GPS">
<set value="1" var="kill_throttle"/>
<while cond="!GpsFixValid()"/>
</block>
<block name="Geo init">
<while cond="LessThan(NavBlockTime(), 10)"/>
<call fun="NavSetGroundReferenceHere()"/>
<call fun="NavSetWaypointHere(WP_HOME)"/>
</block>
<block name="Holding point">
<set value="1" var="kill_throttle"/>
<attitude roll="0" throttle="0" until="estimator_hspeed_mod > 3"
vmode="throttle"/>
<set value="0" var="kill_throttle"/>
<deroute block="standby"/>
</block>
<block name="standby" strip_button="standby" strip_icon="home.png">
<set value="-DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<circle alt="ground_alt+30" radius="nav_radius" wp="HOME"/>
</block>
<block name="Poly Survey" strip_button="Survey" strip_icon="survey.png">
<exception cond="PolySurveySweepNum >= 4" deroute="standby"/>
<call fun="InitializePolygonSurvey(WP_S1, 4, 50, 75)"/>
<call fun="PolygonSurvey()"/>
</block>
<block name="Bomb Right" strip_button="Bomb R" strip_icon="kill.png">
<set value="DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<deroute block="bomb"/>
</block>
<block name="Bomb Left" strip_button="Bomb L"strip_icon="kill.png">
<set value="-DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<deroute block="bomb"/>
</block>
<block name="bomb">
<call fun="BombComputeApproach(WP_TARGET, WP_START, nav_radius)"/>
<circle radius="nav_radius" until="NavCircleCount() > 0.5"
wp="BASELEG"/>
<circle radius="nav_radius"
until="NavQdrCloseTo(DegOfRad(bomb_start_qdr)-10)" wp="BASELEG"/>
</block>
<block name="align">
<exception cond="BombUpdateRelease(WP_TARGET)" deroute="standby"/>
<go approaching_time="bomb_trigger_delay" from="START"
hmode="route" wp="RELEASE"/>
</block>
<block name="shoot">
<set value="BombShoot()" var="unit"/>
<!-- <set value="MIN_PPRZ"
var="ap_state->commands[COMMAND_HATCH]"/> -->
<!-- <set value="MAX_PPRZ"
var="ap_state->commands[COMMAND_HATCH]"/> -->
<go approaching_time="0" from="RELEASE" hmode="route" wp="CLIMB"
alt="ground_alt+100" />
<set value="BombCloseHatch()" var="unit"/>
<deroute block="standby"/>
</block>
<block name="Land Right AF-TD" strip_button="Land (North wind)"
strip_icon="land-right.png">
<set value="DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<deroute block="land"/>
</block>
<block name="Land Left AF-TD" strip_button="Land (North wind)"
strip_icon="land-left.png">
<set value="-DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<deroute block="land"/>
</block>
<block name="land">
<call fun="nav_compute_baseleg(WP_AF, WP_TD, WP_BASELEG,
nav_radius)"/>
<circle radius="nav_radius" until="NavCircleCount() > 0.5"
wp="BASELEG"/>
<set value="V_CTL_AUTO_THROTTLE_MIN_CRUISE_THROTTLE"
var="v_ctl_auto_throttle_cruise_throttle"/>
<circle alt="ground_alt+20" radius="nav_radius"
until="NavQdrCloseTo(DegOfRad(baseleg_out_qdr)-10) && 10 >
fabs(estimator_z - WaypointAlt(WP_BASELEG))" wp="BASELEG"/>
</block>
<block name="final">
<exception cond="ground_alt + 10 > estimator_z" deroute="flare"/>
<go from="AF" hmode="route" vmode="glide" wp="TD"/>
</block>
<block name="flare">
<go approaching_time="0" from="AF" hmode="route" throttle="0.0"
vmode="throttle" wp="TD"/>
<attitude roll="0.0" throttle="0.0" until="FALSE" vmode="throttle"/>
</block>
<block name="Land Right AF_NORTH-TD" strip_button="Land (South wind)
" strip_icon="land-right.png">
<set value="DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<deroute block="land_North"/>
</block>
<block name="Land Left AF_NORTH-TD" strip_button="Land (South wind)"
strip_icon="land-left.png">
<set value="-DEFAULT_CIRCLE_RADIUS" var="nav_radius"/>
<deroute block="land_North"/>
</block>
<block name="land_North">
<call fun="nav_compute_baseleg(WP_AF_NORTH, WP_TD,
WP_BASELEG_NORTH, nav_radius)"/>
<circle radius="nav_radius" until="NavCircleCount() > 0.5"
wp="BASELEG_NORTH"/>
<set value="V_CTL_AUTO_THROTTLE_MIN_CRUISE_THROTTLE"
var="v_ctl_auto_throttle_cruise_throttle"/>
<circle alt="ground_alt+20" radius="nav_radius"
until="NavQdrCloseTo(DegOfRad(baseleg_out_qdr)-10) && 10 >
fabs(estimator_z - WaypointAlt(WP_BASELEG_NORTH))" wp="BASELEG_NORTH"/>
</block>
<block name="final_North">
<exception cond="ground_alt + 10 > estimator_z"
deroute="flare_North"/>
<go from="AF_NORTH" hmode="route" vmode="glide" wp="TD"/>
</block>
<block name="flare_North">
<go approaching_time="0" from="AF_NORTH" hmode="route"
throttle="0.0" vmode="throttle" wp="TD"/>
<attitude roll="0.0" throttle="0.0" until="FALSE" vmode="throttle"/>
</block>
</blocks>
</flight_plan>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Paparazzi-devel] flight plan's block change through GCS buttons question supplement(flight plan),
chris <=