save MATLAB format

Save MATLAB format, a forum discussion on Cleverscope. Join us for more discussions on Save MATLAB format on our Desired Features forum.

Back to Forum Index : Back to Desired Features   RSS

20 Jan 2011
Posts:

Hello,

I have a problem with the acquired signals. I usually save the acquisiton with cleverscope and then I proccess the signals with Matlab but is quite slow to save the signals to a compatible format:

1- you have to acquire the signal
2- you have to ""get frame"" to save all the signal
3- you save the signal in binary format (ascii is horrible to open). In my case this means, open apc file, click on save binary, change name, click in save button
4- you have to convert the signal from binary format to matlab format

I try to use new math function to save signal in matlab format but the problem is the same: the horrible ""get frame problem"". If you save the acquisition using the matlab library you ""only save"" the graph in ""low temporal resolution"" against the full temporal resolution which is acquired when you puss the ""get frame button"".

Please, I need to save the acquisitions at full temporal resolution without the need of pussing ""get frame"" button and if is possible I need to save the signals in Matlab format. We are one step closer with the inclusion of matlab libraries but we need also full temporal resolution.

Thank you very much.

27 Jan 2011
Posts: 396

Yes, we fully understand this, and have a new setting in the pipeline. It will appear in the next release. It is a button next to the 'Get Frame' button. If on we'll automatically do a get frame after every trigger. If off, operation is as current. The autosave options will work as at current, and save whatever is in the buffer.

I'm not understanding why you cannot just open the binary file in Matlab.

Here is a Matlab code snippet supplied by another customer to open the binary file:

% read in data Channel A
fid = fopen(test_A.bin','r','s');
chA_header = (fread(fid,8,'float64'));
% Calc sample set values
num_samples = chA_header(2);
dt=chA_header(4);
T0 = chA_header(5);
fs=1/dt;
chA_data = fread(fid,num_samples,'float32');
fclose(fid);
%
%Plot the data so you can see it
time=((0:num_samples-1)*dt)+T0; % Calc graph time axis
figure (1) % Plot data to fig 1
plot(time, chA_data, 'r')
grid on

I hope this helps!

31 Jan 2011
Posts:

Thank you for your answer.

I have no problems with the conversion of the data to the matlab format. I already have a library to do this.

I think if you implement the automated ""get frame"" acquisition it could be a great improvement because if you combine this function with the matlab implementation you can have an automated acquisition system which is wonderful. I wrote the library to save in matlab, but the problem now is you cannot save the complete frame.

I`ll be waiting for your next version of the program.

Thank you,

Jesus

10 Feb 2012
Posts: 396

Its been a while, but we have now automated the Get Frame process. Click Autoget, and every frame transfer (and save) is a full buffer.

In addition we have added 4 matlab functions that you can call using Maths Equation builder. This allows you to pipe data directlt to Matlab live. See the Help button in the Maths Equation Builder. We have examples in the manual. You can send full buffers to Matlab without problems.
Back to Forum Index : Back to Desired Features   RSS
You must be logged in to post a reply



You need to Register or Log In before posting on these forums.

×

Your shopping cart is empty.