NCEPLIBS-w3emc
2.12.0
Loading...
Searching...
No Matches
makwmo.f
Go to the documentation of this file.
1
C> @file
2
C> @brief FORMS THE WMO HEADER FOR A GIVEN BULLETIN.
3
C> @author Farley @date 1984-07-06
4
5
C> Program history log:
6
C> - Farley 1984-07-06
7
C> - Ralph Jones 1994-10-10 Changes for cray.
8
C> - Ralph Jones 1995-10-18 Add parameter KWBX to call.
9
C> - Stephen Gilbert 1998-06-16 Changed argument list to pass in day and hour
10
C> instead of the old O.N. 84 date word.
11
C> - Stephen Gilbert 2003-03-28 Removed equivalences.
12
C>
13
C> @param[in] BULHED TTAAII bulletin header. FT10
14
C> @param[in] IDAY Day of Month.
15
C> @param[in] IHOUR Hour of Day.
16
C> @param[in] KWBX 4 characters (KWBC to KWBQ)
17
C> @param[out] HEADER Complete WMO header in ASCII.
18
C>
19
C> @author Farley @date 1984-07-06
20
SUBROUTINE
makwmo
(BULHED,IDAY,IHOUR,KWBX,HEADER)
21
C
22
CHARACTER * 6
BULHED
23
CHARACTER * 1
HEADER (*)
24
CHARACTER * 1
WMOHDR (21)
25
CHARACTER * 4
KWBX
26
CHARACTER * 2
CTEMP
27
C
28
C--------------------------------------------------------------------
29
C
30
C$ 1. CREATE WMO HEADER.
31
C
32
C$ 1.1 CONVERT BULHED FROM EBCDIC TO ASCII.
33
C
34
C WRITE (6,FMT='('' MADE IT TO MAKWMO'')')
35
C
36
DO
i = 1,6
37
wmohdr(i) = bulhed(i:i)
38
END DO
39
wmohdr(7)=char(32)
! ASCII BLANK
40
C
41
C MOVE KWBX INTO WMO HEADER
42
C
43
DO
i = 1,4
44
wmohdr(i+7) = kwbx(i:i)
45
END DO
46
wmohdr(12)=char(32)
! ASCII BLANK
47
C
48
C$ 1.2 PICK OFF THE DAY OF MONTH (YY)
49
C$ AND CONVERT TO ASCII.
50
C
51
write
(ctemp,fmt=
'(I2.2)'
) iday
52
wmohdr(13)=ctemp(1:1)
53
wmohdr(14)=ctemp(2:2)
54
C
55
C$ 1.3 PICK OFF THE HOUR(GG) AND CONVERT TO ASCII.
56
C
57
write
(ctemp,fmt=
'(I2.2)'
) ihour
58
wmohdr(15)=ctemp(1:1)
59
wmohdr(16)=ctemp(2:2)
60
C
61
C 1.4 FIL IN REST OF HEADER
62
C
63
wmohdr(17)=char(48)
! ASCII "0"
64
wmohdr(18)=char(48)
! ASCII "0"
65
wmohdr(19)=char(13)
! ASCII CR = '\r'
66
wmohdr(20)=char(13)
! ASCII CR = '\r'
67
wmohdr(21)=char(10)
! ASCII LF = '\n'
68
C
69
C--------------------------------------------------------------------
70
C
71
C$ 2. MOVE WMOHDR TO OUTPUT FIELD.
72
C
73
DO
200 i = 1,21
74
header(i) = wmohdr(i)
75
200
CONTINUE
76
C
77
RETURN
78
END
makwmo
subroutine makwmo(bulhed, iday, ihour, kwbx, header)
Program history log:
Definition
makwmo.f:21
src
makwmo.f
Generated by
1.9.8