File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -549,7 +549,7 @@ void Neuropixels2e::processFrames()
549549 const size_t channelIndex = rawToChannel[j][i];
550550
551551 samples[probeIndex][channelIndex * numFrames + frameCount[probeIndex]] =
552- (float )(*(amplifierData + adcIndices[j] + adcDataOffset)) * gainCorrection[probeIndex];
552+ (float )(*(amplifierData + adcIndices[j] + adcDataOffset)) * gainCorrection[probeIndex] + DataMidpoint ;
553553 }
554554 }
555555
Original file line number Diff line number Diff line change @@ -95,6 +95,9 @@ namespace OnixSourcePlugin
9595
9696 static constexpr int NumberOfProbes = 2 ;
9797
98+ static constexpr uint16_t NumberOfAdcBins = 4096 ;
99+ static constexpr float DataMidpoint = NumberOfAdcBins / 2 ;
100+
98101 DataBuffer* amplifierBuffer[NumberOfProbes];
99102
100103 std::array<uint64_t , NumberOfProbes> probeSN;
You can’t perform that action at this time.
0 commit comments