Skip to content

Hardware stays engaged for 30 seconds after workflow is stopped #401

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

Open
ChucklesOnGitHub opened this issue Jan 17, 2025 · 7 comments
Open
Assignees
Milestone

Comments

@ChucklesOnGitHub
Copy link
Member

I've encountered this several times while using a miniscope and while using only a breakout board.
After pressing stop, the visualizations shut down but the breakout board "Running" light continues to blink as during acquisition.
In the case of the miniscope, the blue LED continues to be on.
During this period, pressing Start throws a "Attempt to trigger an already triggered operation" error.
After a while of waiting without further action (can be 30ish seconds), acquisition finally stops as in the "Running" LED on the breakout stays on and the miniscope blue LED turns off.
See video here

Attached is the offending miniscope workflow
test_miniscope.zip

but even this simple breakout board one had this issue for me too:
Image

The system sometimes says "Failure to write to a stream or register" even though I've changed nothing from the previous run and I have to press Start again for it to work (without changing anything and the "Failure to write to a stream or register" does not reappear). This is quite frequent, I ignore the popup and try again.

Maybe this is just my system but I can't figure out how to correct it. This is on a fresh software I re-installed today.

@ChucklesOnGitHub
Copy link
Member Author

hi @jonnew have you been able to figure out what might be going on here?

@emilyjanedennis
Copy link

Hey Ceci we also have this issue with our board when we're using just the analog in for TTLs. It can take a few minutes for us

@jonnew
Copy link
Member

jonnew commented Feb 17, 2025

  • @emilyjanedennis Your issue may be addressed with Tie lifetime of oni.Context to that of ContextTask #409. However, to know for sure I can try to reproduce, can you share your workflow?

  • @ChucklesOnGitHub At least part of your issue is a result of something that is a problem from the users perspective, but actually is not a logical error or but in the code. It occurs because @ChucklesOnGitHub used this example workflow and removed the miniscope to test the breakout in isolation. In this case, the only device that was producing data was the heartbeat. Further, in that workflow, which must have been produced using a old version of the library, the heartbeat rate is set to to 10 Hz

    image

    It should be hardcoded to 100 (Hardcode ConfigureHeartbeat to enabled in ConfigureBreakoutBoard #359). Combined with the large ReadSize that was originally required for the Miniscope, the read buffer took very long to fill in order to allow the read_frame() call to return and hardware shut down to proceed. The real solution here is that the example workflows should use the updated versions of the ConfigureBreakoutBoard operator which has 100 Hz heartbeat hard coded.

@jonnew
Copy link
Member

jonnew commented Mar 3, 2025

@emilyjanedennis @ChucklesOnGitHub Have you all tried the latest release of the library? Has this helped the situation?

@jonnew
Copy link
Member

jonnew commented Apr 21, 2025

@ChucklesOnGitHub Can you give me an indication if this is fixed?

@jonnew jonnew added this to the 0.5.0 milestone Apr 21, 2025
@jonnew jonnew self-assigned this Apr 21, 2025
@ChucklesOnGitHub
Copy link
Member Author

We spoke about this back then. The fix worked for me and I haven't had significant use of the sytem nor received more user issue regarding this, so it seems resolved.

@emilyjanedennis
Copy link

emilyjanedennis commented Apr 23, 2025 via email

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

No branches or pull requests

3 participants