ECG Data Acquisition and interpretation on Matlab

Started by Badreddinez, March 22, 2015, 12:51:42 PM

Previous topic - Next topic

Badreddinez

dat

Hello Olimex community,

Well, I tend to acquire the raw ECG signal from the board but it seems tricky to have High and Low portions for a single channel. Any way how to concatenate both of them to a single signal?

Also, I would like to work on one of these alternatives:

1. Acquiring the data on Matlab. But, there will be a problem of data format matching since Serial.Write send the data as ASCII while we need them on Matlab as Float/int/Double.

2. Saving the ECG on text file or MS Excel file.

I hope that could be feasible so we can make interpretation for the ECG on Matlab (mainly Biometric identification).

Thank you so much in advance.

Warm regards,
Badr Eddine

claydergc

I found this post -> https://bakerdh.wordpress.com/2013/01/31/a-first-look-at-the-olimex-eeg-smt/ when surfing the web. I haven't tried it, but it seems that he is getting the signal data and plotting it.

I'm also trying to get the raw signal from the board, but in my case I'm using C++. So, I am using portions of the brainbay source code, exactly in the file ob_eeg.cpp, the function parse_byte_P2() I'm adding this code:


char str[256];
unsigned short chn1Value = (PACKET.buffer[0]<<8) + PACKET.buffer[1];
unsigned short chn2Value = (PACKET.buffer[2]<<8) + PACKET.buffer[3];
sprintf_s(str, "chn1: %u, chn2: %u\n", chn1Value, chn2Value);
OutputDebugString(str);


I don't know if that code is correct (I'm still testing it), but I'm getting some integers that seems to correspond to the raw signal of the board.

I hope this can help you.

Regards.


joe50

Hi Badreddinez

Could you guide us through your youtube video project? What did you use to read the data from the shield EKG directly into matlab and labview?

Thanks for any input