Info
This question is closed. Reopen it to edit or answer.
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 views (last 30 days)
Show older comments
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)
0 Comments
Answers (0)
This question is closed.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!