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

Expose software trigger to snap frames #98

Merged
merged 4 commits into from
Nov 20, 2023

Conversation

andy-sweet
Copy link
Contributor

@andy-sweet andy-sweet commented Oct 13, 2023

This functionality is already available in the C API. This PR simply exposes it in the Python API and adds a basic test with a simulated camera to exercise it.

@andy-sweet andy-sweet marked this pull request as ready for review October 16, 2023 22:24
@andy-sweet
Copy link
Contributor Author

andy-sweet commented Oct 16, 2023

This is ready for review now.

The problem with the flakiness of the test was that doing

p.video[0].camera.settings.input_triggers.frame_start.enable = True
p.video[0].camera.settings.input_triggers.frame_start.line = 0
p.video[0].camera.settings.input_triggers.frame_start.edge = TriggerEdge.Rising

was having no effect on configuration, so triggering was not actually enabled and the test was relying on the exposure time and compute for timing.

Instead, I set the frame start trigger in its entirety with

p.video[0].camera.settings.input_triggers.frame_start = Trigger(enable=True, line=0, edge='Rising')

as in other Python tests.

@andy-sweet andy-sweet requested a review from aliddell November 16, 2023 17:04
@andy-sweet andy-sweet merged commit 8c9ddf7 into acquire-project:main Nov 20, 2023
20 checks passed
@andy-sweet andy-sweet deleted the software-trigger branch November 20, 2023 16:49
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.

2 participants