quite low amplitude using micro SD

Hello all,

I tested OpenBCI Ultracortex with ThinkPulse and I believe that it looks fine when I observe EEG on OpenBCI_GUI via serial communication. I hope to use higher sampling rate than 250Hz, and so I used micro SD. I could use micro SD without error but I was surprised that amplitude of waves was obviously weaker than it recorded by serial communication.

I did simple experiment to show this issues. Would you check my attached video?(or an
image) In this video, a left side window shows data recorded in micro SD and a right side shows data via streaming. In this experiment, a subject meditated in 3 minutes. Of course, sampling rate was 250Hz. The data was recorded by both of micro SD and streaming at the same time using OpenBCI_GUI. These data should have been the almost same as each other. However, you may find the amplitude of waves in the left windows, recorded in micro SD, quite lower than the right side of ones, recorded via streaming. I guess that the amplitude of data in micro SD is nearly 1/3 of the amplitude of streaming data but the shape of waves looks the same as each other.

I assume when I record the data in micro SD, I observe small amplitude of waves.
I do not know why it happens. It is difficult to observe significant spectrum from such poor data.
I would be happy if I received your response.

Comments

  • wjcroftwjcroft Mount Shasta, CA

    Hiro, hello.

    Are you correctly adjusting the Cyton 'gain' when using Thinkpulse? It must be reduced from the default gain of x24.

    re: higher sample rates with SD card

    It's not clear this is supported. The API commands to change sample rate were intended to apply to the Wifi Shield, which is no longer in the Shop or supported. Other threads here on the forum cover the historical issues with the Shield.

    Regards, William

  • hirohiro Japan
    edited July 2023

    wjcroft,
    Thank you for your comment. The PGA gain was x8. I modified settings based on "ThinkPulse Getting Started Guide" but I included BIAS because amplitude of waves was poor when I removed BIAS. I also checked this thread.
    https://openbci.com/forum/index.php?p=/discussion/comment/18449#Comment_18449
    Jason did not disconnect BIAS and showed results on OpenBCI_GUI.

    It's not clear this is supported.

    As you say, the OpenBCI_GUI is not supported. I have read "Cyton Board Programming Tutorial" and sent commands to boards to increase sampling rates. I believe it is fine, and the amplitude of waves still weak if I change sampling rate to any values.

  • wjcroftwjcroft Mount Shasta, CA

    So please confirm. You are saying that there are NO amplitude differences (streaming vs SD card), when using the default sampling rate of 250 Hz. The weaker amplitude SD card signals only show up when selecting faster sample rates. Is that correct?

    If that is the case, it might be further evidence that faster sampling to SD card is NOT really supported. Those SDK commands are there for the Wifi Shield. And not intended for faster SD card recording.

    Another issue with faster SD card recording is that there are limitations in how fast the actual SD card writer and firmware can buffer and write faster data streams. You may be hitting such a roadblock.

    Regards, William

  • hirohiro Japan

    So please confirm. You are saying that there are NO amplitude differences (streaming vs SD card), when using the default sampling rate of 250 Hz. The weaker amplitude SD card signals only show up when selecting faster sample rates. Is that correct?

    No, I used 250 Hz but I noticed the amplitude difference between streaming and SD card. I also tested 500Hz and 1000Hz but it is impossible to send signal. Although I think these are low power using high frequency, I could not compare amplitude of streaming and SD card at the same situation. So, I recorded data in micro SD card and via streaming at the same time using sampling rate 250Hz, and compared amplitude between streaming and SD card.

    Another issue with faster SD card recording is that there are limitations in how fast the actual SD card writer and firmware can buffer and write faster data streams. You may be hitting such a roadblock.

    I guess it could be true. I use one of the most fastest writing speed 16 GB (not more than 32 GB) micro SD. I show a log on the Arduino serial monitor.(.txt file) My micro SD spend around 327 microseconds maybe per block. Do you know the limitation of writing speed of card reader? Or could I search it? I read a page, "Cyton Spec", but I cannot find the description of the card reader. I am going to test again using more slower writing speed cards than now, or using a delay function considering the limit of max writing speed. I would like to know information of the writing speed limit to buy a new card.

  • hirohiro Japan

    So please confirm. You are saying that there are NO amplitude differences (streaming vs SD card), when using the default sampling rate of 250 Hz. The weaker amplitude SD card signals only show up when selecting faster sample rates. Is that correct?

    No, I used 250 Hz but I noticed the amplitude difference between streaming and SD card. I also tested 500Hz and 1000Hz but it is impossible to send signal. Although I think these are low power using high frequency, I could not compare amplitude of streaming and SD card at the same situation. So, I recorded data in micro SD card and via streaming at the same time using sampling rate 250Hz, and compared amplitude between streaming and SD card.

    Another issue with faster SD card recording is that there are limitations in how fast the actual SD card writer and firmware can buffer and write faster data streams. You may be hitting such a roadblock.

    I guess it could be true. I use one of the most fastest writing speed 16 GB (not more than 32 GB) micro SD. I show a log on the Arduino serial monitor.(.txt file) My micro SD spend around 327 microseconds maybe per block. Do you know the limitation of writing speed of card reader? Or could I search it? I read a page, "Cyton Spec", but I cannot find the description of the card reader. I am going to test again using more slower writing speed cards than now, or using a delay function considering the limit of max writing speed. I would like to know information of the writing speed limit to buy a new card.

  • hirohiro Japan
    edited July 2023

    So please confirm. You are saying that there are NO amplitude differences (streaming vs SD card), when using the default sampling rate of 250 Hz. The weaker amplitude SD card signals only show up when selecting faster sample rates. Is that correct?

    No, I used 250 Hz but I noticed the amplitude difference between streaming and SD card. I also tested 500Hz and 1000Hz but it is impossible to send signal. Although I think these are low power using high frequency, I could not compare amplitude of streaming and SD card at the same situation. So, I recorded data in micro SD card and via streaming at the same time using sampling rate 250Hz, and compared amplitude between streaming and SD card.

    Another issue with faster SD card recording is that there are limitations in how fast the actual SD card writer and firmware can buffer and write faster data streams. You may be hitting such a roadblock.

    I guess it could be true. I use one of the most fastest writing speed 16 GB (not more than 32 GB) micro SD card. My SD card spend around 327 microseconds maybe per block. Do you know the limitation of writing speed of the card reader? Or could I search it? I read a page, "Cyton Spec", but I cannot find the description of the card reader. I am going to use more slower writing speed cards than now, or a delay function considering the limit of max writing speed. I would like to know information of the writing speed limit to buy a new card.

  • wjcroftwjcroft Mount Shasta, CA

    I'm stumped regarding why your 250 Hz SD card recordings are lower amplitude than GUI streamed recordings.

    Mentioning Richard @retiutut, the GUI dev.

    re: SD cards rating, I suggest using a decently specified 'modern' SD card. I still am doubting you can get reliable faster sample rate recording to SD. That was never a promoted feature. The SDK commands were intended for Shield configurations.

  • hirohiro Japan
    edited July 2023

    Hi William,
    Thank you for your help. I see. I will try to use my cheaper SD card, it's normal quality.

    I still am doubting you can get reliable faster sample rate recording to SD.

    If your expectation is right, it is enough to record correctly using 250Hz sampling rate. I have kits to record with 16 channel electrodes. You may know when we use a Cyton-Daisy 16-channel board, sampling rate is limited to 125Hz. I would like to avoid it.

    Hiro

  • Hi Hiro,
    I believe the CytonDaisy sample rate is 125 Hz, regardless if you are saving the data to GUI folder or to microSD card.
    I am surfacing this thread to RW's attention. I will revert with feedback.
    best,
    Shirley

  • hirohiro Japan
    edited August 2023

    Hi all,
    I did a few of experiences and I found that the same issue cause using another SD or CytonDaisy board but Gelfree did not cause the issue.

    First, I exchanged a faster SD card for slower one and did experience the same as the first thread. I found nothing changed.
    Second, I exchanged a CytonDaisy board for another one because I suspect that my CytonDaisy board is broken. I connected one channel of ThinkPulse active electrode to another board and did the same experience. I will show the image "TPonechannel1" as the result of it.
    The left side is the EEG recorded in a micro SD, the right side is the one streamed. Similarly, the power of waves recorded in a SD card is low. Thus, I assume that type of SD cards is not reason of this issue and my board is not clashed.

    Next, I also did the same experience using Gelfree electrode cap. I will show the result on the image "gelfree1". You may find both side of waves have the same amplitude though the left side is recorded in micro SD and the right side is streamed. So, Gelfree did not cause the phenomenon of low amplitude of waves only with micro SD. I infer that this issue happens only if I use ThinkPulse or if I change Cyton's PGA gain.

    Additionally, I compared the difference of amplitude of waves between in micro SD and streaming. For example, the sample of data from streaming has "-216293.96424221568". On the other hand, the sample of data in micro SD has "-72097.984375". The result of "data of streaming / data of micro SD=-216293.96424221568/-72097.984375=3.0000001542". I calculated a few of samples of them. I will show it below.
    -216293.96424221568/-72097.984375=3.0000001542
    -221508.78268585/-73836.2578125=3.00000012525
    -283991.72085424914/-94663.90625=3.00000002223
    -275472.6216760423/-91824.20313=3.0000001338
    -199258.9845370036/-66419.65625=3.00000023769
    -259868.66770609235/-86622.88281=3.00000022253
    -269569.54831714014/-89856.51563=3.00000001588
    -255153.34369580075/-85051.10938=3.0000001829
    Although they have the tiny margin of error, which is less than 0.0000003, the ratio of data of streaming to data of micro SD is almost 3:1. I am not sure why this ratio is but I guess that changing gain to 8 times from 24 times might be relate to it.

    If you report your idea about it, or report the same situation, I would be happy.

    Best,
    Hiro

  • hirohiro Japan
    edited August 2023

    Hi Shirley,

    I believe the CytonDaisy sample rate is 125 Hz, regardless if you are saving the data to GUI folder or to microSD card.

    Thank you for your response and I am sorry for late response. I see. Yet, I think sampling rate was 250Hz in my recording. Disappointingly, I cannot attach a file. Instead, I will demonstrate a screenshot.
    First of all, I used my modded program. So, data format is different from default settings. You may find "MicroSec" at the first column. This column show how many microseconds spend from stating recording. In this data, the interval of samples are almost 4000 microseconds = 4milliseconds = 0.004seconds. If sampling rate is 250Hz, the interval of samples should be 1/250=0.004 (seconds). I think it is fine but your situation might be different from mine.
    Hiro

Sign In or Register to comment.