Not sure if this has been covered before; I don't recall reading about it, so may be of interest to someone.
I enabled coming home and leaving home lights using VCDS. I never got around to installing the earth wire to the CE module.
The results are:-
Leaving home lights come on when the car is unlocked using the key fob.
Coming home lights come on if the main beams are flashed after the ignition is switched off and before the key is removed, headlights come on when drivers door is opened.My car is a 57 plate Sline SB with halogen lights.