Index: palm/trunk/SOURCE/calc_spectra.f90
===================================================================
--- palm/trunk/SOURCE/calc_spectra.f90	(revision 1323)
+++ palm/trunk/SOURCE/calc_spectra.f90	(revision 1324)
@@ -20,5 +20,5 @@
 ! Current revisions:
 ! -----------------
-!
+! Bugfix: nzb_x, nzb_yd, nyn_x, nyn_x, nzt_x, nzt_yd belong to transpose_indices 
 !
 ! Former revisions:
@@ -77,5 +77,5 @@
 
     USE indices,                                                               &
-        ONLY:  nxl, nxr, nyn, nys, nzb, nzt, nzt_x, nzt_yd
+        ONLY:  nxl, nxr, nyn, nys, nzb, nzt
 
     USE kinds
@@ -274,5 +274,5 @@
 
     USE indices,                                                               &
-        ONLY:  nx, ny, nyn_x, nys_x, nzb_x, nzt_x
+        ONLY:  nx, ny
 
     USE kinds
@@ -286,5 +286,6 @@
         ONLY:  spectrum_x
 
-    USE transpose_indices
+    USE transpose_indices,                                                     &
+        ONLY:  nyn_x, nys_x, nzb_x, nzt_x
 
 
@@ -411,5 +412,5 @@
 
     USE indices,                                                               &
-        ONLY:  nx, ny, nxl_yd, nxr_yd, nzb_yd, nzt_yd
+        ONLY:  nx, ny
 
     USE kinds
@@ -423,5 +424,6 @@
         ONLY:  spectrum_y
 
-    USE transpose_indices
+    USE transpose_indices,                                                     &
+        ONLY:  nxl_yd, nxr_yd, nzb_yd, nzt_yd
 
 
Index: palm/trunk/SOURCE/data_output_spectra.f90
===================================================================
--- palm/trunk/SOURCE/data_output_spectra.f90	(revision 1323)
+++ palm/trunk/SOURCE/data_output_spectra.f90	(revision 1324)
@@ -20,5 +20,6 @@
 ! Current revisions:
 ! -----------------
-!
+! Bugfix: module statistics and module spectrum added, missing variables in ONLY
+! arguments added
 !
 ! Former revisions:
@@ -58,5 +59,7 @@
 
     USE control_parameters,                                                    &
-        ONLY:  average_count_sp, averaging_interval_sp, dosp_time_count
+        ONLY:  average_count_sp, averaging_interval_sp, dosp_time_count,       &
+               message_string, netcdf_output, run_description_header,          &
+               time_since_reference_point
 
     USE cpulog,                                                                &
@@ -70,5 +73,5 @@
 
     USE spectrum,                                                              &
-        ONLY:  data_output_sp
+        ONLY:  data_output_sp, spectra_direction
 
     USE statistics,                                                            &
@@ -274,9 +277,11 @@
  SUBROUTINE data_output_spectra_x( m, cranz, pr, frame_written )
 
+    USE arrays_3d,                                                             &
+        ONLY:  zu, zw
     USE constants,                                                             &
         ONLY:  pi
 
     USE control_parameters,                                                    &
-        ONLY:  averaging_interval_sp
+        ONLY:  averaging_interval_sp, run_description_header, simulated_time_chr
 
     USE grid_variables,                                                        &
@@ -290,6 +295,10 @@
     USE pegrid
 
+    USE statistics,                                                            &
+        ONLY:  spectrum_x
+
     USE spectrum,                                                              &
-        ONLY:  comp_spectra_level, n_sp_x, plot_spectra_level
+        ONLY:  comp_spectra_level, header_char, lstyles, klist_x, n_sp_x,      &
+               plot_spectra_level, utext_char, ytext_char
 
     IMPLICIT NONE
@@ -469,9 +478,12 @@
  SUBROUTINE data_output_spectra_y( m, cranz, pr, frame_written )
 
+    USE arrays_3d,                                                             &
+        ONLY:  zu, zw
+ 
     USE constants,                                                             &
         ONLY:  pi
 
     USE control_parameters,                                                    &
-        ONLY:  averaging_interval_sp
+        ONLY:  averaging_interval_sp, run_description_header, simulated_time_chr
 
     USE grid_variables,                                                        &
@@ -484,6 +496,11 @@
 
     USE pegrid
-
-    USE spectrum  comp_spectra_level, plot_spectra_level
+    
+    USE statistics,                                                             &
+        ONLY:  spectrum_y
+
+    USE spectrum,                                                              &
+        ONLY:  comp_spectra_level, header_char, klist_y, lstyles, n_sp_y,      &
+               plot_spectra_level, utext_char, ytext_char
 
     IMPLICIT NONE
Index: palm/trunk/SOURCE/header.f90
===================================================================
--- palm/trunk/SOURCE/header.f90	(revision 1323)
+++ palm/trunk/SOURCE/header.f90	(revision 1324)
@@ -20,5 +20,5 @@
 ! Current revisions:
 ! -----------------
-!
+! Bugfix: module spectrum added
 !
 ! Former revisions:
@@ -175,4 +175,8 @@
         
     USE pegrid
+    
+    USE spectrum,                                                              &
+        ONLY:  comp_spectra_level, data_output_sp, plot_spectra_level,         &
+               spectra_direction
 
     IMPLICIT NONE
@@ -487,4 +491,5 @@
        ENDIF
     ENDIF
+
 
 !
Index: palm/trunk/SOURCE/init_masks.f90
===================================================================
--- palm/trunk/SOURCE/init_masks.f90	(revision 1323)
+++ palm/trunk/SOURCE/init_masks.f90	(revision 1324)
@@ -20,4 +20,5 @@
 ! Current revisions:
 ! -----------------
+! Bugfix: ONLY statement for module netcdf_control removed 
 !
 ! Former revisions:
@@ -89,6 +90,5 @@
     USE kinds
 
-    USE netcdf_control,                                                        &
-        ONLY:  domask_unit
+    USE netcdf_control
 
     USE particle_attributes,                                                   &
Index: palm/trunk/SOURCE/package_parin.f90
===================================================================
--- palm/trunk/SOURCE/package_parin.f90	(revision 1323)
+++ palm/trunk/SOURCE/package_parin.f90	(revision 1324)
@@ -20,5 +20,5 @@
 ! Current revisions:
 ! -----------------
-!
+! Bugfix: Missing variable dt_data_output output added to ONLY statement
 !
 ! Former revisions:
@@ -56,6 +56,6 @@
 
     USE control_parameters,                                                    &
-        ONLY:  averaging_interval_sp, dt_dopts, dt_dosp, dt_dvrp,              &
-                particle_maximum_age, skip_time_dosp, threshold
+        ONLY:  averaging_interval_sp, dt_data_output, dt_dopts, dt_dosp,       &
+               dt_dvrp, particle_maximum_age, skip_time_dosp, threshold
 
     USE dvrp_variables,                                                        &
Index: palm/trunk/SOURCE/surface_coupler.f90
===================================================================
--- palm/trunk/SOURCE/surface_coupler.f90	(revision 1323)
+++ palm/trunk/SOURCE/surface_coupler.f90	(revision 1324)
@@ -20,6 +20,6 @@
 ! Current revisions:
 ! ------------------
+! Bugfix: ONLY statement for module pegrid removed 
 ! 
-!
 ! Former revisions:
 ! -----------------
@@ -435,7 +435,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  comm2d, comm_inter, ierr, MPI_DOUBLE_PRECISION, myid, ngp_a,    &
-               target_id
+    USE pegrid
 
     IMPLICIT NONE
@@ -521,7 +519,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  comm2d, comm_inter, ierr, MPI_DOUBLE_PRECISION, myid, ngp_o,    &
-               target_id
+    USE pegrid
 
     IMPLICIT NONE
Index: palm/trunk/SOURCE/transpose.f90
===================================================================
--- palm/trunk/SOURCE/transpose.f90	(revision 1323)
+++ palm/trunk/SOURCE/transpose.f90	(revision 1324)
@@ -20,5 +20,5 @@
 ! Current revisions:
 ! -----------------
-! 
+! Bugfix: ONLY statement for module pegrid removed 
 ! 
 ! Former revisions:
@@ -264,7 +264,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dx, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               pdims, sendrecvcount_zx
+    USE pegrid
 
     USE transpose_indices,                                                     &
@@ -407,7 +405,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dy, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               numprocs, pdims, sendrecvcount_xy
+    USE pegrid
 
     USE transpose_indices,                                                     &
@@ -504,7 +500,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dx, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               pdims, sendrecvcount_xy
+    USE pegrid
 
     USE transpose_indices,                                                     &
@@ -629,7 +623,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dx, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               pdims, sendrecvcount_yz
+    USE pegrid
 
     USE transpose_indices,                                                     &
@@ -767,7 +759,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dx, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               pdims, sendrecvcount_zx
+    USE pegrid
 
     USE transpose_indices,                                                     &
@@ -909,7 +899,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dx, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               pdims, sendrecvcount_yz
+    USE pegrid
 
     USE transpose_indices,                                                     &
@@ -1007,7 +995,5 @@
     USE kinds
 
-    USE pegrid,                                                                &
-        ONLY:  collective_wait, comm1dy, comm2d, ierr, MPI_DOUBLE_PRECISION,   &
-               pdims, sendrecvcount_zyd
+    USE pegrid
 
     USE transpose_indices,                                                     &
Index: palm/trunk/SOURCE/write_var_list.f90
===================================================================
--- palm/trunk/SOURCE/write_var_list.f90	(revision 1323)
+++ palm/trunk/SOURCE/write_var_list.f90	(revision 1324)
@@ -20,5 +20,5 @@
 ! Current revisions:
 ! -----------------
-!
+! Bugfix: ONLY statement for module netcdf_control removed 
 !
 ! Former revisions:
@@ -119,6 +119,5 @@
         ONLY:  damp_level_1d, dt_pr_1d, dt_run_control_1d, end_time_1d
     
-    USE netcdf_control,                                                        &
-        ONLY:  output_for_t0
+    USE netcdf_control
     
     USE particle_attributes,                                                   &
