As long as you have the PCM on the CAN network (somewhere between the RoboRIO and the PDP with the termination resistor set to on), the compressor will just work - no coding it to turn on. The compressor and pressure switch attach directly to the PCM and it will control it all by itself. The most you will have to do is code your solenoids.
Check out
this article (under the Compressor section) for a bit more info on what changed this year to control pneumatics.