convert a midifile into a csvfile