Skip to content
Snippets Groups Projects
Commit a1691ec1 authored by Aaron Cuevas Lopez's avatar Aaron Cuevas Lopez
Browse files

Fix bitVolts not read properly by kwik file source

parent 8e39b06e
No related branches found
No related tags found
No related merge requests found
......@@ -117,9 +117,22 @@ void KWIKFileSource::fillRecordInfo()
try
{
recordN = recordings.openGroup((String(i) + "/application_data").toUTF8());
attr=recordN.openAttribute("channel_bit_volts");
attr.read(ArrayType(PredType::NATIVE_FLOAT,1,&dims[1]),bitVoltArray);
foundBitVoltArray = true;
try
{
DataSet bV = recordN.openDataSet("channel_bit_volts");
bV.read(bitVoltArray.getData(), PredType::NATIVE_FLOAT);
foundBitVoltArray = true;
}
catch (GroupIException)
{ }
catch (DataSetIException)
{ }
if (!foundBitVoltArray)
{
attr = recordN.openAttribute("channel_bit_volts");
attr.read(ArrayType(PredType::NATIVE_FLOAT, 1, &dims[1]), bitVoltArray);
foundBitVoltArray = true;
}
} catch (GroupIException)
{
} catch (AttributeIException)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment