Extracted from the workshop manual, I thought this might be useful:
Effect of disconnection or total discharge of battery on electrical systems in the vehicle and the precautions to be taken. (MY2005-on)
Control unit memories
Values and faults stored in the control units can be deleted if the battery is disconnected or completely discharged. If possible, all fault memories should be checked and, if necessary, printed out before the battery is disconnected.
Supply voltage fault entry
The entry "supply voltage" may be stored in various control units if the battery has been completely discharged. Delete the "supply voltage" entry from the control units in question.
Ready status
In some countries (presently the U.S.A. and Canada), after disconnecting the battery, it is necessary to reach the Ready status by a test drive and/or by using the Porsche System Tester DME control module menu). If in doubt about this, contact the relevant importer.
DME control module
With all DME systems, the engine must run for several minutes before the engine control module can relearn the idle speed and mixture adaptation values! After disconnection of the power supply, the idle speed might change or fluctuate briefly until the throttle valve adjusting unit has been readapted.
The mixture adaptation is also lost.
After the battery is connected:
With the DME, it is necessary to carry out a learning and adaptation routine as described below:
Switch ignition on for 30 seconds without starting the engine.
Do not actuate accelerator pedal.
This completes the adaptation of the throttle valve adjusting unit.
Tyre pressure monitoring system
When the battery is disconnected and connected, the tyre pressure is first displayed as "- - - ".
Once the battery has been disconnected and work is complete, the vehicle must be driven for a short distance.The actual pressures will then be displayed again.
Steering angle sensor (PSM)
The steering angle sensor must be re-initialised when the battery is disconnected and connected.
Turn wheels to straight-ahead position.
Switch ignition off and then on again twice.
Start engine.
From the straight-ahead position, turn steering wheel approx. 20° to the right, past the straight-ahead position.
Drive the vehicle straight ahead for at least one second at a speed above 4 km/h (2.5 mph).
The steering angle sensor segment is recognised again in this process.
Once the sensor has been successfully initialised, the fault code that is stored in the fault memory is documented using the fault deletion counter.
The fault memory erases itself automatically.
The PSM indicator light in the instrument cluster goes out.
Power windows
The end positions of the power windows are deleted from the control unit when the battery is disconnected and connected.
Perform the following procedure for all power windows:
Actuate rocker switch and fully close window once.
Actuate rocker switch once more to close.
The upper end position of the window is stored.
Actuate rocker switch and fully open window once.
Actuate rocker switch once more to open.
The lower end position of the window is stored.
Instrument cluster
Clock
The time is deleted when the power supply is disconnected.
Press clock control button approx. 1 second on instrument cluster. Hour display flashes.
Press clock control button in the corresponding direction. Hours can be adjusted.
Press the clock control button again, the minute display flashes and can be adjusted by turning the clock control button.
Trip odometer
The trip counter is set to 0 when the power supply is disconnected.
Airbag control module
If the battery is disconnected for less than 100 seconds when the ignition is switched on, a CAN time fault, which makes diagnosis of the airbag control unit impossible, may be stored in the airbag control unit.
The fault is erased by removing the ignition key.
On-board computer
Disconnection of the vehicle battery deletes the memories for average speed and average consumption. As a result, the displayed range on remaining fuel can be markedly different or even 0. The outside temperature display loses its memory effect. In other words, the indicated outside temperature can be too high due to the heat radiated when the vehicle is hot.
PCM
When the power supply is disconnected, the built-in GPS receiver loses the so-called almanac containing the satellite orbital paths.
Switch on PCM when there is a free panoramic view (load GPS almanac); the almanac is reloaded as soon as four satellites have been identifed.
The date and time are deleted when the battery is disconnected. The summer-/wintertime recognition feature is maintained. The time is lost and is updated again when there is a plausible GPS reception (four satellites).
The date and time are also adopted once the GPS almanac has been loaded; it may be necessary to change over to summer time (daylight-saving time). This time is transferred to the instrument cluster. If the time is then manually changed by means of the instrument cluster, this time is adopted by the PCM and synchronised with GPS time.
If the telephone card had been inserted and the telephone was ready for operation, the telephone is subsequently disabled (only if "Use last PIN" is deactivated).
The telephone is enabled again when the telephone PIN code is entered with the SIM telephone card inserted.
Test drive after disconnecting battery
Depending on the vehicle equipment fitted, all these work steps are carried out during the test drive.
Read out the fault memories of all control units after the test drive.
If there is a fault present, check to see if the fault was caused by an undervoltage.
If faults were caused by an undervoltage (or CAN timeout error), erase the fault memory, perform another test drive and read out the fault memory.
If faults were not caused by an undervoltage, correct the faults in accordance with GFF (Guided Fault Finding).