Info

Questa domanda è chiusa. Riaprila per modificarla o per rispondere.

I want to create a data file where i want to enter a gain value and a 1x96000 array. i am unable to read both values separately. i have written the following code. after using the following code the data and gain have not been retrieved.

2 visualizzazioni (ultimi 30 giorni)
gain = 24.08; data = [0:1:96000]; fid = fopen('jibs.dat','ieee-be'); if if~=-1 fseek(fid,276,'bof') end fwrite(fid,gain,'float32') fseek(fid,5120,'bof') fwrite(fid,data,'float32') fclose(fid) clc clear all %%%% to read data %%%%% fid = fopen('jibs.dat','ieee-be'); fseek(fid,276,'bof'); gain2 = fread(fid,1,'float'); fseek(fid,5120,'bof'); data2 = fread(fid,'inf','float'); fclose (fid)

Risposte (0)

Questa domanda è chiusa.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by