I have written an app for iPhones and for the 4S I want to support screen mirroring of the application over AirPlay.
Using the System AirPlay picker the and with Mir
The only way to programmatically enable mirroring is to use private APIs. See here
I am pretty sure mirroring can only be enabled from the system supplied menu in the multitasking bar.