 				sprintf(fname, "%s.%s.%02d", fname_pre, "A", index);
 				file_ptr[index] = fopen(fname, "w");
 				fwrite( param_ptr, sizeof(SHM_PARAM), 1, file_ptr[index]);
+				sprintf(fname, "%s.%s.%02d", fname_pre, "P", index);
+				power_ptr[index] = fopen(fname, "w");
+				fwrite( param_ptr, sizeof(SHM_PARAM), 1, power_ptr[index]);
 			}
 			sprintf(fname, "%s.%s.%02d", fname_pre, "C", 0);  file_ptr[Nif]   = fopen(fname, "w");
 			sprintf(fname, "%s.%s.%02d", fname_pre, "C", 1);  file_ptr[Nif+1] = fopen(fname, "w");

	short	*k5data_ptr;				// Pointer to shared K5 data
	float	*xspec_ptr;					// Pointer to 1-sec-integrated Power Spectrum
	FILE	*file_ptr[6];				// File Pointer to write
	char	fname[24];					// File Name [YYYYDOYHHMMSSIF]
	char	fname_pre[16];
	unsigned int		bitDist[64];

		cudaMemcpy(xspec_ptr, cuPowerSpec, Nif* NFFT2* sizeof(float), cudaMemcpyDeviceToHost);
		for(index=0; index<Nif; index++){
			fwrite(&xspec_ptr[index* NFFT2], sizeof(float), NFFT2, file_ptr[index]);	// Save Pspec
			fwrite(&bitDist[index* 16], sizeof(int), 16, power_ptr[index]);				// Save Bitdist
		}
		cudaMemcpy(&xspec_ptr[4* NFFT2], cuXSpec, 2* NFFT2* sizeof(float2), cudaMemcpyDeviceToHost);
		fwrite(&xspec_ptr[4* NFFT2], sizeof(float2), NFFT2, file_ptr[4]);	// Save Xspec (IF0 - IF2)
