-
Notifications
You must be signed in to change notification settings - Fork 1
Add Neuropixels 2.0e #39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
For the
Double check what the timer the Juce |
jonnew
approved these changes
Apr 14, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved after addressing comments during live review.
- Mainly adding hub enums
- Create common Neuropixels interface to make it easier to generate UI elements - Add support for passthrough device indices
- Set I2C rate to 400 kHz - Read the correct polled BNO data type, and then convert to useful values - Remove calls to the gate run register of the OutputClock
- Currently capped at 25 Hz when streaming all values
- This is to avoid thread conflicts where a register needs to be written to while the Bno is still trying to read data
- Add a check for the device name that ignores the -X at the end, in the case where multiple headstages are connected
- All streams follow the format "Hub/Device/DataType", except for BNO devices which contain multiple data types in one stream. Those are left as "Hub/Device" - The headstage label is now removed from the canvas, since it was redundant information
- Instead of storing the result in a variable, and then calling a method to get that result, which could result in threading issues, the result of an operation is returned immediately
- Remove the option to invert ephys data, all ephys data is now inverted to match the pxi plugin - Remove the offset correction for 2.0 probes. Not needed
- createStreamName now uses std::vector to concatenate arbitrary length names together - Add the headstage name to the OnixDevice class - Update headstage names to be more consumer friendly
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds the Neuropixels 2.0e Headstage to the plugin. This includes the addition of a
PolledBno
as a device. Currently all values are streamed for thePolledBno
, which does limit the amount of data that can be streamed to be 25 Hz. This is based on empirical testing of the amount of time eachReadBytes()
call takes to read all data. Future updates will allow only the desired values to be read, which should substantially increase the throughput.This PR also simplifies the tabs, and no longer shows the device index in the tab name.
To calculate the offset for each Neuropixels V2 channel, the time to settle seems to be longer than the 1.0f variant (~15 seconds compared to <5). This could be due to the fact that the probe is floating, so if this is too long we can very easily decrease the time to settle. More empirical testing may be required.
Fixes #33
Fixes #38
Also discovered that there is a way to default the
FileChooser
to the last opened directory automatically.Fixes #28
During testing, an "Unknown error" could be thrown by the PolledBno. This turned out to be a threading issue that was fixed by directly returning the results of context operations.
Fixes #50
Added a label to the editor that displays the version of liboni that is running.