Skip to content
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

Fix register mapping for Neuropixels 2.0 public probes #190

Merged
merged 3 commits into from
Aug 6, 2024
Merged

Conversation

jonnew
Copy link
Member

@jonnew jonnew commented Aug 3, 2024

  • Neuropixels 2.0 has a completely different register map compared to 2.0-beta. This is reflected in the changes in this commit.
  • Common static helper functions for 1.0, 2.0, and 2.0-beta were moved to BitHelper.cs and NeuropixelV2.cs

- Neuropixels 2.0 has a completely different register map compared to
  2.0-beta. This is reflected in the changes in this commit.
- Common static helper functions for 1.0, 2.0, and 2.0-beta were moved
to BitHelper.cs and NeuropixelV2.cs
@jonnew jonnew added this to the 0.1.0 milestone Aug 3, 2024
- It was left connected to the last probe configured which caused a huge
  amount of cross talk if i2c bus was used during acquisition
- Gain corrections were not used in NeuropixelsV1
- Gain corrections for NeuropixelsV2 were changed form fixed point multiplication to floating point since we are no longer doing this on an FPGA
Copy link
Collaborator

@glopesdev glopesdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jonnew This all looks great, were you able to get shift register OK checks with these changes?

@jonnew
Copy link
Member Author

jonnew commented Aug 5, 2024

Its hard to know with 100 percent certainty, due the lack of proper Neuropixels documentation in general and unavailability of their API source code (even though its supposed to be open source given the terms of IMECs contract) that everything is functional but course tests with Jakob reveal that we are definitely shifting electrode positions etc.

@jvoigts when you program your probes with the package I sent you, do you see text appearing in the console window regarding failure of SR checks?

@jonnew
Copy link
Member Author

jonnew commented Aug 5, 2024

Side note: I changed the SR check reporting level from raising an exception to printing to the Error stream. The reason is because on multishank probes the users should be able to use a probe even if one shank is broken.

@glopesdev
Copy link
Collaborator

I think this is totally reasonable and appropriate, especially given the current state of the integration, we can update this once we get certainty.

@jonnew
Copy link
Member Author

jonnew commented Aug 5, 2024

Yeah to be honest there are a lot of systematic issues I would like to go over that relate to shared state between devices that use passthrough and the way that gain corrections are handled here, which I think is pretty bad: declare as nullable double, use if sn detected and cast to double just feels gross.

@jvoigts
Copy link
Member

jvoigts commented Aug 6, 2024

I'll have time to debug this some more next week. I dont think I'm seeing any SR check errors but I have not verified that the channel map is behaving as expected.

@jonnew jonnew merged commit 62aa90b into main Aug 6, 2024
5 checks passed
@jonnew jonnew deleted the issue-186 branch August 6, 2024 16:45
@jonnew
Copy link
Member Author

jonnew commented Aug 24, 2024

@jvoigts When you use the library with np2.0 probes, please let me know so I can verify the SR programming is working for the whole probe

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants