My A4 came with heated / electric mirrors as most do - however, our house has a narrow garage so i thought about installing the OEM power folding ones. It's a very easy DIY:
New door control modules for each side - part numbers
Drivers side: 8E2 959 802
Passenger side: 8E2 959 801
It seems modules with 'E' at the end will also work - but definately not ones with 'B' at the end.
You need a new mirror switch that has 4 positions - the 4th position is to turn them in.
New mirrors from an A4 or S4 with power folding function:
8E2 858 531 B or 8E2858531AC passenger side
8E2 858 532 J or 8E2858532AC drivers side
To fit them, remove both door cards, remove the speakers. The old control modules are 3 screws and pull off. replace with new ones. Once the speaker is out you can access the wire all the way through the door upto the mirror - uncrew the old mirror base and replace with new mirror and push cable down through door and into new control module.
WIth the door card off you can access the switch on teh armrest and unscrew and replace with the new one.
That's it - no wiring, no coding it just works!