home *** CD-ROM | disk | FTP | other *** search
-
- Approach Control
- Version 2.0
-
- A Pre-compiler for the Microsoft
- Flight Simulator Aircraft and
- Adventure Factory
-
- (c) 1993 by John Mechalas
-
-
- This program is shareware. It may be distributed freely provided that
- it is not modified in any way, and that all the accompanying files
- in this archive are distributed with it.
-
-
- - Introduction -
-
- Probably the most useful application that I have found for the Aircraft
- and Adventure Factory is the simulation of Air Traffic Control. I have
- created adventures that would simulate approach control for various
- airports across the country, and would serve the purpose of providing
- the necessary heading vectors needed to line up my aircraft for
- instrument approaches.
- Unfortunately, I found the coding of the necessary "fixes" and commands
- to be a tedious process, but since the basic command structure of the AAF
- file was roughly the same all the time, I was able to come up with a
- program that could automatically generate the necessary source code for
- the AAF compiler, with only a minimum of input and effort.
- Approach Control reads a data file that contains basic airport
- location and runway information and creates the source code necessary
- for AAF to compile an adventure file. With this program, you can create
- an approach control simulator within (literally) a matter of seconds,
- instead of the hours that it would take to code manually. And, absolutely
- no programming is necessary.
- After compiling the resulting source code with Adventure Factory's
- AFF.EXE program, you are ready to go. If you want to fly into Indianapolis
- International Airport, for example, you simply load your adventure file
- containing the data for Indy's airport into Flight Simulator, then start
- flying. Once you are within 40 miles of the airport, you would be told
- to contact Indianapolis Approach, and approach control would proceed to
- vector you in for an instrument approach on the runway favored by the
- local surface winds.
-
-
- - What You Need -
-
- Naturally, you will have to have both Microsoft Flight Simulator version
- 4.0 and the Aircraft and Adventure Factory. Until Flight Simulator version
- 5.0 is released (whenever that will be), I can make no guarantees as to
- whether or not the adventure files created by this program will work with
- v5.0, since I can not predict whether or not the Flight Simulator variables
- I make use of in this program will become obsolete.
- It is also recommended that you have the Aircraft and Scenery Designer.
- Without it, you will only have the ILS approaches available on scenery
- disks, which will limit the usefulness of any adventure files created
- by this program. With A&SD, you can provide full ILS support at each
- airport, and hence a corresponding adventure file to vector you in for
- a final approach.
- All communications generated by the resulting adventure file will be
- printed to the screen, so you won't need a special sound card to make use
- of the adventures-- I tried to make the program as universal as I could.
- However, if you do own a sound card, I have added the option of playing
- recorded/digitized speech in addition to printing the ATC commands. The
- APP.EXE program will ask if you wish to include speech in your adventure,
- so if you do not have a sound card, or don't care for the recorded voices,
- simply answer "no".
-
-
- Section 0: Quick Start
-
- If you want to get started quickly and test out the sample adventure
- (OHARE.APP), just type APP and when asked for the input file, enter
- OHARE. APP will then create a file called OHARE.AAF ... Simply compile
- this using the AAF compiler by typing AAF OHARE.AAF OHARE.ADV. You will
- now have an adventure file titled "OHARE.ADV" in your directory which
- you can now load and run from Flight Simulator. (A good flight for
- this adventure would be from Kankakee Airport to O'Hare International).
-
-
- Section 1: Running the Program
-
-
- 1.1 Creating the Airport File
-
- In order to build an adventure file, APP needs to read in an input
- file that contains the necessary airport information. When you first
- run the program, APP will ask you for the name of that input file,
- which must have a .APP extension. If the file does not exist, you
- will be asked if you want to create it. At this point, you can
- enter "y" to go to the file creation utility.
- Here, you will be asked several questions about the airport which
- you wish to model approach control for. The best way to explain the
- process is by example, so we will "build" a sample file for Willard
- Airport in Champaign, Urbana (this airport is supported by the FS4.0
- default scenery, so you can test your file after we are done). Another
- sample input file, already created for you, is included in this package
- that covers Ohare Airport in Chicago.
- Any lines beginning with a '>' are responses from the APP.EXE
- program. Entries in capital letters are meant for you to enter in
- response to the questions that APP will ask you.
-
- > C:\FLTSIM> APP.EXE
- >
- > Approach Control Version 2.0
- > A Pre-Compiler for the Microsoft
- > Flight Simulator Aircraft and
- > Adventure Factory
- >
- > Enter input filename: WILLARD
-
- You do not need to add the .APP extension...the program will do that
- for you. In fact, due to teh string-handling routines I used, if
- you enter a name greater than 8 characters, or with an extension of
- your own, you may get some bizarre results.
-
- > File does not exist. Do you wish to create it? Y
- >
- > Is there a control tower at this airport? Y
-
- Willard has an active control tower. If we had answered "N" to this
- question, the program would have you contact Willard Unicom instead
- of Willard Tower when appropriate.
-
- > Enter airport name (eq "Ohare"): WILLARD
- > Enter Willard tower or unicom radio frequency: 120.40
-
- The airport name is Willard, and the radio frequency of the Willard
- tower is 120.40. Not that you wouldn't really want to enter the
- name in all CAPS like above. This is only done to help clarify the
- data entry process as described above.
-
- > Enter approach control name (eq "Chicago"): CHAMPAIGN
- > Enter Champaign approach radio frequency: 121.35
-
- Note that the name of approach control is not necessarily the same as
- the airport tower. This is particularly the case at small airports
- that are near major facilities. In this case, Willard is under
- Champaign APproach Control, and the radio frequency is 121.35.
-
- > Is this correct? Y
-
- If we enter "N", we will re-enter all of the above information.
-
- > Enter airport NORTH coordinate: 16400
- > Enter airport EAST coordinate: 16465
-
- Here we need to tell APP where the airport is located in the FS world.
- Simply enter the FS coordinates given in your scenery disk info sheets.
- These values MUST be integers, so round them off to the nearest whole
- number. If you enter a floating-point number, you may get some very
- bizarre results.
-
- > Is this correct? Y
-
- Gives you a chance to correct errors in the airport location.
-
- > Enter first altitude assignment: 4000
- > Enter second altitude assignment: 2600
-
- ATC will assign you to a certain altitude when you are a given distance
- from the airport. The first altitude assignment is given at about 30 NM
- and the second is given at 15 NM. You will want the first altitude
- to be higher than the second, and both must be integer values.
-
- > Is this correct? Y
-
- Enter "Y" or "N" as needed.
-
- > Enter the magnetic variation (positive values for east,
- > negative values for west variation): 0
-
- Here we tell APP what the local magnetic variation is. The best way to
- determine the variation is to enter SLEW mode in FS4.0 and hit both
- ALT keys simultaneously. This will turn your aircraft so that it
- points to true north. Next, simply read off the value showing in your
- magnetic compass. If the compass shows a number from 0 to 180 degrees,
- variation is west. If the compass reads from 180 to 360 degrees, then
- variation= 360 - compass east. (eg: If your compass reads 358 degrees,
- the magnetic variation is 2 degrees east). West variation should be
- entered as a negative number, so if variation is 4 degrees west, enter
- -4 in response.
- This number must also be an integer, so round off to the nearest whole
- number. At Champaign, variation is roughly 0.1 degrees East, so we'll
- enter 0 degrees.
-
- > Is this correct? Y
-
- Self-explanatory.
-
- > How many instrument approaches? 4
-
- Willard airport has six runways, but only four of them have published
- instrument approaches. This tells APP how many approaches we are going
- to enter.
-
- > Is this correct? Y
-
- To correct your mistakes.
-
- > Enter runway number: 4
- > Enter runway/approach heading: 54
- > ILS, LOC, VOR, or NDB approach? VOR
-
- Now we begin entering the approach information. There's a lot to digest
- here, so we'll try to take it in slowly.
- First, we have to tell APP which runway we are entering data for. At
- the present time, all runway information has to be entered in ASCENDING
- NUMERICAL ORDER. Also, APP does not currently differentiate between
- Left, Center, and Right runways. So, if your airport has both a 4L and
- a 4R approach, you should only enter runway 4 once. Whether you choose
- to land on 4L or 4R during flight is up to you, though if one runway has
- a higher-precision approach, you will probably want to simulate it (the
- highest precision approaches are ILS, followed by LOC, VOR, and NDB
- approaches, in that order).
- A good example of this is the example OHARE.APP file. Ohare has
- parallel runways for every instrument approach. Runway 4R features an
- ILS approach, and 4L an LOC approach. Since the ILS is a higher-
- precision system, runway 4 is entered as an ILS approach.
- The published instrument approach procedures can be found in both
- NOAA Terminal Approach Procedure plates or the Jeppsen plates, both of
- which are probably available at your local airport.
- ILS systems transmit both localizer and glideslope information. By
- tuning the ILS frequency on your NAV radio, you follow both the localizer
- and the glideslope down to the runway.
- An LOC system consists of a localizer beacon only, and does not transmit
- any glideslope information.
- In a VOR approach, you tune in a radial for the airport's VOR beacon
- and follow that radial in until you can visually line yourself up for a
- landing. The heading of the runway does not necessarily match that of
- the approach radial.
- For NDB approaches, you track the given non-directional beacon with your
- ADF guage. When you intersect the NDB, you turn to a certain heading and
- follow it in until you can visually line up with the runway as in a VOR
- approach.
- At Willard, runway 4 is supported with a VOR approach (in this case,
- you track radial 54 of the CMI VOR on 110.00).
- Note that the approach type must be entered in all CAPS, so if you enter
- "ils" instead of "ILS", the program will prompt you to re-enter.
-
- > Enter runway number: 14
- > Enter runway/approach heading: 136
- > ILS, LOC, VOR, or NDB approach: LOC
- >
- > Enter runway number: 22
- > Enter runway/approach heading: 207
- > ILS, LOC, VOR, or NDB approach: VOR
- >
- > Enter runway number: 32
- > Enter runway/approach heading: 316
- > ILS, LOC, VOR, or NDB approach: ILS
- >
- >
- > Runway 4: VOR heading 54 degrees
- > Runway 14: LOC heading 136 degrees
- > Runway 22: VOR heading 207 degrees
- > Runway 32: ILS heading 316 degrees
- >
- > Is this correct? Y
-
- The rest of the approach information.
- After answering "Y", to confirm that all information has been entered
- correctly, the program will write a data file called WILLARD.APP to the
- current directory. It will then proceed to create the WILLARD.AAF file
- from the information in the .APP file.
-
-
- 1.2 The APP.EXE Pre-Compiler
-
- Once you have created or read in a valid input file, the APP program
- will begin generating the source code for the AAF compiler. Some
- information will be printed to the screen, and you will be prompted if
- you want to include the digitized speech in your adventure program.
-
- > Do you want digitized speech in your adventure file? N
-
- If you want digitized speech, enter "Y". Check your AAF manual for
- hardware requirements.
-
- > Variation is 0 degrees.
- > 4 runways.
- > 4 54
- > 14 136
- > 22 207
- > 32 316
-
- Here, the runway information is printed back as a For Your Information
- feature. It confirms that your runway data has been read properly. Note
- that the runway headings are adjusted according to the magnetic variation.
-
- > 54 5 95
- > 136 95 171
- > 207 171 261
- > 316 261 5
-
- Here, the runway headins are printed along with the boundaries for runway
- selection according to the local winds. If, for example, the surface winds
- were between 5 and 95 degrees, you would be vectored to land on runway
- 4, which has an approach heading of 54 degrees.
- Again, this is an FYI listing, only.
- After this point, the program will complete in a manner of seconds, and
- you will have a file called WILLARD.AAF in your current directory. You
- can now compile it using the AAF.EXE program.
-
-
- Section 2: Compiling Your Adventure Program
-
- To compile your program, simply follow the procedure as given in your
- AAF manual. In our above example, we would type:
-
- > C:\FLTSIM> AAF WILLARD.AAF WILLARD.ADV
-
- If, however, you are lazy like me, then you can instead use the batch file
- AF.BAT that is included in this archive. Simply type:
-
- > C:\FLTSIM> AF WILLARD
-
- This is equivalent to the full command line given above. The syntax is as
- follows:
-
- AF <infile>
-
- This is equivalent to typing:
-
- AAF <infile>.AAF <outfile>.ADV
-
-
-
- Section 3: The Input File
-
- APP.EXE reads an input file that you create and turns it into source
- code for the Aircraft and Adventure Factory. A sample input file,
- OHARE.APP, is provided in this archive to help you understand the
- structure of the input file, as well as give you an sample adventure to
- experiment with (O'Hare airport at Chicago is available on the FS4 default
- scenery, and provides full ILS support. It was included as a sample file
- so that anyone could use the it, since not all of us have scenery disks or
- the Scenery Designer). It is compatible with the FS4.0 default scenery.
- The structure of the file is outlined below, and I will explain the
- OHARE.APP input file in detail so that it is easier to understand the format.
- Quite a few changes have occurred between Approach Control versions 1.0 and
- 2.0, so if you have the previous version, you will want to check out the
- WHATS.NEW file included in this archive.
-
-
- 3.1: File Format for .APP input files.
-
- Line 1 (Airport location):
-
- NORTH and EAST coordinates, seperated by a space. Both must be integers.
-
- Line 2 (Approach control frequency and name):
-
- Radio frequency of approach control, followed by the name, seperated
- by a space.
-
- Line 3 (Tower frequency and name):
-
- Frequency of airport tower or unicom, followed by the tower "flag",
- and then the airport name; all seperated by a space. The tower flag is
- either 0 or 1, and is defined as follows--
-
- 0 -- No tower at the airport. Use Unicom.
- 1 -- Airport has a tower.
-
- Lines 4-6 (Distance from airport to "fixes"):
-
- These are default values given by the program. You should not need
- to change them unless you find that ATC vectors you through a mountain
- or something. By changing the numbers here, you change the distance
- from the airport to the various "fixes" that ATC vectors you to during
- your approach. These can be floating-point numbers.
-
- Lines 5-7 (Angles for "fixes" with respect to runway headings):
-
- Again, these are default values that you should not have to change.
- They represent the angles between the runway and the various fixes
- described above. These can be floating-point numbers, and are given
- in FS Units (1 NM = 7.2 FS Units).
-
- Lines 8-9 (Altitude assignments)
-
- Here is where the altitude assignments are stored. The first number
- is the altitude, and the second is the distance from the airport at which
- the altitude assignment is given. All numbers are integers.
-
- Line 10 (Magnetic Variation):
-
- Magnetic variation. + for east, - for west. Must be an integer.
-
- Lines 12 - ?? (Runway information)
-
- Here is where the runway information is stored. The first is the ruway
- number, the second is the runway heading, and the third is a flag denoting
- the approach type. All numbers are integers, and the flag is defined as
- follows:
-
- 1 -- ILS approach
- 2 -- LOC
- 3 -- VOR
- 4 -- NDB
-
-
- 3.2: The OHARE.APP Sample File
-
- The first line of the input file describes the location of the airport
- in FS units. For O'Hare, the location is 16244N and 16578 E.
-
- 17244 16578
-
- The second line tells the compiler what frequency approach control uses
- for communication, along with the name of that approach control center.
- Note that the airport name and approach control name are not necessarily
- the same.
-
- 119.00 Chicago
-
- Line three gives the tower frequency of the airport's ATC tower, along
- with it's name. The "1" denotes that there is a tower available at the
- airport.
-
- 126.90 1 O'Hare
-
- The next six lines define the locations of the various "fixes" that
- ATC guides you into during your approach. These numbers should not
- have to be changed, but I am allowing you to do so if you wish. For
- the most part, however, the numbers given in the OHARE file will work
- well for almost all airports.
- Looking at the OHARE file, we can see that the fixes are located
- roughly 88, 132, and 171 FS units from the airport, and are at angles
- of 18, 45, and 89 degress to the runway heading. (This is a difficult
- concept to explain, but since you shouldn't need to change any of these
- numbers, I won't bore you with the gory details).
-
- 87.5322
- 132.4499
- 171.4833
- 17.7435
- 45.2737
- 88.6013
-
- At certain distances from the tower, your aircraft should be assigned
- lower altitudes to prepare you for your approach. The next two lines
- define what the new altitude assignment is, and at what distance
- from the airport (in miles) they are given. Although you probably
- shouldn't have to change the distance at which a new assignment is
- given, the actual assigned altitudes themselves will have to be adjusted
- according to the local ground level.
- In the OHARE file, an altitude of 5000 feet is assigned at 30 miles
- from the airport, and an altitude of 2700 feet is assigned at 15 miles.
-
- 5000 30
- 2700 15
-
- The magnetic variation is about 1 degree west, so we enter a -1 on the
- next line.
-
- -1
-
- Here is where you tell the program how many runways you have. At O'Hare,
- we have six. Note that the current version of Approach Control does not
- distinguish between left, right, or center runways. If there is a
- runway 19R and 19L, simply enter runway 19 once, and when you are vectored
- to land on runway 19, you can choose either the left or right runway as
- you see fit.
-
- 6
-
- Here we enter the runway data. The first number is the actual runway
- number, and the second number defines the runway heading. Again, as
- mentioned above, the current version of Approach Control does not
- distinguish between left, right, and center runways. All runways are
- ILS supported, so each has the "flag" set to "1".
-
- 4 42 1
- 9 90 1
- 14 140 1
- 22 222 1
- 27 270 1
- 32 320 1
-