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

20031113: 20031112: problem with dclsfc with synoptic bulletin



David,

The default station table for dclsfc is: lsfstns.tbl which
I have linked to lsystns.upc.

Are you using the -s option? I'd have to see your invocation again with
the data file. The one you sent yesterday was all "nil".

Steve Chiswell


>From: "David Bernhardt" <address@hidden>
>Organization: UCAR/Unidata
>Keywords: 200311131711.hADHB2Ob005030

>Thanks for the response, Steve. I did not get the same error when I 
>placed your code at the
>head and tail of the file. However, I get another problem. The log file 
>says:
>[DCLSFC 7] Bulletin: 999 SMCN35 CWAO  131200 RRH
>[SF -10]        Station xxxxx is not in file.
>[DC 2]            read 0/102193 byes strt 207 newstrt 207
>[DC -9]          End of input data file
>[DC 5]             Normal termination.
>
>I have tried this with a couple of different files that do have the 
>offending station in the
>appropriate table file ($GEMTBL/tables/stsns/systns.tbl).
>
>More ideas would be appreciated.
>
>Dave
>
>Unidata Support wrote:
>
>>David,
>>
>>The metar decoder is built to allow both FOS style (^A^M^M\n.....^M^M\n^C) 
>>bulletin separators, and AFOS style (ZCZC.....NNNN) separators
>>as found in the $GEMPAK/source/bridge/mt/mtdcod.f routine, where
>>the call to DC_GBUL will determine which of the styles the bulletin is,
>>and call either DC_GHDR for FOS or DC_GPIL for AFOS.
>>
>>The dclsfc decoder routine $GEMPAK/source/bridge/ls/lsdcod.f only has a call 
> to
>>the FOS style header routine, so is not built to expect AFOS style ZCZC....NN
> NN 
>>delimeters. You could add the check on iftype returned from DC_GHDR through.
>>
>>On a FOS style header, the AFOS style PIL identifier you have is not present.
>>Rather, you should have metar bulletins that look like either:
>>
>>^A^M^M
>>sequence number (eg 999, etc)
>>WMO header (eg SAUS80 KWBC 121800 etc)
>>....
>>
>>^M^M
>>^C
>>
>>For an AFOS Metar,
>>ZCZC NNNMTRCCC
>>SAUS80 KWBC 122100
>>.....
>>NNNN
>>
>>
>>Since dclsfc is expecting FOS bulletins only, your bulletin should look like:
>>^A^M^M
>>999
>>SMCN23 CWAO 120900
>>AAXX 12094
>>71300 NIL=
>>71301 NIL=
>>71303 NIL=
>>71304 NIL=
>>....
>>^M^M
>>^C
>>
>>
>>I created a header and trailer for your bulletin with:
>>echo 'AMML' | tr 'AMLC' '\001\015\012\003' >! header
>>echo 'MMLC' | tr 'AMLC' '\001\015\012\003' >! trailer
>>and then edited your WAO....file placing the header and seq. number at
>>the top and the trailer at the end and eliminated the AFOS 9 character pil.
>>At that point, it will decode.
>>
>>Steve Chiswell
>>
>>
>>
>>
>>
>>  
>>
>>
>
>