comments and changes to mid_converter.pl