November 10, 200520 yr Hi all I want to set up a switch for number increase ie: (current number) (current number increases by one gives bool 1 then (new current number) (new current number increases by one gives bool 1 etc. with no limit Tried a few things but can't get the reset to the next higher number Can anyone help Paul EGLD
November 10, 200520 yr Hi PVE,Not sure, if you're talking about XML or C. In XML you can do it on this way:(L:Whatyouwant, number) 1 + (>L:Whatyouwant, number)Best RegardsMatthias
November 10, 200520 yr Author Hi Matthias I am counting each flightplan Wpt passage number with (L:wpt_pass, number) gives 1-2-3-4 etc. I want to trigger 1 bool at each number increment to update the ATA fuel, distance, etc. I have it working OK with (A:GPS IS ACTIVE WAY POINT, bool) (A:GPS WP DISTANCE, nmiles) 3 < if { But the mileage number includes altitude and the trigger point does not match the GPS change point. Regards Paul EGLD
November 10, 200520 yr Hi,I think there is a GPS variable that stores the number of waypoints left in the flight plan. Maybe (@c:FlightPlanWaypointsNumber) but I'm not sure. If you save its value at a/c startup, and then compares it with the last registered value, you should obtain something similar to a "Wpt passage number", but more accurate than the "distance less than 3 miles" solution. Just by saving the previous number and comparing with the new one like:(L:PrevFPIndex,number) (L:CurrentFPindex,number) != (>L:Flag, bool)should give what you're looking for.Tom
November 10, 200520 yr Hi,Why not use the GPS codes to show a flightplan with everything you want from it?Jan"Beatus ille qui procul negotiis..." Jan "Beatus ille qui procul negotiis..."
November 10, 200520 yr Author Hi Tom (@c:FlightPlanWaypointsNumber) gives total of waypoints. Does not change on Wpt passage. I Tried (@c:FlightPlanWaypointsNumber)(L:WPt,number) "counts up from first waypoint" != (>L:Flag, bool) just gives 1 Paul Paul EGLD
November 10, 200520 yr Author Jan I am building a simple HA! FMC using only FS9 and FSgps info. The more I add to it the more difficult it becomes. I am now reaching the limit of my skills but with some help I think I can add few more things. Paul EGLD
November 10, 200520 yr Paul,Show what you got and what you want and we will have a look.May be we can add something useful.Something like this:Jan"Beatus ille qui procul negotiis..."http://forums.avsim.net/user_files/132688.jpg Jan "Beatus ille qui procul negotiis..."
November 12, 200520 yr Hi,Made this one just for fun, it triggers a piece of music at waypointpassage.(A:GPS DRIVES NAV1,bool) if{ @FPLLineIndex (>L:waypointA,number) (@c:FlightPlanWaypointRemainingDistance,nmiles) 3 < if{ (P:Absolute time,seconds) 2 + (>L:fptimer,number) } (P:Absolute time,seconds) (L:fptimer,number) > if{ @FPLLineIndex (>L:waypointB,number) } (L:waypoint A,number) (L:waypointB,number) != if{ 1 (>L:BACH,number) (L:waypointB,number) 1 + (>L:waypointB,number) } } Of course you can do something else instead of making music.Hope it helps,Jan"Beatus ille qui procul negotiis..." Jan "Beatus ille qui procul negotiis..."
November 12, 200520 yr Author Jan Your FMC Looks nice, I tried your code but not working I don't see the macro @FPLLineIndex anywhere is it yours.Paul Paul EGLD
November 12, 200520 yr Paul,The macro is an existing one and will only work in the MS-GPS!Jan"Beatus ille qui procul negotiis..." Jan "Beatus ille qui procul negotiis..."
November 12, 200520 yr Author Jan Found the macro, closed the space between the A, changed (@c:FlightPlanWaypointRemainingDistance,nmiles) for (A:GPS WP DISTANCE, nmiles) and now get a 1 spot on time but it does not reset to 0. Nearly there. Paul Paul EGLD
November 14, 200520 yr Author OK I got it Not sure if it's best way but it works. (A:GPS DRIVES NAV1,bool) if{ @FPLLineIndex (>L:waypointA,number) (A:GPS WP DISTANCE, nmiles) 3 < if{ (P:Absolute time,seconds) 2 + (>L:fptimer,number) } (P:Absolute time,seconds) (L:fptimer,number) > if{ @FPLLineIndex (>L:waypointB,number) } (L:waypointA,number) (L:waypointB,number) != if{ 1 (>L:BACH,enum) (L:waypointB,number) 1 + (>L:waypointB,number) } } (A:GPS WP DISTANCE, nmiles) 5 < (L:BACH,enum) 1 == && if{ (P:Absolute time,seconds) 4 + (>L:fptimer,number) } (P:Absolute time,seconds) (L:fptimer,number) > if{ (L:BACH,enum) 0 (>L:BACH,enum) } Paul EGLD
November 14, 200520 yr May be this works too:(A:GPS DRIVES NAV1,bool) if{ @FPLLineIndex (>L:waypointA,number) (A:GPS WP DISTANCE, nmiles) 3 < if{ (P:Absolute time,seconds) 2 + (>L:fptimer,number) } (P:Absolute time,seconds) (L:fptimer,number) > if{ @FPLLineIndex (>L:waypointB,number) } (L:waypointA,number) (L:waypointB,number) != if{ 1 (>L:BACH,enum) (L:waypointB,number) 1 + (>L:waypointB,number) } els{ 0 (>L:BACH,enum) } } Jan"Beatus ille qui procul negotiis..." Jan "Beatus ille qui procul negotiis..."
Create an account or sign in to comment