implemented channels with midi data, midi input handling, and atomic boolean to stop threads with user input.