Skip to content

Conversation

@cjsha
Copy link
Member

@cjsha cjsha commented Oct 30, 2025

Fix #286 Fix #287

@cjsha cjsha requested review from bparks13 and jonnew October 30, 2025 20:06
@bparks13
Copy link
Member

@cjsha couple things I noticed;

  1. Issue 236 was closed a while ago, did you mean to say this fixes Document GPOTrigger #286?
  2. There is an open PR to fix Broken link in api/overview.md #280 (Fix broken link to InterPulseInterval property #283)
  3. It looks like the submodule might not be pointing to the correct commit, the build failed saying the workflow has unknown types

@cjsha cjsha changed the base branch from main to issue-272 October 30, 2025 20:36
@cjsha
Copy link
Member Author

cjsha commented Oct 30, 2025

  1. Issue 236 was closed a while ago, did you mean to say this fixes Document GPOTrigger #286?
  2. There is an open PR to fix Broken link in api/overview.md #280 (Fix broken link to InterPulseInterval property #283)
  3. It looks like the submodule might not be pointing to the correct commit, the build failed saying the workflow has unknown types
  1. yea, fixed
  2. oh oops. I merged that PR into issue-272 and rebased this PR on issue-272.
  3. Thanks for noting that. To run it on my hardware (hs64 0.4), I merged issue-502-2 into main in the bonsai-onix1 repo. I recommend doing this to test this branch.

Copy link
Member

@bparks13 bparks13 left a comment

Choose a reason for hiding this comment

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

It's looking really good! I've got a few more comments, but once those are addressed I am ready to merge.

Also:
- Add dotnet xrefmap in docfx.json so I can use `<xref:System.Double>`.
- Remove include for now, the long-term solution will be to add a template.
- Remove `Condition` operator from Headstage64GpoTrigger branch
  This node's unnecessary bc only True values trigger stimulus anyway.
@cjsha
Copy link
Member Author

cjsha commented Nov 3, 2025

Note to self: make sure the stimuli waveforms have reasonable parameters.

@cjsha
Copy link
Member Author

cjsha commented Nov 3, 2025

Note to self: make sure there is note about 0.7.0 doesn't support hs 64 firmware version <0.4

Copy link
Member

@bparks13 bparks13 left a comment

Choose a reason for hiding this comment

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

I like the changes! I see some other comments, so I won't merge this, but feel free to merge it if we want to address the comments in other PRs

Copy link
Member

@jonnew jonnew left a comment

Choose a reason for hiding this comment

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

A few comments. Looks good.

<onix1:DeviceAddress>256</onix1:DeviceAddress>
<onix1:Enable>true</onix1:Enable>
<onix1:DspCutoff>Off</onix1:DspCutoff>
<onix1:DspCutoff>Dsp146mHz</onix1:DspCutoff>
Copy link
Member

Choose a reason for hiding this comment

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

I think we should leave the DSP off for these workflows.

Copy link
Member Author

Choose a reason for hiding this comment

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

Is it worth changing the default value in the node too?

        public Rhd2164DspCutoff DspCutoff { get; set; } = Rhd2164DspCutoff.Dsp146mHz;

https://github.com/open-ephys/bonsai-onix1/blob/7fb9332eb67c111a894de5ecaddbe63def120562/OpenEphys.Onix1/ConfigureRhd2164.cs#L55

If so, I can spawn an issue in the bonsai-onix1 repo before resolving this.

operator, the enumerated values appear in the `HasFlags`'s `Value` property's dropdown menu. Because `HasFlags`'s
`Value` is set to "Circle", its output is "True" when the selected `BreakoutButtonState` bit field contains the
"Circle" flag.
<xref:OpenEphys.Onix1.BreakoutButtonState> is selected from the
Copy link
Member

Choose a reason for hiding this comment

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

This link should be [Buttons](xref:OpenEphys.Onix1.BreakoutButtonState)

"Circle" flag.
<xref:OpenEphys.Onix1.BreakoutButtonState> is selected from the
`DigitalInputDataFrame`. It is an enumerator with values that correspond to bit
positions of the breakout board's digital port. When this type is connected to a
Copy link
Member

Choose a reason for hiding this comment

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

I think this sentence can be simplified and we need to be careful when we use jargon (should we use it and is it used correctly). "type" is both not necessary and used incorrectly here.

Buttons is selected from the DigitalInputDataFrame and passed to a HasFlags operator, which filters the sequence based on the presence of particular button using the Value property's dropdown menu. In this case, HasFlags's Value is set to "Circle", so its
output is "True" when its input contains a "Circle" flag.

operator emits a <xref:System.Double> determined by `Double`'s `Value` property
whenever it receives an item in its input sequence. Each double in the input
sequence received by <xref:OpenEphys.Onix1.Headstage64OpticalStimulatorTrigger>
triggers an optical stimulus. The value of the double determines the delay
Copy link
Member

Choose a reason for hiding this comment

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

value of the double determines the delay in microseconds, executed on the hardware,

"Headstage64/Headstage64ElectricalStimulator". This links the
`Headstage64ElectricalStimulatorData` operator to the corresponding
configuration operator. Frames from this operators are saved to a file named
"estim_.csv" using a <xref:Bonsai.IO.CsvWriter>.
Copy link
Member

Choose a reason for hiding this comment

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

estim_<timestamp>.csv ?

- Automatically commutates the tether if there is a proper commutator connection.
- Applies electrical stimulation triggered by pressing the breakout board's △ key.
- Applies optical stimulation triggered by pressing the breakout board's ◯ key.
- Applies either electrical or optical stimulation (depending on which stimulators
Copy link
Member

Choose a reason for hiding this comment

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

Just armed, enable determines if they produce frames.

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.

Document e-stim and o-stim reports from hs64 Document GPOTrigger

4 participants