I dont think this option requires any coding. Its simply an option with a Jailbrake app called DisplayOut.
It allows you to display whatever is on your iPhone, whether its email, texts, apps...anything. BUT...it is just a display, if you want to control the iphone you do it from the phone, which must be in the cradle.
Obviously this is less than ideal, but its still handy.
2013 X5 35i M Sport