[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[LDM #KWB-817118]: Intepretation of NLDN binary data.



Hi Takeshi,

re:
> I need help to interpret NLDN binary data.
> 
> We are receiving NLDN data feed at GI/UAF and storing it as the
> original binary format. I am trying to convert these binary to ascii
> format.
> 
> I referred to your website
> (http://www.unidata.ucar.edu/data/lightning.html) and LDM-MCIDAS
> decorder source code. What I've found it works better is;
> 
> char[4]  NLDN      'NLDN' marks the start of record
> int[4]   tsec      time in seconds since 1970
> int[4]   nsec      nanoseconds since tsec (seems to be thousandths)
> int[4]   lat       latitude [deg] * 1000
> int[4]   lon       longitude [deg] * 1000
> short[2] fill      padding
> short[2] sgnl      signal strength * 10 [150 NLDN measures ~= 30 kAmps]
> short[2] fill      padding
> char[1]  mult      multiplicity [#strokes per flash]
> char[1]  fill      padding
> char[1]  semimaj   semi-major axis
> char[1]  eccent    eccentricity
> char[1]  angle     ellipse angle
> char[1]  chisqr    chi-square
> 
> However, reading the binary with this description gives me "nsec" like
> 100000000, 300000000..., i.e. single leading digit followed by eight
> zeros.

> The NLDN data is supposed to have millisecond resolution. I am
> confused how to interpret it.

The original documentation we received (many years ago) on the NLDN data
said that 'tsec' was nanoseconds (1.E-9 s, as per list above).  As you say, the
values seem too large for there to be millisecond resolution unless
one views 100 ms, 300 ms as 'millisecond resolution'.

> Could you tell me how to interpret the NLDN binary file?

I have always interpreted the numbers as nanoseconds so that the numbers you
report indicate tenths of a second resolution, not milliseconds as the original
documentation we were provided indicates.  We were never concerned with this
since our decoding of the NLDN data into McIDAS and GEMPAK formats assigned
times with 1 second resolution (the reason why the ldm-mcidas source code,
nldninput.c, does nothing with time_tsec).

Cheers,

Tom
****************************************************************************
Unidata User Support                                    UCAR Unidata Program
(303) 497-8642                                                 P.O. Box 3000
address@hidden                                   Boulder, CO 80307
----------------------------------------------------------------------------
Unidata HomePage                       http://www.unidata.ucar.edu
****************************************************************************


Ticket Details
===================
Ticket ID: KWB-817118
Department: Support ldm-mcidas
Priority: Normal
Status: Closed