Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
bufr.pm:dump_flag_tables.pl [2010-05-16 12:37:55] pals |
bufr.pm:dump_flag_tables.pl [2022-05-31 09:29:31] (current) |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | < | + | < |
# | # | ||
- | # Dump all flag tables in table file | + | # Dump all flag tables in table file. |
+ | # Flag tables not found is printed to STDERR. | ||
# Author: P.Sannes, met.no 2010-05-12 | # Author: P.Sannes, met.no 2010-05-12 | ||
Line 9: | Line 10: | ||
my $table_path = '/ | my $table_path = '/ | ||
- | my $table = 'B0000000000098013001'; | + | my $Btable |
+ | my $Ctable = ' | ||
Geo:: | Geo:: | ||
Line 15: | Line 17: | ||
my $bufr = Geo:: | my $bufr = Geo:: | ||
- | $bufr-> | + | $bufr-> |
- | $bufr-> | + | $bufr-> |
- | for my $i (1..50000) { | + | for my $i (1..48000) { |
my $desc = sprintf " | my $desc = sprintf " | ||
my ($name, $unit) = ($bufr-> | my ($name, $unit) = ($bufr-> | ||
- | next unless defined $unit && $unit =~ /^FLAG TABLE/; | + | next unless defined $unit && $unit =~ /^FLAG( )?TABLE/; |
- | print "$desc $name\n"; | + | |
- | print $bufr-> | + | if ($dump) { |
+ | | ||
+ | print $dump; | ||
+ | } elsif ($desc%1000 < 192) { | ||
+ | # Don't care about local tables missing | ||
+ | print STDERR "Flag table $desc is missing in $Ctable\n"; | ||
+ | } | ||
} | } | ||
</ | </ |