I've searched a lot to find out what does the pygame.midi.Input.read() returns.
In every documentation I found they say it's
[[status,data1,data2,data3],timestamp],...]
But what the hell is data1, data2, data3?
Someone, please explain what each list item's type and use in relation to MIDI data
The status and data bytes are specified in the MIDI specification. A short summery can also be found at Music - Midi - Status and Data Bytes.
In the Pygame documentation of
pygame.midi.readthe data structure of the return value is defined:Pygame uses the PortMidi (Platform Independent Library for MIDI I/O), where further documentation can be found.
There is also an example in the Pygame repository how to use the midi module: pygame/examples/midi.py
And there are some other StackOverflow questions related to this topic: