code working in OUTPUTMODE_REVERT_TO_MIDI. Unsure about the rest. switch scanning is a bit dodgy and therefore turned off.