Programming Examples GPIB Operation
8-140 PN: 10585-00001 Rev. P ML2437A/38A OM/PM
table_entries = bin_data.ival;
length -= 2;
/* The cal factor table output is in frequency, dB order for */
/* the whole table. The frequencies format is */
/* 32768.0e-6LONG and the dBs are held in 1024INT format.*/
/**/
count = 0;
loop = 0;
while (count < length)
{
/* Frequency conversion */
bin_data.cval[0] = *cptr++;
bin_data.cval[1] = *cptr++;
bin_data.cval[2] = *cptr++;
bin_data.cval[3] = *cptr++;
real_data1[loop] = ((float)(bin_data.lval))/32768e-6;
/* dB conversion */
bin_data.cval[0] = *cptr++;
bin_data.cval[1] = *cptr++;
bin_data.cval[2] = 0;
bin_data.cval[3] = 0;
real_data2[loop++] = ((float)(bin_data.ival))/1024.0;
count += 6;
}
real1_entries = loop;
real2_entries = loop;
}