Read data and freq data from within a new thread