00001 #ident "$Header: /home/cvsuser/cvsroot/JSOC/proj/lev0/apps/test_get_image_location.c,v 1.2 2011/03/15 21:09:30 carl Exp $"
00002
00003
00004
00005
00006
00007
00008
00009
00010 #include <stdio.h>
00011 #include <stdlib.h>
00012 #include <string.h>
00013 #include <time.h>
00014 #include <sys/stat.h>
00015 #include <unistd.h>
00016 #include <stdarg.h>
00017 #include "drms.h"
00018 #include "drms_names.h"
00019 #include "jsoc_main.h"
00020 #include <printk.h>
00021 #include "get_image_location.c"
00022
00023
00024 ModuleArgs_t module_args[] =
00025 {
00026 {ARG_STRING, "src", "Not Specified", "day file source"},
00027 {ARG_STRING, "in", "Not Specified", "full path to day file"},
00028 {ARG_STRING, "out", "Not Specified", "Series name"},
00029 {ARG_FLAG, "p", "0", "print values of keywords to standard out"},
00030 {ARG_END}
00031 };
00032 ModuleArgs_t *ggModArgs=module_args;
00033 char* module_name = "test_get_image_location";
00034
00035
00036
00037
00038
00039
00040
00041 int DoIt(void)
00042 {
00043
00044 int i=1;
00045 int ncnt=1;
00046 int rstatus;
00047 Image_Location *p_imageloc;
00048 Image_Location imageloc[10];
00049
00050 printf("test_get_image_location() ran!!\n");
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061 for(i=0; i < ncnt; i++)
00062 {
00063
00064
00065 imageloc[i].tobs =1049918434;
00066 imageloc[i].camera = 1;
00067 imageloc[i].wavelength=0;
00068 strcpy(imageloc[i].telescope,"SDO/HMI");
00069 }
00070 p_imageloc = imageloc;
00071 rstatus = get_image_location(drms_env, ncnt, &p_imageloc);
00072
00073 printf("rstatus is %d\n", rstatus);
00074 printf("x is %f\n", p_imageloc->x);
00075 printf("y is %f\n", p_imageloc->y);
00076 printf("instrot is %f\n", p_imageloc->instrot);
00077 printf("imscale is %f\n", p_imageloc->imscale);
00078 printf("yinrtb is %f\n", p_imageloc->yinrtb);
00079 printf("zinrtb is %f\n", p_imageloc->zinrtb);
00080
00081 return(0);
00082
00083 }
00084
00085