These are mostly identical changes as added to the non-52MHz
implementation with the exception of sample rate.
Signed-off-by: Thomas Tsou <ttsou@vt.edu>
This should make it slightly less frequent to segfault on exit.
Actually we should shutdown all our threads correctly, but that's a lot of work.
(cherry picked from commit 7cd65d3e5a717e0c224477cacfe932cfd7a45b8f)