This is related to a bug in REAPER with respect to MIDI device name encoding. I should work around it.