@@ -50,7 +50,7 @@ unsigned[1] reservedSection3 = 0;
50
50
unsigned[2] numberOfSubsets : dump;
51
51
alias ls.numberOfSubsets=numberOfSubsets;
52
52
53
- if (section2Present && bufrHeaderCentre== 98 && section2Length== 52) {
53
+ if (section2Present && bufrHeaderCentre == 98 && section2Length == 52) {
54
54
if ( rdbType == 2 || rdbType == 3 || rdbType == 8 || rdbType == 12 || rdbType == 30 ) {
55
55
transient isSatelliteType=1;
56
56
} else {
@@ -69,10 +69,11 @@ if (section2Present && bufrHeaderCentre==98 && section2Length==52) {
69
69
meta localLatitude2 bits(keyMore,32,25,-9000000,100000) : dump,no_copy;
70
70
71
71
# This rule is taken from BUFRDC. See bufrdc_wmo/buukey.F
72
- # Also see ECC-686
73
- if (oldSubtype == 255 || numberOfSubsets>255 ||
74
- ( oldSubtype>=121 && oldSubtype <=130 ) ||
75
- oldSubtype==31) {
72
+ # See ECC-686
73
+ # and https://confluence.ecmwf.int/pages/viewpage.action?pageId=24316441
74
+ if (oldSubtype == 255 || numberOfSubsets > 255 ||
75
+ ( oldSubtype >= 121 && oldSubtype <= 130 ) ||
76
+ oldSubtype == 31) {
76
77
meta ls.localNumberOfObservations bits(keySat,0,16) : dump,long_type,no_copy;
77
78
meta ls.satelliteID bits(keySat,16,16) : dump,long_type,no_copy;
78
79
} else {
@@ -114,16 +115,16 @@ meta bufrdcExpandedDescriptors bufrdc_expanded_descriptors(expandedCodes) : no_c
114
115
#smart_table NAME (VALUES,FILE_NAME,MASTER_DIRECTORY,LOCAL_DIRECTORY,WIDTH_OF_CODE_IN_BITS,EXTRA_DIRECTORY,EXTRA_FILE_NAME);
115
116
#Note: The WIDTH_OF_CODE_IN_BITS has to be big enough so 2^width > the highest BUFR descriptor code
116
117
smart_table expandedOriginalCodes (expandedCodes,"element.table",tablesMasterDir,tablesLocalDir,18,rootTablesDir,"operators.table") :no_copy;
117
- meta expandedAbbreviations smart_table_column(expandedOriginalCodes,0,1) : string_type,no_copy;
118
- meta expandedTypes smart_table_column(expandedOriginalCodes,1,0) : string_type,no_copy;
119
- meta expandedNames smart_table_column(expandedOriginalCodes,2,0) : string_type,no_copy;
120
- meta expandedUnits smart_table_column(expandedOriginalCodes,3,0) : string_type,no_copy;
121
- meta expandedOriginalScales smart_table_column(expandedOriginalCodes,4,0) : long_type,no_copy;
122
- meta expandedOriginalReferences smart_table_column(expandedOriginalCodes,5,0) : long_type,no_copy;
123
- meta expandedOriginalWidths smart_table_column(expandedOriginalCodes,6,0) : long_type,no_copy;
124
- meta expandedCrex_units smart_table_column(expandedOriginalCodes,7,0) : long_type,no_copy;
125
- meta expandedCrex_scales smart_table_column(expandedOriginalCodes,8,0) : long_type,no_copy;
126
- meta expandedCrex_widths smart_table_column(expandedOriginalCodes,9,0) : long_type,no_copy;
118
+ meta expandedAbbreviations smart_table_column(expandedOriginalCodes,0,1) : string_type,no_copy;
119
+ meta expandedTypes smart_table_column(expandedOriginalCodes,1,0) : string_type,no_copy;
120
+ meta expandedNames smart_table_column(expandedOriginalCodes,2,0) : string_type,no_copy;
121
+ meta expandedUnits smart_table_column(expandedOriginalCodes,3,0) : string_type,no_copy;
122
+ meta expandedOriginalScales smart_table_column(expandedOriginalCodes,4,0) : long_type,no_copy;
123
+ meta expandedOriginalReferences smart_table_column(expandedOriginalCodes,5,0) : long_type,no_copy;
124
+ meta expandedOriginalWidths smart_table_column(expandedOriginalCodes,6,0) : long_type,no_copy;
125
+ meta expandedCrex_units smart_table_column(expandedOriginalCodes,7,0) : long_type,no_copy;
126
+ meta expandedCrex_scales smart_table_column(expandedOriginalCodes,8,0) : long_type,no_copy;
127
+ meta expandedCrex_widths smart_table_column(expandedOriginalCodes,9,0) : long_type,no_copy;
127
128
128
129
position endDescriptors;
129
130
section_padding section3Padding;
0 commit comments