Index: /palm/trunk/SOURCE/Makefile
===================================================================
--- /palm/trunk/SOURCE/Makefile	(revision 2920)
+++ /palm/trunk/SOURCE/Makefile	(revision 2921)
@@ -25,4 +25,7 @@
 # -----------------
 # $Id$
+# date_and_time_mod dependency has been added to read/write_restart_data_mod
+# 
+# 2918 2018-03-21 15:52:14Z gronemeier
 # read/write_3d_binary and read/write_var_list has been removed, 
 # read/write_restart_data_mod, wrd_write_string and
@@ -1344,5 +1347,6 @@
 read_restart_data_mod.o: \
 	chemistry_model_mod.o \
-	cpulog_mod.o\
+	cpulog_mod.o \
+	date_and_time_mod.o \
 	gust_mod.o \
 	land_surface_model_mod.o \
@@ -1674,4 +1678,5 @@
 write_restart_data_mod.o: \
 	chemistry_model_mod.o \
+	date_and_time_mod.o \
 	gust_mod.o \
 	land_surface_model_mod.o \
Index: /palm/trunk/SOURCE/land_surface_model_mod.f90
===================================================================
--- /palm/trunk/SOURCE/land_surface_model_mod.f90	(revision 2920)
+++ /palm/trunk/SOURCE/land_surface_model_mod.f90	(revision 2921)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! The activation of spinup has been moved to parin
+! 
+! 2894 2018-03-15 09:17:58Z Giersch
 ! Calculations of the index range of the subdomain on file which overlaps with
 ! the current subdomain are already done in read_restart_data_mod,
@@ -4586,17 +4589,4 @@
        land_surface = .TRUE.
 
-!
-!--    Activate spinup
-       IF ( spinup_time > 0.0_wp )  THEN
-          coupling_start_time = spinup_time
-          IF ( spinup_pt_mean == 9999999.9_wp )  THEN
-             spinup_pt_mean = pt_surface
-          ENDIF
-          IF ( .NOT. spinup )  THEN
-             end_time = end_time + spinup_time
-             spinup = .TRUE.
-          ENDIF
-       ENDIF
-
 
  10    CONTINUE
Index: /palm/trunk/SOURCE/parin.f90
===================================================================
--- /palm/trunk/SOURCE/parin.f90	(revision 2920)
+++ /palm/trunk/SOURCE/parin.f90	(revision 2921)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! Activation of spinup has been moved from lsm/usm_parin to parin itself
+! 
+! 2906 2018-03-19 08:56:40Z Giersch
 ! ENVIRONMENT variables read/write_svf has been added 
 ! 
@@ -707,4 +710,17 @@
 
 !
+!--       Activate spinup
+          IF ( land_surface .OR. urban_surface )  THEN
+             IF ( spinup_time > 0.0_wp )  THEN
+                coupling_start_time = spinup_time
+                IF ( spinup_pt_mean == 9999999.9_wp )  THEN
+                   spinup_pt_mean = pt_surface
+                ENDIF
+                end_time = end_time + spinup_time
+                spinup = .TRUE.
+             ENDIF
+          ENDIF
+
+!
 !--       In case of nested runs, explicitly set nesting boundary conditions. 
 !--       This will overwrite the user settings and basic defaults.
Index: /palm/trunk/SOURCE/read_restart_data_mod.f90
===================================================================
--- /palm/trunk/SOURCE/read_restart_data_mod.f90	(revision 2920)
+++ /palm/trunk/SOURCE/read_restart_data_mod.f90	(revision 2921)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! spinup_time, day_of_year_init and time_utc_init are also read now
+! 
+! 2912 2018-03-20 13:00:05Z knoop
 ! Added gust module interface calls
 ! 
@@ -78,4 +81,7 @@
            ONLY:  inflow_damping_factor, mean_inflow_profiles, pt_init,        &
                   q_init, ref_state, s_init, sa_init, u_init, ug, v_init, vg
+
+       USE date_and_time_mod,                                                  &
+           ONLY:  day_of_year_init, time_utc_init
 
        USE flight_mod,                                                         &
@@ -343,4 +349,6 @@
              CASE ( 'damp_level_1d' )
                 READ ( 13 )  damp_level_1d
+             CASE ( 'day_of_year_init' )
+                READ ( 13 )  day_of_year_init
              CASE ( 'dissipation_1d' )
                 READ ( 13 )  dissipation_1d
@@ -561,4 +569,6 @@
              CASE ( 'simulated_time' )
                 READ ( 13 )  simulated_time
+             CASE ( 'spinup_time' )
+                READ ( 13 )  spinup_time
              CASE ( 'surface_heatflux' )
                 READ ( 13 )  surface_heatflux
@@ -609,4 +619,6 @@
              CASE ( 'time_since_reference_point' )
                 READ ( 13 )  time_since_reference_point
+             CASE ( 'time_utc_init' )
+                READ ( 13 )  time_utc_init
              CASE ( 'timestep_scheme' )
                 READ ( 13 )  timestep_scheme
Index: /palm/trunk/SOURCE/urban_surface_mod.f90
===================================================================
--- /palm/trunk/SOURCE/urban_surface_mod.f90	(revision 2920)
+++ /palm/trunk/SOURCE/urban_surface_mod.f90	(revision 2921)
@@ -28,4 +28,7 @@
 ! -----------------
 ! $Id$
+! The activation of spinup has been moved to parin
+! 
+! 2920 2018-03-22 11:22:01Z kanani
 ! Remove unused pcbl, npcbl from ONLY list
 ! moh.hefny:
@@ -5177,18 +5180,7 @@
        urban_surface = .TRUE.
 
-!
-!--    Activate spinup
-       IF ( spinup_time > 0.0_wp )  THEN
-          coupling_start_time = spinup_time
-          IF ( spinup_pt_mean == 9999999.9_wp )  THEN
-             spinup_pt_mean = pt_surface
-          ENDIF
-          IF ( .NOT. spinup )  THEN
-             end_time = end_time + spinup_time
-             spinup = .TRUE.
-          ENDIF
-       ENDIF
 
  10    CONTINUE
+
 
     END SUBROUTINE usm_parin
Index: /palm/trunk/SOURCE/write_restart_data_mod.f90
===================================================================
--- /palm/trunk/SOURCE/write_restart_data_mod.f90	(revision 2920)
+++ /palm/trunk/SOURCE/write_restart_data_mod.f90	(revision 2921)
@@ -25,4 +25,7 @@
 ! -----------------
 ! $Id$
+! spinup_time, day_of_year_init and time_utc_init are also written out now
+! 
+! 2912 2018-03-20 13:00:05Z knoop
 ! Added gust module interface calls
 ! 
@@ -77,4 +80,7 @@
                   q_init, ref_state, s_init, sa_init, u_init, ug, v_init, vg
 
+       USE date_and_time_mod,                                                  &
+           ONLY:  day_of_year_init, time_utc_init
+
        USE flight_mod,                                                         &
            ONLY:  flight_wrd_global
@@ -313,4 +319,7 @@
        WRITE ( 14 )  damp_level_1d
 
+       CALL wrd_write_string( 'day_of_year_init' ) 
+       WRITE ( 14 )  day_of_year_init
+
        CALL wrd_write_string( 'dissipation_1d' ) 
        WRITE ( 14 )  dissipation_1d
@@ -632,4 +641,7 @@
        WRITE ( 14 )  simulated_time
 
+       CALL wrd_write_string( 'spinup_time ' ) 
+       WRITE ( 14 )  spinup_time 
+
        CALL wrd_write_string( 'surface_heatflux' ) 
        WRITE ( 14 )  surface_heatflux
@@ -703,4 +715,7 @@
        CALL wrd_write_string( 'time_since_reference_point' ) 
        WRITE ( 14 )  time_since_reference_point
+
+       CALL wrd_write_string( 'time_utc_init' ) 
+       WRITE ( 14 )  time_utc_init
 
        CALL wrd_write_string( 'timestep_scheme' ) 
