changed instrument/channel behavior for writing midis. Added test case for converting a midi file to a project