NCEPLIBS-bufr  11.5.0
 All Data Structures Files Functions Variables Pages
mvb.f
Go to the documentation of this file.
1 C> @file
2 C> @author WOOLLEN @date 1994-01-06
3 
4 C> THIS SUBROUTINE COPIES A SPECIFIED NUMBER OF BYTES FROM
5 C> ONE PACKED BINARY ARRAY TO ANOTHER.
6 C>
7 C> PROGRAM HISTORY LOG:
8 C> 1994-01-06 J. WOOLLEN -- ORIGINAL AUTHOR
9 C> 1998-07-08 J. WOOLLEN -- REPLACED CALL TO CRAY LIBRARY ROUTINE
10 C> "ABORT" WITH CALL TO NEW INTERNAL BUFRLIB
11 C> ROUTINE "BORT"
12 C> 1998-10-27 J. WOOLLEN -- MODIFIED TO CORRECT PROBLEMS CAUSED BY IN-
13 C> LINING CODE WITH FPP DIRECTIVES
14 C> 2002-05-14 J. WOOLLEN -- REMOVED OLD CRAY COMPILER DIRECTIVES
15 C> 2003-11-04 S. BENDER -- ADDED REMARKS/BUFRLIB ROUTINE
16 C> INTERDEPENDENCIES
17 C> 2003-11-04 D. KEYSER -- UNIFIED/PORTABLE FOR WRF; ADDED
18 C> DOCUMENTATION (INCLUDING HISTORY); OUTPUTS
19 C> MORE COMPLETE DIAGNOSTIC INFO WHEN ROUTINE
20 C> TERMINATES ABNORMALLY
21 C> 2005-11-29 J. ATOR -- MAXIMUM NUMBER OF BYTES TO COPY INCREASED
22 C> FROM 24000 TO MXIMB
23 C> 2014-10-22 J. ATOR -- MERGE TWO DO LOOPS INTO ONE, AND REMOVE
24 C> MXIMB PARAMETER AND DIMENSIONING OF NVAL
25 C>
26 C> USAGE: CALL MVB (IB1, NB1, IB2, NB2, NBM)
27 C> INPUT ARGUMENT LIST:
28 C> IB1 - INTEGER: *-WORD PACKED INPUT BINARY ARRAY
29 C> NB1 - INTEGER: POINTER TO FIRST BYTE IN IB1 TO COPY FROM
30 C> NB2 - INTEGER: POINTER TO FIRST BYTE IN IB2 TO COPY TO
31 C> NBM - INTEGER: NUMBER OF BYTES TO COPY
32 C>
33 C> OUTPUT ARGUMENT LIST:
34 C> IB2 - INTEGER: *-WORD PACKED OUTPUT BINARY ARRAY
35 C>
36 C> REMARKS:
37 C> THIS ROUTINE CALLS: PKB UPB
38 C> THIS ROUTINE IS CALLED BY: ATRCPT CNVED4 CPYUPD MSGUPD
39 C> STNDRD
40 C> Normally not called by any application
41 C> programs.
42 C>
43  SUBROUTINE mvb(IB1,NB1,IB2,NB2,NBM)
44 
45  CHARACTER*128 bort_str
46  dimension ib1(*),ib2(*)
47 
48 C-----------------------------------------------------------------------
49 C-----------------------------------------------------------------------
50 
51  jb1 = 8*(nb1-1)
52  jb2 = 8*(nb2-1)
53 
54  DO n=1,nbm
55  CALL upb(nval,8,ib1,jb1)
56  CALL pkb(nval,8,ib2,jb2)
57  ENDDO
58 
59 C EXITS
60 C -----
61 
62  RETURN
63  END
subroutine mvb(IB1, NB1, IB2, NB2, NBM)
THIS SUBROUTINE COPIES A SPECIFIED NUMBER OF BYTES FROM ONE PACKED BINARY ARRAY TO ANOTHER...
Definition: mvb.f:43
subroutine upb(NVAL, NBITS, IBAY, IBIT)
THIS SUBROUTINE UNPACKS AND RETURNS A BINARY INTEGER CONTAINED WITHIN NBITS BITS OF IBAY...
Definition: upb.f:49
subroutine pkb(NVAL, NBITS, IBAY, IBIT)
This subroutine encodes an integer value within a specified number of bits of an integer array...
Definition: pkb.f:40