Do I need to say anything more?
Launch jack and a2jmidid to bridge your ALSA midi ports to jack. Then connect in and out to the second port pair of your LaunchPad X.
Put the LaunchPad X into Programmer mode by long-pressing "Session", then pressing the red "Record Arm" button. Leave the menu by pressing "Session" again.
Alternatively, programmer mode is activated when any button is pressed on the launchpad.
Tap on the buttons to toggle cells dead/alive.