1
0
Fork 0
Commit graph

5667 commits

Author SHA1 Message Date
ehofman
63c1f4b613 Mathias Fröhlich:
This patch makes the aircraft carrier's hardware  appear in the scenegraph.
2004-11-26 10:24:48 +00:00
curt
91ae7ce82a Add a *really* crude model of ITT, Oil Temp, and Oil Pressure. This
currently just returns a lagged normalized value in the range of 0-1 that
is proportional to N1.  It's up to the engine gauge to scale to the right
range.  This is for lack of a real model of these items so we can have
something to drive the engine gauges.
2004-11-23 21:35:30 +00:00
ehofman
7159e318e1 Mathias Fröhlich:
I have now split out the ground cache functions into src/FDM/groundcache.[ch]xx
Attached are the two files and the patch to integrate that cache into
FGInterface.

The code is nowhere used at the moment, the fdm's need to be updated to use
that ground cache. The JSBSim-dropin.tar.gz from Martins ftp server does this
for example.

The carrier's scenegraph is not yet processed to be visible for ground
intersection testing. So the only benefit up to now is that the api is set
up. Using this I can put the changes to make JSBSim work with that into
JSBSim's cvs. Also I aim to provide Andy a patch to make use of that with
YASim.
2004-11-22 10:10:33 +00:00
curt
16ca655c03 More FreeBSD fixes ... add -lusbhid where needed. 2004-11-21 03:15:19 +00:00
ehofman
4de23ad628 Melchior FRANZ:
Use a suggested exit method as described in the SDL_Quit man page. (fgOSExit() is still uncalled in both fg_os.cxx (glut) and fg_os_sdl.cxx, which makes these functions kind-of useless.) The other changes are fixes for gcc 3.3.4 warnings.
2004-11-20 13:04:26 +00:00
ehofman
b859e77072 MacOS X fix. 2004-11-20 12:47:42 +00:00
ehofman
337d0d1be6 Add some missing bits from Mathias' carrier code. 2004-11-20 12:44:42 +00:00
curt
161fb0c770 Various property name changes relating to moving the kr-87 adf to
/instrumentation
2004-11-19 23:56:12 +00:00
curt
1c2c76709e Roy Ovesen: remove src files from Cockpit and move them over to Instrumentation. 2004-11-19 23:10:44 +00:00
curt
e9b70e3ab8 Changes by Roy Ovesen to begin migrating the avionics out of the Cockpit
directory and over to the Instrumentation directory and make them modular
in the sense of being able to pick and choose what you include with any
particular aircraft.
2004-11-19 23:01:34 +00:00
curt
d05121ef46 Fix my mailing address by replacing it with my web page. 2004-11-19 22:10:41 +00:00
curt
62df58d4f8 I have added Aaron Wilson's virtual 3d runway projection to the HUD.
Aaron says:

I just got the virtual runway hud projection working on all views and
2D & 3D HUDs.  It is working awesome(see below).  I have attached every
file that was modified (hud.hxx, hud.cxx, and the default.xml for the hud)
and every file that was added (hud_rwy.cxx and runwayinstr.xml).

Just a quick overview of how the instrument works.

The virtual runway is projected by getting the "cockpit view" of the
runway in 3D and projecting the points on to the 2D HUD.  Therefore, the
virtual runway will be displayed the same in every view.  For example,
you can land an aircraft from the "Tower View" by flying the HUD.  Also
if you're in "Cockpit View" and it is centered then the virtual runway
lines will perfectly outline the actual runway.  I am getting the active
runway via the wind like done in the ATC classes, which may need changed.
Also, I made the assumption the view 0, in view manager, is always the
cockpit view, which may need changed as well.

The runway configuration file will allow you to specify a center offset
(x,y) and a bounding box (width,height).  You can also configure the line
stipple pattern for the outside and the center line.  For instance, if
you wanted a 0xFAFA pattern, then specify 64250 as the value.  If you
want a solid line, you can specify -1 or 65535 (0xFFFF) and zero will
turn the line off.  It also draws a runway indication arrow when the
runway is not in the HUD or it can be drawn all the time if arrow_always
is true.  The arrow will point in the direction of the runway (2D) by
rotating around the center  at a radius of arrow_radius.  If you wish to
turn the arrow off, you must set the arrow_scale <=0.  The arrow really
should be 3D arrow that points to the runway (or points in the direction
of the aircraft-to-runway vector).
2004-11-19 18:31:02 +00:00
ehofman
ddb15394ee Mathias FröhlichMathias Fröhlich:
Add some controls required for carrier operations:

/controls/gear/launchbar

should be 1.0 if the launchbar is lowered, that means the aircraft should now
be arrested at the catapult.

/controls/gear/catapult-launch-cmd

Should be set to 1.0 when the aircraft should be launched from tha catapult.
2004-11-19 12:33:53 +00:00
ehofman
3c0ab43b43 Mathias Fröhlich:
The moving ai models will jump around realtive to the moving aircraft model.
I can see that with the carrier but others have noticed that too with ai
aircraft before.
The reason is that all SGSystems are called with a dt value which is not
necessarily a multiple of 1/hz.
In contrast, most FDM's use the _calc_multiloop function from FGInterface
which forces the time update to be a multiple of 1/hz for the FDM aircraft.
As a result, in the worst case, the FDM aircraft has moved nearly 1/hz seconds
further than the rest of flightgear (1/120sec*300kts that is about 1.3m).
That patch forces the time update to be a multiple of 1/hz.
2004-11-19 12:33:08 +00:00
curt
4214cd6c10 Migrate FlightGear code to use "#include SG_GL*" defined in
"#include <simgear/compiler.h>".
2004-11-18 19:53:00 +00:00
curt
225af83b32 This code is written on top of a driver interface only available with linux
(/proc file system) so it doesn't make sense to have other OS's trying to
open these files because they could never exist.
2004-11-18 17:40:03 +00:00
curt
a1265ddc1d - ATC-Inputs.cxx: Fix some portability problems for non-linux operating
systems.  Fix a couple bugs/oversights.

- atc610x.cxx: Much code has moved into the configurable input mapper
  (ATC-Inputs.cxx) and the remaining input massaging code has moved into
  the atcsim.nas module.
2004-11-18 05:04:35 +00:00
curt
7f9566111d Tweak the atcsim command line interface. 2004-11-18 05:01:19 +00:00
curt
11548e9e7e Minor white space fix. 2004-11-18 05:00:44 +00:00
curt
93faf0afc3 Add a local copy of the nasal documentation. 2004-11-17 02:54:04 +00:00
curt
d66c4c1d82 Get rid of a stray character that must have introduced itself with my random
keyboard fumbling.
2004-11-16 19:48:42 +00:00
ehofman
3142457537 Remove some changes I had put in to make it compile. those are no longer needed. 2004-11-16 19:48:09 +00:00
curt
2eeddb8c9f Begin work on revamping the ATC hardware interface so it is infinitely more
configurable.
2004-11-16 19:47:11 +00:00
ehofman
9a8eaae03d commit some pending updates from Vivian 2004-11-16 09:33:21 +00:00
andy
d43d10046b Melchior caught a missing return value that is now an error on newer gcc versions 2004-11-15 18:15:33 +00:00
ehofman
2c72f13163 Roy Vegard Ovesen:
We have decided that hardcoded initialization of instruments and systems is
bad. So we remove them.

Hardcoded initialization is bad because it can't be overridden from config
files or from the command line. We prefer to do it through config files that
should be, eventually, aircraft specific (*-set.xml), not global
(preferences.xml).
2004-11-13 15:00:00 +00:00
ehofman
2df4a3b685 Vivian Meazza:
I attach the latest version  of Nimitz. The textures have been improved. A glide-path has been added, it is on by default, but can be switched off by means of the properties browser: /ai/models/ship/controls/glide-path. The origin has been adjusted to the turning pivot and approximate roll center.

Modified AiShip files are also attached. These allow the radius of the turning circle of a ship to be input. The turning circle is adjusted for speed and rudder angle. Roll has been corrected so that a ship leans out of a turn, not inwards like an aircraft. The roll angle is adjusted for speed and rudder angle (yes, application of more rudder reduces roll angle - rudders act as stabilizers).


TODO

Add a relative wind calculation so that a carrier can be turned to the appropriate launch and recovery courses.

Add a 'flight plan' so that the carrier can carry out a racetrack for flight ops.

Add a projector landing sight.

Add auto-land facilities.
2004-11-13 14:45:57 +00:00
david
42322949fa Reverted last changes, because they caused needle flips near 0. 2004-11-10 20:01:28 +00:00
ehofman
5733464305 Melchior FRANZ:
The caption should already be set when the window is opened. This is
important for some window managers. (KDE's kwin, for example, can store
special settings for certain windows, such as "no border" and "always
on top". KDE uses the window title to determine if a special rule is
to be applied. KDE will be made more tolerant, too.)
2004-11-08 17:41:30 +00:00
ehofman
85df309a3b David Culp:
Here are files to get automated contrails working.  I've set up contrails for
the 737, using my simple, untextured contrail model.  Vivian has made another
contrail model, but I'm still trying to get his to work.  I'm hoping others
will try to make contrail models also.

Here's some code that defines a top to thermals.  When the top of a thermal is
reached the strength is phased-out linearly over the next 100 feet of
altitude.  At first I tried just capping the thermal at the top, but the
change in thermal strength was too fast for the FDM to handle well.

Included is a new version of the thermal scenario that includes a top
(height-msl) to the thermal.  The default value is 5000 feet.
2004-11-07 14:46:21 +00:00
ehofman
3420e23833 MSVC fix. 2004-11-07 14:23:48 +00:00
david
2f13bafff5 Use angular momentum so that the compass can overshoot and oscillate
before settling.
2004-11-06 16:23:18 +00:00
david
079bc3196e Fixed typo that prevented DME groundspeed display. 2004-11-06 16:22:17 +00:00
david
0f2aad8320 Minor code clean-up. 2004-11-06 16:21:41 +00:00
david
b0c1fb7755 Added acceleration error to compass (most obvious during heavy braking
on the ground) -- this is based on some wild guesses, but it seems
reasonable for now.

The next step will be to give the compass some angular momentum so
that it does not snap instantly to a heading, and so that it can
overshoot a heading and oscillate.
2004-11-05 00:18:58 +00:00
david
04842a0f5b Add errors for pitch, based on a modified equation contributed by
Chris Metzler.
2004-11-04 02:24:46 +00:00
david
956823b161 Begin a rewrite of the magnetic compass code. So far, only northerly
turning error is supported, and I don't know if this works properly in
the southern hemisphere.
2004-11-03 15:59:49 +00:00
david
63cb4e59b7 Begin a rewrite of the magnetic compass code. So far, only northerly
turning error is supported, and I don't know if this works properly in
the southern hemisphere.
2004-11-03 15:15:32 +00:00
david
889dba8d65 Make FlightGear work with 16bpp:
1. Check that SDL actually initializes successfully and sets up its
   video mode.

2. Do not try to enable stencil in 16bpp.
2004-11-03 04:18:27 +00:00
curt
b82cc40c58 Make separate left/right flap surface positions in the net_fdm.hxx
structure for future use.  Right now they are tied together.
2004-10-29 00:13:32 +00:00
ehofman
e3c89b1d33 gcc fixes. 2004-10-28 11:03:15 +00:00
ehofman
73313ed0e1 Boris Koenig:
After applying the attached patches (based on latest CVS) you should
have a new option available within your version that should also
show up using fgfs --help, the syntax is:

    fgfs --min-status={level} --show-aircraft

whereas "level" can be anything between

    "alpha","beta","early-production" and "production"

Of course running something like

    fgfs --min-status=alpha --show-aircraft

should not return any aircraft right now, as none of the
current aircraft definition files in your base-package is using the
required

    <status></status>

tag - but you can easily give it a try by adding something like

    <status>alpha</status>

The tag should be placed as a sub-tag within <sim> - so directly behind
the <description> tag would be just fine and straight-forward.
2004-10-28 09:37:21 +00:00
ehofman
4668174848 Move the submodels from the /systems proprty subtree into /ai instead. 2004-10-28 08:44:24 +00:00
ehofman
670ea7c881 David Culp:
Here's code to support a new AICarrier class, which I think will be
sufficiently different from a basic AIShip that it should have its own class.
2004-10-28 08:33:55 +00:00
ehofman
e5b1ab4831 Vivian Meazza:
As a result of recent requests, I've implemented the ability to switch off
aerodynamic stabilisation:

This has to be added to the submodel.xml files:

<aero-stabilised>false</aero-stabilised>

When false the submodel retains the pitch given at instantiation.

It defaults to true.
2004-10-28 08:29:15 +00:00
ehofman
2a94cedeba Fix some warnings. 2004-10-26 12:09:31 +00:00
ehofman
ba7fd47740 Roy Vegard Ovesen:
I've made an encoder and a transponder. The transponder gets C-Mode altitude
information from the encoder. These two might not be very usefull right now,
but I think they might come in handy when the ATC network gets going.
2004-10-26 12:06:45 +00:00
ehofman
5071415bd1 Melchior FRANZ:
input.cxx allocates memory for js->getNumAxes() axes and for jsCaps.wNumButtons
or MAX_JOYSTICK_BUTTONS buttons per joystick. But it doesn't check if some
xml config defines bindings for more axes/buttons, in which case it writes
to unallocated memory and causes crashes. This is a real world example:
sidewinder-force-feed-pro.xml defines 7 axes, but only newer versions of
this js do actually have that many. Older ones (-> gameport) don't. The patch
drops unused and unusable bindings.
2004-10-24 14:45:52 +00:00
ehofman
0ab2a40c2a Roy Vegard Ovesen:
I've added two new debug log types for the instrumentation and systems. They
used to use the autopilot debug log, because I couldn't figure out how to
make new log types. Well, now I have figured it out.  ;-)
2004-10-24 11:05:14 +00:00
ehofman
5192c5bc7d Add loadxml/savexml commands and textbox gui dialog. 2004-10-24 09:26:00 +00:00