1
0
Fork 0
fgdata/Aircraft/Instruments-3d/garmin196/garmin196.nas

1 line
152 KiB
Text
Raw Normal View History

## garmin 196 functions var last_time = 0.0; var last_bearing = -1; var tab_chiffres_lettres = ["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"]; var old_status = -1; var init_variables = func{ ##version props.globals.getNode("/instrumentation/garmin196/version",1).setValue("JeeP v. 29/02/2012"); ##routes props.globals.getNode("/instrumentation/garmin196/menu_routes/search/x_char",1).setIntValue(0); props.globals.getNode("/instrumentation/garmin196/menu_routes/search/y_char",1).setIntValue(0); props.globals.getNode("/instrumentation/garmin196/menu_routes/fpl-loaded",1).setBoolValue(0); props.globals.getNode("/instrumentation/garmin196/menu_routes/waypoint-jump",1).setBoolValue(0); ##points props.globals.getNode("/instrumentation/garmin196/menu_points/x_char",1).setIntValue(0); props.globals.getNode("/instrumentation/garmin196/menu_points/y_char",1).setIntValue(0); ##aircrafts props.globals.getNode("/instrumentation/garmin196/menu_aircraft/x_char",1).setIntValue(0); props.globals.getNode("/instrumentation/garmin196/menu_aircraft/y_char",1).setIntValue(0); ##load atis freq fgcommand("loadxml", props.Node.new({ filename: getprop("/sim/fg-root")~"/Aircraft/Instruments-3d/garmin196/airports_atis.xml", targetnode: "/instrumentation/garmin196" })); ##init waypoint system props.globals.getNode("/instrumentation/garmin196/panel-wpt-bearing",1).setDoubleValue(0); props.globals.getNode("/instrumentation/garmin196/position-wpt-bearing",1).setDoubleValue(0); props.globals.getNode("/instrumentation/garmin196/panel-wpt-id",1).setValue("------"); props.globals.getNode("/instrumentation/gps/config/drive-autopilot",1).setBoolValue(0); ##pour ne pas interferer avec l'autopilot ##init map system props.globals.getNode("/instrumentation/garmin196/map-range",1).setDoubleValue(0.125); ##init dto system props.globals.getNode("/instrumentation/garmin196/dto_display/x_char",1).setIntValue(0); props.globals.getNode("/instrumentation/garmin196/dto_display/y_char",1).setIntValue(0); ##init saveable variables props.globals.getNode("/instrumentation/garmin196/antenne-deg",1).setDoubleValue(30); props.globals.getNode("/instrumentation/garmin196/light",1).setDoubleValue(30); props.globals.getNode("/instrumentation/garmin196/max-speed",1).setDoubleValue(150); props.globals.getNode("/instrumentation/garmin196/cruise-speed",1).setDoubleValue(120); props.globals.getNode("/instrumentation/garmin196/fuel-flow",1).setDoubleValue(5); props.globals.getNode("/instrumentation/garmin196/no_aircraft",1).setIntValue(0); props.globals.getNode("/instrumentation/garmin196/symbols/params/airport",1).setBoolValue(1); props.globals.getNode("/instrumentation/garmin196/symbols/params/vor",1).setBoolValue(1); props.globals.getNode("/instrumentation/garmin196/symbols/params/ndb",1).setBoolValue(1); props.globals.getNode("/instrumentation/garmin196/symbols/params/fix",1).setBoolValue(1); props.globals.getNode("/instrumentation/garmin196/symbols/params/twn",1).setBoolValue(1); props.globals.getNode("/instrumentation/garmin196/symbols/params/wpt",1).setBoolValue(1); props.globals.getNode("/instrumentation/garmin196/params/units/distance",1).setIntValue(1); props.globals.getNode("/instrumentation/garmin196/params/units/speed",1).setIntValue(1); props.globals.getNode("/instrumentation/garmin196/params/units/vert-speed",1).setIntValue(1); props.globals.getNode("/instrumentation/garmin196/params/units/altitude",1).setIntValue(1); props.globals.getNode("/instrumentation/garmin196/params/units/pressure",1).setIntValue(1); props.globals.getNode("/instrumentation/garmin196/params/units/temperature",1).setIntValue(1); props.globals.getNode("/instrumentation/garmin196/params/filtrage",1).setBoolValue(0); props.globals.getNode("/instrumentation/garmin196/params/vnav-indicator",1).setBoolValue(1); ##status du gps #0 eteint #1 startup page #1x map page #2x panel page #3x position page #50 coffee page #menus #100 = menu gps