folks, i drive a non-vanos m50 e34 with air-cond in tropical malaysia. it is a manual car.

here's my problem:
1. with air-cond switch OFF, the engine rpm control is very smooth across the range including idle and drops quickly nicely when i take the foot off the accelerator.

2. with air-cond switched ON, the engine rpm takes a while (~0.5 - ~1s) to drop once i take my foot off the accelerator. also idle speed takes a while to settle down and sometimes swings to 1000rpm.

my question is:
1. how does the ecu controls rpm speed (idle etc) when the air-cond is ON?
2. what sensors/vacuum pipes etc are related to engine rpm control when air-cond compressor is ON?