Files
DP44/Common/DTS.Common.Serialization/DDAS (Chrysler)/ChannelDefinition.h
2026-04-17 14:55:32 -04:00

61 lines
1.9 KiB
C

/////////////////////////////////////////////////////////////////////////////
// ChannelDefinition.h
// --------------------
// Defines a data channel (based on DDAS testplan.h)
//
//
// AUTHOR: A. J. Owski
// LOC: 1250
// DEPT: 5260 Tool Development
// (formerly Instrument Systems)
//
// COPYRIGHT: (c) 2002 DaimlerChrysler Corp.
//
// REVISIONS: (most-recent at top of list).
//
// Date Init Description of Change
// ---- ---- ---------------------
// 11/08/04 wjp Remove redundant CalDate from Channel definition and label the
// field as spare bytes. Use the date in the transducer structure,
// which is part of the channel definition.
//
#if !defined( CHANNEL_H )
#define CHANNEL_H
#include "TransducerDefinition.h"
enum ChannelFlags{CHANFLAG_ACTIVE};
// Channel State Macro's
#define ISCHANACTIVE(pChan)(pChan->Flags&(1<<CHANFLAG_ACTIVE)?1:0)
#define SETCHANACTIVE(pChan)(pChan->Flags|=(1<<CHANFLAG_ACTIVE))
#define CLRCHANACTIVE(pChan)(pChan->Flags&=(~(1<<CHANFLAG_ACTIVE)))
// Channel Data Structure
typedef struct tagCHANNEL
{
short Size; // Size of this object
short Flags; // Channel Flags
char Name[64]; // Channel Name
char Sign[8]; // Sign +, -, or blank
char Axis[8]; // X,Y,Z,FX,MX,AX,...
float FilterFreq; // Channel Filter Class (in Hz)
float SetGain; // Gain setting (1 - n)
float ActGain; // Actual (measured?) gain setting.
float Rcal; // Shunt cal resistance
float Excitation; // Excitation Voltage (when programable)
// time_t CalDate; // Calibration date (Remove - redundant)
byte byteSpares[4]; // Spare bytes (was Cal Date)
TRANSDUCER Transducer; // "Snapshot" of transducer values
} CHANNEL;
typedef CHANNEL *PCHANNEL; // Pointer to a channel
typedef CHANNEL *PCHAN; // Even shorter version of above
#endif // !defined( CHANNEL_H )