added MultithreadedIO and reworked logic.