Refractor proposal #155
QuantumEntangledAndy
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I was thinking about the current way we issue command to the camera because I found it difficult just to add another stream on one login (maybe my lack of rust-fu). Was thinking of how we could generalise the login and adding of tasks for a camera and thought of this pseudo code.
Task
should be a trait withbring_up
,poll
andtear_down
all of which return the Status::Complete/Running/Error.The
camera.run_task
should be a templated function that runsbring_up
then loopspoll
until Status::Complete then runstear_down
on another thread.Providing my rust-fu can make this happen what do you think about making this a PR?
Beta Was this translation helpful? Give feedback.
All reactions