116 COMMON /usrstr/ nnod,ncon,nods(20),nodc(10),vals(10),kons(10)
120 CHARACTER*128 BORT_STR,ERRSTR
121 CHARACTER*10 TGS(100)
122 CHARACTER*8 SUBSET,CVAL
123 equivalence(cval,rval)
125 real*8 tab(i1,i2),rval,
ups
130 mps(node) = 2_8**(
ibt(node))-1
135 IF(
msgp(0).EQ.0)
GOTO 100
146 CALL parstr(str,tgs,maxtg,ntg,
' ',.true.)
151 IF(tgs(i).EQ.
'IREC') irec = i
152 IF(tgs(i).EQ.
'ISUB') isub = i
153 IF(tgs(i).EQ.
'ITBL') itbl = i
162 CALL rdmemm(imsg,subset,jdate,mret)
163 IF(mret.LT.0)
GOTO 900
166 IF(irec.GT.0) nods(irec) = 0
167 IF(isub.GT.0) nods(isub) = 0
168 IF(itbl.GT.0) nods(itbl) = 0
173 DO WHILE (nsub(lun).LT.msub(lun))
174 IF(iret+1.GT.i2)
GOTO 99
178 nods(i) = abs(nods(i))
182 mbit =
mbyt(lun)*8+16
18620
IF(n+1.LE.nval(lun))
THEN
191 IF(
itp(node).EQ.1)
THEN
192 CALL upb8(ival,nbit,mbit,
mbay(1,lun))
193 nbmp=ival;
CALL usrtpl(lun,n,nbmp)
196 IF(nods(i).EQ.node)
THEN
197 IF(
itp(node).EQ.1)
THEN
198 CALL upb8(ival,nbit,mbit,
mbay(1,lun))
200 ELSEIF(
itp(node).EQ.2)
THEN
201 CALL upb8(ival,nbit,mbit,
mbay(1,lun))
202 IF(ival.LT.mps(node)) tab(i,iret) =
ups(ival,node)
203 ELSEIF(
itp(node).EQ.3)
THEN
206 CALL upc(cval,nbit/8,
mbay(1,lun),kbit,.true.)
214 IF(nods(i).GT.0)
GOTO 20
222 CALL upb(nbyt,16,
mbay(1,lun),ibit)
224 nsub(lun) = nsub(lun) + 1
225 IF(irec.GT.0) tab(irec,iret) = nmsg(lun)
226 IF(isub.GT.0) tab(isub,iret) = nsub(lun)
227 IF(itbl.GT.0) tab(itbl,iret) =
ldxts
23799
CALL rdmemm(0,subset,jdate,mret)
240 CALL rdmemm(imsg,subset,jdate,mret)
241 IF(mret.LT.0)
GOTO 900
245 CALL errwrt(
'+++++++++++++++++++++WARNING+++++++++++++++++++++++')
246 WRITE ( unit=errstr, fmt=
'(A,A,I8,A,A)' )
247 .
'BUFRLIB: UFBTAM - THE NO. OF DATA SUBSETS IN MEMORY ',
248 . .GT.
'IS LIMIT OF ', i2,
' IN THE 3RD ARG. (INPUT) - ',
251 WRITE ( unit=errstr, fmt=
'(A,I8,A,I8,A)' )
252 .
'>>>UFBTAM STORED ', iret,
' REPORTS OUT OF ', nrep,
'<<<'
254 CALL errwrt(
'+++++++++++++++++++++WARNING+++++++++++++++++++++++')
261200
CALL rdmemm(0,subset,jdate,mret)
267900
WRITE(bort_str,
'("BUFRLIB: UFBTAM - HIT END-OF-FILE READING '//
268 .
'MESSAGE NUMBER",I5," IN INTERNAL MEMORY")') imsg
subroutine bort(STR)
This subroutine calls subroutine errwrt() to log an error message, then calls subroutine bort_exit() ...
subroutine errwrt(STR)
This subroutine allows the user to specify a custom location for the logging of error and diagnostic ...
This module contains array and variable declarations used to store BUFR messages internally for multi...
integer, dimension(:), allocatable mbyt
Length (in bytes) of current BUFR message for each internal I/O stream.
integer, dimension(:,:), allocatable mbay
Current BUFR message for each internal I/O stream.
This module contains array and variable declarations used to store the contents of one or more BUFR f...
integer munit
Fortran logical unit number for use in accessing contents of BUFR files within internal memory.
integer ldxts
Number of DX BUFR table that is currently in scope, depending on which BUFR message within msgs is cu...
integer, dimension(:), allocatable msgp
Pointers to the beginning of each message within msgs (up to a maximum of MAXMSG, and where array ele...
This module contains array and variable declarations used to store the internal jump/link table.
integer, dimension(:), allocatable itp
Integer type values corresponding to typ:
integer, dimension(:), allocatable ibt
Bit widths corresponding to tag and typ:
This module declares and initializes the BMISS variable.
real *8, public bmiss
Current placeholder value to represent "missing" data when reading from or writing to BUFR files; thi...
function nmsub(LUNIT)
This function returns the total number of data subsets available within the BUFR message that was mos...
subroutine parstr(STR, TAGS, MTAG, NTAG, SEP, LIMIT80)
THIS SUBROUTINE PARSES A STRING CONTAINING ONE OR MORE SUBSTRINGS INTO AN ARRAY OF SUBSTRINGS.
subroutine rdmemm(IMSG, SUBSET, JDATE, IRET)
This subroutine reads a specified BUFR message from internal arrays in memory, so that it is now in s...
subroutine status(LUNIT, LUN, IL, IM)
This subroutine checks whether a specified Fortran logical unit number is currently connected to the ...
subroutine string(STR, LUN, I1, IO)
THIS SUBROUTINE CHECKS TO SEE IF A USER-SPECIFIED CHARACTER STRING IS IN THE STRING CACHE (ARRAYS IN ...
subroutine ufbtam(TAB, I1, I2, IRET, STR)
THIS SUBROUTINE READS SPECIFIED VALUES INTO INTERNAL ARRAYS FROM ALL DATA SUBSETS IN BUFR MESSAGES ST...
subroutine upb8(nval, nbits, ibit, ibay)
THIS SUBROUTINE UNPACKS AND RETURNS AN 8-BYTE INTEGER CONTAINED WITHIN NBITS BITS OF IBAY,...
subroutine upb(NVAL, NBITS, IBAY, IBIT)
THIS SUBROUTINE UNPACKS AND RETURNS A BINARY INTEGER CONTAINED WITHIN NBITS BITS OF IBAY,...
subroutine upc(CHR, NCHR, IBAY, IBIT, CNVNULL)
THIS SUBROUTINE UNPACKS AND RETURNS A CHARACTER STRING OF LENGTH NCHR CONTAINED WITHIN NCHR BYTES OF ...
real *8 function ups(IVAL, NODE)
THIS FUNCTION UNPACKS A REAL*8 USER VALUE FROM A PACKED BUFR INTEGER BY APPLYING THE PROPER SCALE AND...
subroutine usrtpl(LUN, INVN, NBMP)
THIS SUBROUTINE STORES THE SUBSET TEMPLATE INTO INTERNAL SUBSET ARRAYS IN MODULE USRINT FOR CASES OF ...