-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrapic_routines.h
118 lines (109 loc) · 3.56 KB
/
rapic_routines.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
#include "rsl.h"
typedef struct {
char *s;
int len;
} Charlen;
typedef struct {
int country; /* 000 */
char namestr[20]; /* Berrima */
int station_id_no; /* 63 */
float lat; /* 12.457 */
float lon; /* 130.925 */
float height; /* 40 (meters) */
int datno; /* 02798 (jjjyy) */
float hhmm; /* 05.00 */
char yyyymoddhhmmss[20]; /* 1998012705001 */
float versionNumber; /* 10.01 */
int freq; /* 5645 */
int prf; /* 740 */
float pulselen; /* 0.9 */
int range_resolution; /* 500 (meters) */
float anglerate; /* 15.0 */
char clearair[4]; /* "ON" or "OFF" */
float angle_resolution; /* 1.0 (degrees) */
int video_resolution; /* 256 */
int start_range; /* 1000 (meters) */
int end_range; /* 256000 (meters) */
char product_type[10]; /* VOLUMETRIC */
int scannum; /* Scan n of m */
int ofscans; /* m */
char imgfmt[20]; /* PPI, RHI, etc. */
float elev; /* 0.5 (degrees) */
char video[20]; /* Vel, Wid, ... */
float vellvl; /* 9.8 */
float nyquist; /* 9.8 */
float ratio1, ratio2; /* x:y, None */
int nbins; /* Number of values in Rapic_range vector. */
} Rapic_sweep_header;
typedef struct {
float x; /* Dummy. */
} Rapic_range;
typedef struct {
Rapic_sweep_header h;
Rapic_range *r;
} Rapic_sweep;
void binprint(char *s, int n);
void rapic_decode(unsigned char *inbuf, int inbytes, unsigned char *outbuf, int *outbytes,
float *azim, float *elev, int *delta_time);
void rapic_fix_time (Ray *ray);
void rapic_load_ray_header(Rapic_sweep_header rh, int iray, int isweep, float elev, float azim, Ray_header *h);
void rapic_load_ray_data(unsigned char *buf, int bufsize, int ifield, Ray *ray);
Radar *fill_header(Radar *radar);
/* These functions were moved here otherwise linking to the shared "rsl.so" object would result in missing yylex / yywrap errors */
int yylex(void);
int yywrap();
/* I want to have the rapic prefix in the yacc parser.
* This hack is required.
* I got this list from automake.html.
*/
/*
#define yymaxdepth rapicmaxdepth
#define yyparse rapicparse
#define yyerror rapicerror
#define yylval rapiclval
#define yychar rapicchar
#define yydebug rapicdebug
#define yypact rapicpact
#define yyr1 rapicr1
#define yyr2 rapicr2
#define yydef rapicdef
#define yychk rapicchk
#define yypgo rapicpgo
#define yyact rapicact
#define yyexca rapicexca
#define yyerrflag rapicerrflag
#define yynerrs rapicnerrs
#define yyps rapicps
#define yypv rapicpv
#define yys rapics
#define yy_yys rapicyys
#define yystate rapicstate
#define yytmp rapictmp
#define yyv rapicv
#define yy_yyv rapicyyv
#define yyval rapicval
#define yylloc rapiclloc
#define yyreds rapicreds
#define yytoks rapictoks
#define yylhs rapiclhs
#define yylen rapiclen
#define yydefred rapicdefred
#define yydgoto rapicdgoto
#define yysindex rapicsindex
#define yyrindex rapicrindex
#define yygindex rapicgindex
#define yytable rapictable
#define yycheck rapiccheck
#define yyin rapicin
#define yyout rapicout
#define yy_create_buffer rapic_create_buffer
#define yy_load_buffer_state rapic_load_buffer_state
#define yyrestart rapicrestart
#define yy_init_buffer rapic_init_buffer
#define yy_switch_to_buffer rapic_switch_to_buffer
#define yy_delete_buffer rapic_delete_buffer
#define yy_flush_buffer rapic_flush_buffer
#define yy_scan_buffer rapic_scan_buffer
#define yy_scan_string rapic_scan_string
#define yy_scan_bytes rapic_scan_bytes
*/