torcs - 1.2.2

src/modules/simu/simuv3/transmission.h

Go to the documentation of this file.
00001 /***************************************************************************
00002 
00003     file                 : transmission.h
00004     created              : Mon Apr 16 16:04:36 CEST 2001
00005     copyright            : (C) 2001 by Eric Espié
00006     email                : Eric.Espie@torcs.org
00007     version              : $Id: transmission.h,v 1.5 2004/01/15 09:54:06 olethros Exp $
00008 
00009  ***************************************************************************/
00010 
00011 /***************************************************************************
00012  *                                                                         *
00013  *   This program is free software; you can redistribute it and/or modify  *
00014  *   it under the terms of the GNU General Public License as published by  *
00015  *   the Free Software Foundation; either version 2 of the License, or     *
00016  *   (at your option) any later version.                                   *
00017  *                                                                         *
00018  ***************************************************************************/
00019  
00026 #ifndef _TRANSMISSION_H_
00027 #define _TRANSMISSION_H_
00028 
00029 typedef struct 
00030 {
00031     int         gear;
00032     int         gearMin;
00033     int         gearMax;
00034 } tGearbox;
00035 
00036 typedef struct
00037 {
00038     int         state;
00039 #define CLUTCH_APPLIED   1
00040 #define CLUTCH_RELEASED  0
00041 #define CLUTCH_RELEASING 2
00042     int         mode;
00043 #define CLUTCH_AUTO     0
00044 #define CLUTCH_MANUAL   1
00045     tdble       timeToRelease;  /* remaining time before releasing the clutch pedal */
00046     tdble       releaseTime;    /* time needed for releasing the clutch pedal */
00047     tdble       transferValue;  /* 1.0 -> released, 0.0 -> applied */
00048     tdble       plip;           /* automatic plip... */
00049 } tClutch;
00050 
00051 typedef struct
00052 {
00053     tGearbox    gearbox;
00054     tClutch     clutch;
00055     int         type;
00056 #define TRANS_RWD       0
00057 #define TRANS_FWD       1
00058 #define TRANS_4WD       2
00059     tdble       overallRatio[MAX_GEARS];        /* including final drive ratio */
00060     tdble       driveI[MAX_GEARS];              /* Inertia (including engine) */
00061     tdble       freeI[MAX_GEARS];               /* Inertia when clutch is applied (wheels side) */
00062     tdble       gearEff[MAX_GEARS];             /* Gear Efficiency */
00063     tdble       curOverallRatio;
00064     tdble       curI;
00065 
00066 #define TRANS_FRONT_DIFF        0
00067 #define TRANS_REAR_DIFF         1
00068 #define TRANS_CENTRAL_DIFF      2
00069     tDifferential       differential[3];
00070 } tTransmission;
00071 
00072 
00073 #endif /* _TRANSMISSION_H_ */ 
00074 
00075 
00076 

Generated at Thu Feb 26 21:52:31 2004 for torcs by doxygen 1.3.3 written by Dimitri van Heesch, © 1997-1999
TORCS © Eric Espié 1999, 2002.