Go to the documentation of this file.
108 char *routine =
"init_L1A_HDF_vdatas";
113 uint16 eng_field_order[VSFIELDMAX];
122 if ((L1A_file ==
NULL) || (eng_data ==
NULL)) {
141 strcpy(eng_field_names[
i], eng_data[current_index].field[
i].field_name);
142 switch (eng_data[current_index].field[
i].
type) {
143 case DFNT_INT8 :
strcpy(eng_data_types[
i], I8);
break;
144 case DFNT_UINT8 :
strcpy(eng_data_types[
i], UI8);
break;
146 case DFNT_UINT16 :
strcpy(eng_data_types[
i], UI16);
break;
148 case DFNT_UINT32 :
strcpy(eng_data_types[
i], UI32);
break;
149 default : sprintf(
msg,
"\nVdata Name: %s Vdata Field: %s Vdata type: %d",
150 eng_data[current_index].vdata_name,
151 eng_data[current_index].field[
i].field_name,
152 eng_data[current_index].field[
i].
type);
156 eng_field_order[
i] = eng_data[current_index].
field[
i].
order;
166 switch(eng_data[current_index].field[
j].
type)
170 eng_data[current_index].field[
j].union_value[
k].i8type
176 eng_data[current_index].field[
j].union_value[
k].ui8type
182 eng_data[current_index].field[
j].union_value[
k].i16type
188 eng_data[current_index].field[
j].union_value[
k].ui16type
194 eng_data[current_index].field[
j].union_value[
k].i32type
200 eng_data[current_index].field[
j].union_value[
k].ui32type
211 returnStatus =
create_Vdata(eng_data[current_index].vdata_name,
214 eng_data[current_index].num_fields,
222 sprintf(
msg,
"Vdata Name: %s", eng_data[current_index].vdata_name);
234 memset(eng_field_order, 0,
sizeof(eng_field_order));
235 eng_field_order[0] = 650;
236 strcpy(Vdata_name, M01DISCARDED_PACKETS);
237 strcpy(eng_field_names[0], M01DISCARDED_PKTS_FIELD);
238 strcpy(eng_data_types[0], I8);
250 "The Discarded Packets Vdata could not be created in the file");
254 return (returnStatus);
EN_FIELD_TYPE_t field[EN_MAX_FIELDS_PER_VDATA]
PGSt_SMF_status init_L1A_HDF_vdatas(EN_VDATA_TYPE_t *eng_data, MODFILE *L1A_file)
HDF4 data type of the output SDS Default is DFNT_FLOAT32 Common types used DFNT_INT32
#define EN_SC_ANCILLARY_VDATA_END
#define MODIS_E_CREATE_VDATA
#define EN_SC_ANCILLARY_VDATA_START
void log_fmt_msg(PGSt_SMF_status code, const char *routine, const char *msg_fmt,...)
#define EN_MAX_VDATA_NAME_LENGTH
HDF4 data type of the output SDS Default is DFNT_FLOAT32 Common types used DFNT_INT16
PGSt_SMF_status create_Vdata(char *Vdata_name, char field_names[][VU_MAX_NAME_LENGTH], char data_types[][VU_MAX_DATA_TYPE_STRING_LENGTH], int16 num_fields, uint16 order[])
#define VU_MAX_NAME_LENGTH
#define MODIS_E_INVALID_VDATA_TYPE
#define VU_MAX_DATA_TYPE_STRING_LENGTH
#define MODIS_E_NULL_POINTER
How many dimensions is the output array Default is Not sure if anything above will work correctly strcpy(l2prod->title, "no title yet")