MIES icon indicating copy to clipboard operation
MIES copied to clipboard

Add FFI Functions for Clamp Control

Open MichaelHuth opened this issue 1 month ago • 2 comments

close #2547

MichaelHuth avatar Oct 30 '25 16:10 MichaelHuth

Let's do your usual appraoch here where Luke/Tim can test the FFI functions before we write the tests.

t-b avatar Oct 30 '25 19:10 t-b

If the current clamp mode for the headstage in MIES is different from the specific calmp mode of an amplifier setting (e.g. auto bridge balance that applies only to IC) then it is ignored by MIES.

MichaelHuth avatar Nov 03 '25 16:11 MichaelHuth

I gave this a try today:

  • I need a way to get the state of the clamp for any mode, not just the currently active mode. I suggest always returning all fields for both modes regardless of the current clamp mode (much simpler, but is there a cost to assembling these structures?). Alternatively, add a mode argument to FFI_GetClampState that can optionally be -1 to request the current mode.
  • missing GetHeadstageActive (or is there another way to get this?)
  • missing SetHoldingPotentialEnable and SetBiasCurrentEnable

campagnola avatar Dec 10 '25 00:12 campagnola

If the current clamp mode for the headstage in MIES is different from the specific calmp mode of an amplifier setting (e.g. auto bridge balance that applies only to IC) then it is ignored by MIES.

That makes sense for any of the TriggerAuto* functions, but all other parameters I would expect to be settable even when the mode is not active (for example, I should be able to set the auto bias parameters before switching to IC)

campagnola avatar Dec 10 '25 00:12 campagnola