ok, it was to be sure you follow the movement ;) here are the patch for
route management. sorry for the inconvenience, I've been a bit hurry to
release the first patch.
Turnpoint is managed using "OBS mode", the route is still managed by
zkv500's Nasal, only "obs" mode is available (see
http://wiki.flightgear.org/index.php/GPS_internals). It should be "leg
mode" but I can't get it to work as I expect to.
thanks in advance for commit the patch (made using fg-commit)
best regards
seb
Victhor Foster a écrit :
The "turnpoint" screen works again, but it won't start the selected
waypoint, instead it uses the departure airport.
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel
? zkv500.diff
Index: MainScreens.nas
===================================================================
RCS file: /var/cvs/FlightGear-0.9/data/Aircraft/Instruments-3d/zkv500/MainScreens.nas,v
retrieving revision 1.7
diff -u -p -r1.7 MainScreens.nas
--- MainScreens.nas 30 Oct 2009 18:39:12 -0000 1.7
+++ MainScreens.nas 1 Nov 2009 00:25:32 -0000
@@ -182,17 +182,13 @@ var screenNavigationMain = {
waypointindex += 1;
next = gps_data.getNode("route/Waypoint[" ~ waypointindex ~ "]/",1);
if (next != nil) {
- gps_wp.getNode("wp/longitude-deg",1).setValue(gps_wp.getNode("wp[1]/longitude-deg",1).getValue());
- gps_wp.getNode("wp/latitude-deg",1).setValue(gps_wp.getNode("wp[1]/latitude-deg",1).getValue());
- gps_wp.getNode("wp/altitude-ft",1).setValue(gps_wp.getNode("wp[1]/altitude-ft",1).getValue());
- gps_wp.getNode("wp/ID",1).setValue(gps_wp.getNode("wp[1]/ID",1).getValue());
-
- gps_wp.getNode("wp[1]/longitude-deg",1).setValue(next.getNode("longitude-deg",1).getValue());
- gps_wp.getNode("wp[1]/latitude-deg",1).setValue(next.getNode("latitude-deg",1).getValue());
- gps_wp.getNode("wp[1]/altitude-ft",1).setValue(next.getNode("altitude-ft",1).getValue());
- gps_wp.getNode("wp[1]/waypoint-type",1).setValue(next.getNode("waypoint-type",1).getValue());
- gps_wp.getNode("wp[1]/ID",1).setValue(next.getNode("ID",1).getValue());
-
+ var scratch = gps_data.getNode("scratch");
+ scratch.getNode("longitude-deg",1).setValue(next.getNode("longitude-deg",1).getValue());
+ scratch.getNode("latitude-deg",1).setValue(next.getNode("latitude-deg",1).getValue());
+ scratch.getNode("altitude-ft",1).setValue(next.getNode("altitude-ft",1).getValue());
+ scratch.getNode("type",1).setValue(next.getNode("waypoint-type",1).getValue());
+ scratch.getNode("ident",1).setValue(next.getNode("ID",1).getValue());
+ gps_data.getNode("command").setValue("obs");
}
else {
page = 0; #screenTaskSelect
Index: TaskScreens.nas
===================================================================
RCS file: /var/cvs/FlightGear-0.9/data/Aircraft/Instruments-3d/zkv500/TaskScreens.nas,v
retrieving revision 1.3
diff -u -p -r1.3 TaskScreens.nas
--- TaskScreens.nas 14 Jul 2008 14:40:22 -0000 1.3
+++ TaskScreens.nas 1 Nov 2009 00:25:32 -0000
@@ -19,18 +19,8 @@ var screenTaskSelect = {
}));
foreach (var c; gps_data.getNode("route").getChildren("Waypoint"))
screenWaypointsList.n += 1;
- gps_wp.getNode("wp/latitude-deg",1).setValue(gps_data.getNode("indicated-latitude-deg",1).getValue());
- gps_wp.getNode("wp/longitude-deg",1).setValue(gps_data.getNode("indicated-longitude-deg",1).getValue());
- gps_wp.getNode("wp/altitude-ft",1).setValue(gps_data.getNode("indicated-altitude-ft",1).getValue());
- gps_wp.getNode("wp/ID").setValue("startpos");
-
- gps_wp.getNode("wp[1]/latitude-deg",1).setValue(gps_data.getNode("route/Waypoint/latitude-deg",1).getValue());
- gps_wp.getNode("wp[1]/longitude-deg",1).setValue(gps_data.getNode("route/Waypoint/longitude-deg",1).getValue());
- gps_wp.getNode("wp[1]/altitude-ft",1).setValue(gps_data.getNode("route/Waypoint/altitude-ft",1).getValue());
- gps_wp.getNode("wp[1]/waypoint-type",1).setValue(gps_data.getNode("route/Waypoint/waypoint-type",1).getValue());
- gps_wp.getNode("wp[1]/ID",1).setValue(gps_data.getNode("route/Waypoint/ID",1).getValue());
-
- waypointindex = 0;
+ waypointindex = -1;
+ screenNavigationMain.nextWaypoint();
me.loaded = 1;
},
enter : func {
Index: TurnpointScreens.nas
===================================================================
RCS file: /var/cvs/FlightGear-0.9/data/Aircraft/Instruments-3d/zkv500/TurnpointScreens.nas,v
retrieving revision 1.5
diff -u -p -r1.5 TurnpointScreens.nas
--- TurnpointScreens.nas 30 Oct 2009 18:39:12 -0000 1.5
+++ TurnpointScreens.nas 1 Nov 2009 00:25:32 -0000
@@ -18,20 +18,21 @@ var screenTurnpointSelect = {
},
start : func {
me.n > 0 or return;
- gps_wp.getNode("wp/latitude-deg",1).setValue(gps_data.getNode("indicated-latitude-deg",1).getValue());
- gps_wp.getNode("wp/longitude-deg",1).setValue(gps_data.getNode("indicated-longitude-deg",1).getValue());
- gps_wp.getNode("wp/altitude-ft",1).setValue(gps_data.getNode("indicated-altitude-ft",1).getValue());
- gps_wp.getNode("wp/ID").setValue("startpos");
-
var bookmark = gps_data.getNode("bookmarks/bookmark["~me.selected~"]/");
- gps_wp.getNode("wp[1]/latitude-deg",1).setValue(bookmark.getNode("latitude-deg").getValue());
- gps_wp.getNode("wp[1]/longitude-deg",1).setValue(bookmark.getNode("longitude-deg").getValue());
- gps_wp.getNode("wp[1]/altitude-ft",1).setValue(bookmark.getNode("altitude-ft").getValue());
- gps_wp.getNode("wp[1]/ID").setValue(bookmark.getNode("ID").getValue());
+ var scratch = gps_data.getNode("scratch");
+ scratch.getNode("latitude-deg",1).setValue(bookmark.getNode("latitude-deg").getValue());
+ scratch.getNode("longitude-deg",1).setValue(bookmark.getNode("longitude-deg").getValue());
+ scratch.getNode("altitude-ft",1).setValue(bookmark.getNode("altitude-ft").getValue());
+ scratch.getNode("ident").setValue(bookmark.getNode("ID").getValue());
if (bookmark.getNode("name") != nil)
- gps_wp.getNode("wp[1]/name",1).setValue(bookmark.getNode("name").getValue());
- if (bookmark.getNode("waypoint-type") != nil)
- gps_wp.getNode("wp[1]/waypoint-type",1).setValue(bookmark.getNode("waypoint-type").getValue());
+ scratch.getNode("name",1).setValue(bookmark.getNode("name").getValue());
+ else
+ scratch.getNode("name",1).setValue("");
+ if (bookmark.getNode("type") != nil)
+ scratch.getNode("type",1).setValue(bookmark.getNode("waypoint-type").getValue());
+ else
+ scratch.getNode("type",1).setValue("");
+ gps_data.getNode("command").setValue("obs");
blocked = 0;
me.loaded = 1;
page = 1;
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel