NCEPLIBS-g2 4.0.0
Loading...
Searching...
No Matches
tocgrib2.F90 File Reference

Create new GRIB2 file with fields from an existing GRIB2 file, with a TOC Flag Field separator block and WMO header. More...

Go to the source code of this file.

Functions/Subroutines

program tocgrib2
 Program reads selected GRIB2 fields from a file, adds a TOC Flag Field separator block and WMO Header in front of each GRIB2 field, and writes them out to a new file.
 

Detailed Description

Create new GRIB2 file with fields from an existing GRIB2 file, with a TOC Flag Field separator block and WMO header.

Author
Stephen Gilbert
Date
2004-05-17

Definition in file tocgrib2.F90.

Function/Subroutine Documentation

◆ tocgrib2()

program tocgrib2

Program reads selected GRIB2 fields from a file, adds a TOC Flag Field separator block and WMO Header in front of each GRIB2 field, and writes them out to a new file.

The output file is in the format required for TOC's FTP Input Service, which can be used to disseminate the GRIB2 bulletins. See [File Transfer Input Service Guide - Input examples and how to FTP files to the Gateway] (https://www.weather.gov/tg/ftpingest).

Note
The "EXTRACT" variable in the namelist allows users to choose whether they want the entire GRIB2 message containing the requested field (extract=.false.), OR a GRIB2 message containing only the requested field (extract=.true.). Both options return the same message if the requested field is the only field in the GRIB2 message.

Input Files

  • 5 namelist of grib fields and associated wmo headers.
  • 11 input grib2 file.
  • 31 corresponding input grib2 index file.

Output Files (Including Scratch Files)

  • 6 standard fortran print file
  • 51 output grib bulletin file in toc format
Returns
  • 0 - Successful run
  • 10 - Error opening input GRIB2 data file
  • 20 - Error opening output GRIB transmission file
  • 19 - Error reading control card file - all bulletins missing
  • 30 - Some bulletins are missing
Author
Stephen Gilbert
Date
2004-05-17
Author
Alex Richert, Edward Hartnett

Definition at line 39 of file tocgrib2.F90.

References getgb2p2(), makwmo(), and mkfldsep().