refactor: moving code to capture.c
init capture after send

more consistent with MA mode
Guess driver while setting CI parameters.
Move callback retrieval to function.

Also fixes a bug where mixing drivers would cause only the last driver to be used.
Merge branch 'refactor_capture'

Break out functions and move lots of code to capture.c
refactor: move to subfunction