32 static airs_rad_gran_t airs_rad_gran;
39 (
"Give parameters: <orbit.tab> <airs_l1b_file> [ <airs_l1b_file2> ... ]");
42 printf(
"Write orbit data: %s\n", argv[1]);
43 if (!(out = fopen(argv[1],
"w")))
44 ERRMSG(
"Cannot create file!");
48 "# $1 = time (seconds since 01-JAN-2000, 00:00 UTC)\n"
49 "# $2 = satellite longitude [deg]\n"
50 "# $3 = satellite latitude [deg]\n"
51 "# $4 = footprint longitude [deg]\n"
52 "# $5 = footprint latitude [deg]\n");
55 for (
int i = 2; i < argc; i++) {
58 printf(
"Read AIRS Level-1B data file: %s\n", argv[i]);
59 airs_rad_rdr(argv[i], &airs_rad_gran);
62 for (
int track = 0; track < AIRS_RAD_GEOTRACK; track++) {
64 for (
int xtrack = 0; xtrack < AIRS_RAD_GEOXTRACK; xtrack++)
65 fprintf(out,
"%.2f %g %g %g %g\n",
66 airs_rad_gran.Time[track][xtrack] - 220838400,
67 airs_rad_gran.sat_lon[track],
68 airs_rad_gran.sat_lat[track],
69 airs_rad_gran.Longitude[track][xtrack],
70 airs_rad_gran.Latitude[track][xtrack]);
#define ERRMSG(...)
Print error message and quit program.
AIRS Code Collection library declarations.
int main(int argc, char *argv[])