Problems of import a .pl2 file

Hi,

I am trying to import a .pl2 file into the brainstorm. As indicated by the tutorial, I set pass to the SDK package, and review the raw file. However, I received an error report as the following,

Is there any method of solving the problem?
Many thanks!

Peng-Hu

Could you please share a short example file?
(upload it somewhere and post the download link here)

Hi, Francois,

Here is the link,

https://www.dropbox.com/s/t1syklaneh48i92/2021-03-01.pl2?dl=0

Many thanks,

Peng-Hu Wei

Thank you for the example file.
Indeed, it seems that there is something wrong in the Brainstorm reader.

@mpompolas @MartinC
Could you check your code with the attached file?
Since you have some experience with this file format and this SDK, you might be much more efficient, and I will avoid damaging your existing use cases.
It seems like AnalogChannels{i}.NumValues is not the appropriate place to get the number of samples, since it is set to zero in the example while it is possible to read data from this file with PL2ReadFirstDataBlock.

Hi @weipenghu2005.

Please update Brainstorm and try again