updated for latest version of libpd, plus MIDI support