Here are my settings for the M-Audio pedals.
Sustain - Plugged into the Sustain socket, with the switch set to 1 on the pedal.
The PX Global setting 27 (Sustain Polarity) can be left at "normal".
Expression - Plugged into the Pedal/CV socket, with the switch set to 'other' and turned the level adjuster fully anti-clockwise on the pedal.
The PX setting 25 (Pedal/CV Mode) can be set to 'Foot CC4'.
Mod matrix has a dedicated slot for 'Foot', which I have tried mapping to 'EnvVCA Att' with value -50 to give a 'mute' effect on fast attacking sounds, like piano.
My friendly piano player finds this gives a lot more expression to her recordings!