finish basic midi implementation