SURFEX  V8_0
Surfex V8_0 release
 All Classes Files Functions Variables
read_nam_prep_surfn.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 read_nam_prep_surf_n(HPROGRAM)
7 ! #######################################################
8 !
9 !---------------------------------------
10 !
11 USE modd_surf_par, ONLY : xundef, nundef
13 !
15 USE modi_get_luout
16 USE modi_open_namelist
17 USE modi_close_namelist
18 USE mode_pos_surf
19 !
20 !
21 USE yomhook ,ONLY : lhook, dr_hook
22 USE parkind1 ,ONLY : jprb
23 !
24 IMPLICIT NONE
25 !
26  CHARACTER(LEN=6), INTENT(IN) :: hprogram ! program calling surf. schemes
27 !
28 INTEGER :: ilunam ! logical unit of namelist file
29 INTEGER :: iluout
30 LOGICAL :: gfound ! Return code when searching namelist
31 REAL(KIND=JPRB) :: zhook_handle
32 !
33 !---------------------------------------
34 !
35 IF (lhook) CALL dr_hook('READ_NAM_PREP_SURF_N',0,zhook_handle)
36 !
37 nhalo_prep = 2
38 !
39 nyear=nundef
40 nmonth=nundef
41 nday=nundef
42 xtime=xundef
43  cfile = ' '
44  cfiletype = ' '
45  cfilepgd = ' '
46  cfilepgdtype = ' '
47 !
48  CALL get_luout(hprogram,iluout)
49 !
50 !
51  CALL open_namelist(hprogram,ilunam)
52  CALL posnam(ilunam,'NAM_PREP_SURF_ATM',gfound,iluout)
53 IF (gfound) READ(unit=ilunam,nml=nam_prep_surf_atm)
54  CALL close_namelist(hprogram,ilunam)
55 !
56  CALL test_nam_var_surf(iluout,'CFILETYPE', cfiletype, ' ','GRIB ','MESONH','ASCII ','LFI ','FA ')
57  CALL test_nam_var_surf(iluout,'CFILEPGDTYPE', cfilepgdtype, ' ','GRIB ','MESONH','ASCII ','LFI ','FA ')
58 IF (lhook) CALL dr_hook('READ_NAM_PREP_SURF_N',1,zhook_handle)
59 !
60 END SUBROUTINE read_nam_prep_surf_n
subroutine close_namelist(HPROGRAM, KLUNAM)
subroutine posnam(KULNAM, HDNAML, OFOUND, KLUOUT)
subroutine get_luout(HPROGRAM, KLUOUT)
Definition: get_luout.F90:6
subroutine open_namelist(HPROGRAM, KLUNAM, HFILE)
subroutine read_nam_prep_surf_n(HPROGRAM)