SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
prep_buffer_grid.F90
Go to the documentation of this file.
1 !SFX_LIC Copyright 1994-2014 CNRS, Meteo-France and Universite Paul Sabatier
2 !SFX_LIC This is part of the SURFEX software governed by the CeCILL-C licence
3 !SFX_LIC version 1. See LICENSE, CeCILL-C_V1-en.txt and CeCILL-C_V1-fr.txt
4 !SFX_LIC for details. version 1.
5 ! #########
6  SUBROUTINE prep_buffer_grid(KLUOUT,HINMODEL,TPTIME_BUF)
7 ! ##########################################################################
8 !
9 !!**** *PREP_BUFFER_GRID* - reads BUFFER infos
10 !!
11 !! PURPOSE
12 !! -------
13 !!
14 !!** METHOD
15 !! ------
16 !!
17 !! EXTERNAL
18 !! --------
19 !!
20 !! IMPLICIT ARGUMENTS
21 !! ------------------
22 !!
23 !!
24 !! REFERENCE
25 !! ---------
26 !!
27 !!
28 !! AUTHOR
29 !! ------
30 !!
31 !! S.Malardel
32 !!
33 !! MODIFICATIONS
34 !! -------------
35 !! Original 03/2005
36 !! Y. Seity 08/2006 : for NEC Prepsurfex configuration (pbs LEN /=6)
37 !-------------------------------------------------------------------------------
38 !
39 !* 0. DECLARATIONS
40 ! ------------
41 !
43 !
45 !
46 USE modd_grid_buffer, ONLY : nni
47 !
48 !
49 USE yomhook ,ONLY : lhook, dr_hook
50 USE parkind1 ,ONLY : jprb
51 !
52 USE modi_abor1_sfx
53 !
54 IMPLICIT NONE
55 !
56 !* 0.1. Declaration of arguments
57 ! ------------------------
58 !
59 INTEGER, INTENT(IN) :: kluout ! logical unit of output listing
60  CHARACTER(LEN=6), INTENT(OUT) :: hinmodel ! originating model
61 TYPE (date_time) :: tptime_buf ! current date and time
62 
63 !
64 !* 0.2 Declaration of local variables
65 ! ------------------------------
66 INTEGER :: iret ! return code
67 REAL(KIND=JPRB) :: zhook_handle
68 !
69 !---------------------------------------------------------------------------------------
70 !
71 IF (lhook) CALL dr_hook('PREP_BUFFER_GRID',0,zhook_handle)
72 WRITE (kluout,'(A)') ' -- Buffer reader started'
73 !
74 !
75 !---------------------------------------------------------------------------------------
76 !* 1. Read HINMODEL
77 !---------------------------------------------------------------------------------------
78 !
79  CALL read_buffer('INMODE',hinmodel,iret)
80 
81  IF (hinmodel =='ALADIN' ) THEN
82  WRITE (kluout,'(A)') ' | Grib file from French Weather Service - Aladin model'
83  ELSE
84  CALL abor1_sfx('PREP_BUFFER_GRID: UNSUPPORTED GRIB FILE FORMAT')
85  END IF
86 !
87 !---------------------------------------------------------------------------------------
88 !* 3. Number of points
89 !---------------------------------------------------------------------------------------
90 !
91  CALL read_buffer('NNI ',nni,iret)
92 WRITE (kluout,*)'apres READ BUFFER NNI=',nni
93 !---------------------------------------------------------------------------------------
94 !* 2.4 Read date
95 !---------------------------------------------------------------------------------------
96 !
97 WRITE (kluout,'(A)') ' | Reading date'
98 !
99  CALL read_buffer('YEAR ',tptime_buf%TDATE%YEAR,iret )
100  CALL read_buffer('MONTH ',tptime_buf%TDATE%MONTH,iret )
101  CALL read_buffer('DAY ',tptime_buf%TDATE%DAY,iret )
102  CALL read_buffer('TIME ', tptime_buf%TIME,iret)
103 IF (lhook) CALL dr_hook('PREP_BUFFER_GRID',1,zhook_handle)
104 !
105 END SUBROUTINE prep_buffer_grid
subroutine prep_buffer_grid(KLUOUT, HINMODEL, TPTIME_BUF)
subroutine abor1_sfx(YTEXT)
Definition: abor1_sfx.F90:6