Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
plugin-GUI
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
yehaojie
plugin-GUI
Commits
30914395
Commit
30914395
authored
10 years ago
by
Aaron Cuevas Lopez
Browse files
Options
Downloads
Patches
Plain Diff
Read proper channels on RHD2132 16ch headstage
parent
216d11fc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Source/Processors/DataThreads/RHD2000Thread.cpp
+7
-3
7 additions, 3 deletions
Source/Processors/DataThreads/RHD2000Thread.cpp
with
7 additions
and
3 deletions
Source/Processors/DataThreads/RHD2000Thread.cpp
+
7
−
3
View file @
30914395
...
...
@@ -42,6 +42,7 @@
#define CHIP_ID_RHD2164_B 1000
#define REGISTER_59_MISO_A 53
#define REGISTER_59_MISO_B 58
#define RHD2132_16CH_OFFSET 8
// Allocates memory for a 3-D array of doubles.
void
allocateDoubleArray3D
(
std
::
vector
<
std
::
vector
<
std
::
vector
<
double
>
>
>&
array3D
,
...
...
@@ -1456,7 +1457,7 @@ bool RHD2000Thread::stopAcquisition()
bool
RHD2000Thread
::
updateBuffer
()
{
int
chOffset
;
//cout << "Number of 16-bit words in FIFO: " << evalBoard->numWordsInFifo() << endl;
//cout << "Block size: " << blockSize << endl;
...
...
@@ -1473,7 +1474,10 @@ bool RHD2000Thread::updateBuffer()
// do the neural data channels first
for
(
int
dataStream
=
0
;
dataStream
<
enabledStreams
.
size
();
dataStream
++
)
{
if
((
chipId
[
dataStream
]
==
CHIP_ID_RHD2132
)
&&
(
numChannelsPerDataStream
[
dataStream
]
==
16
))
//RHD2132 16ch. headstage
chOffset
=
RHD2132_16CH_OFFSET
;
else
chOffset
=
0
;
for
(
int
chan
=
0
;
chan
<
numChannelsPerDataStream
[
dataStream
];
chan
++
)
{
...
...
@@ -1481,7 +1485,7 @@ bool RHD2000Thread::updateBuffer()
channel
++
;
int
value
=
dataBlock
->
amplifierData
[
dataStream
][
chan
][
samp
];
int
value
=
dataBlock
->
amplifierData
[
dataStream
][
chan
+
chOffset
][
samp
];
thisSample
[
channel
]
=
float
(
value
-
32768
)
*
0.195
f
;
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment