Added midi player helper function