Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

arc_2_ewevent.c File Reference

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <sys/types.h>
#include <earthworm.h>
#include <ws_clientII.h>
#include <chron3.h>
#include <ewdb_ora_api.h>
#include <ew_event_info.h>
#include <read_arc.h>

Go to the source code of this file.

Defines

#define ARC_HYP_LEN   500
#define ARC_SHYP_LEN   500
#define ARC_PHS_LEN   500
#define ARC_SPHS_LEN   500
#define ARC_TRM_LEN   74
#define ARC_STRM_LEN   74
#define MIN(a, b)   (((a)<(b)) ? (a) : (b))
#define ABS(a)   ((a) > 0 ? (a) : -(a))

Functions

time_t timegm_ew (struct tm *)
int EWEvent2ArcMsg (EWEventInfoStruct *, char *, int)
int BuildHyp (EWEventInfoStruct *, char *, int)
int BuildPhs (EWEventInfoStruct *, int, char *, int)
int BuildTerm (int, char *, int)
int ArcMsg2EWEvent (EWEventInfoStruct *pEWEvent, char *pArc, int ArcLen)


Define Documentation

#define ABS      ((a) > 0 ? (a) : -(a))
 

Definition at line 151 of file arc_2_ewevent.c.

Referenced by BuildHyp(), and wr_strongmotionII().

#define ARC_HYP_LEN   500
 

Definition at line 137 of file arc_2_ewevent.c.

Referenced by ArcMsg2EWEvent(), and BuildHyp().

#define ARC_PHS_LEN   500
 

Definition at line 139 of file arc_2_ewevent.c.

Referenced by BuildPhs().

#define ARC_SHYP_LEN   500
 

Definition at line 138 of file arc_2_ewevent.c.

Referenced by ArcMsg2EWEvent(), and BuildHyp().

#define ARC_SPHS_LEN   500
 

Definition at line 140 of file arc_2_ewevent.c.

Referenced by ArcMsg2EWEvent(), and BuildPhs().

#define ARC_STRM_LEN   74
 

Definition at line 142 of file arc_2_ewevent.c.

Referenced by BuildTerm().

#define ARC_TRM_LEN   74
 

Definition at line 141 of file arc_2_ewevent.c.

Referenced by BuildTerm().

#define MIN a,
     (((a)<(b)) ? (a) : (b))
 

Definition at line 148 of file arc_2_ewevent.c.


Function Documentation

int ArcMsg2EWEvent EWEventInfoStruct *    pEWEvent,
char *    pArc,
int    ArcLen
 

Definition at line 236 of file arc_2_ewevent.c.

References ARC_HYP_LEN, ARC_SHYP_LEN, ARC_SPHS_LEN, Hpck::azm, Hpck::codalen, Hpck::codalenObs, Hpck::codawt, Hpck::comp, Hpck::dist, Hsum::dmin, Hsum::e0, Hsum::e0az, Hsum::e0dp, Hsum::e1, Hsum::e1az, Hsum::e1dp, Hsum::e2, Hsum::erh, Hsum::erz, EW_FAILURE, EW_SUCCESS, FALSE, Hsum::gap, GSEC1970, InitEWChan(), InitEWEvent(), Hsum::lat, logit(), Hsum::lon, MAGTYPE_DURATION, Hpck::Md, Hsum::Md, Hsum::mdmad, Hsum::mdwt, Hpck::net, Hsum::nph, Hsum::ot, Hpck::Pat, Hpck::Pfm, Hpck::Plabel, Hpck::Ponset, Hpck::Pqual, Hpck::Pres, Hpck::Pwt, Hsum::qid, read_hyp(), read_phs(), Hsum::rms, Hpck::Sat, Hpck::Sfm, Hpck::site, Hpck::Slabel, Hpck::Sonset, Hpck::Squal, Hpck::Sres, Hpck::Swt, Hpck::takeoff, TRUE, and Hsum::z.

int BuildHyp EWEventInfoStruct *    pEvent,
char *    arcmsg,
int    maxlen
 

Region Code - UNKNOWN - leave blank for now

Definition at line 586 of file arc_2_ewevent.c.

References ABS, ARC_HYP_LEN, ARC_SHYP_LEN, EW_FAILURE, and MIN.

Referenced by EWEvent2ArcMsg().

int BuildPhs EWEventInfoStruct *   ,
int   ,
char *   ,
int   
 

Definition at line 836 of file arc_2_ewevent.c.

References ARC_PHS_LEN, ARC_SPHS_LEN, epochsec17(), EW_FAILURE, EW_SUCCESS, logit(), and MIN.

Referenced by EWEvent2ArcMsg().

int BuildTerm int   ,
char *   ,
int   
 

Definition at line 1307 of file arc_2_ewevent.c.

References ARC_STRM_LEN, ARC_TRM_LEN, EW_FAILURE, EW_SUCCESS, and logit().

Referenced by EWEvent2ArcMsg().

int EWEvent2ArcMsg EWEventInfoStruct *   ,
char *   ,
int   
 

Definition at line 182 of file arc_2_ewevent.c.

References BuildHyp(), BuildPhs(), BuildTerm(), EW_FAILURE, EW_SUCCESS, and logit().

time_t timegm_ew struct tm *   
 

Definition at line 107 of file time_ew.c.


Generated on Tue May 6 09:16:14 2003 for Earthworm Libs by doxygen1.3-rc3