Hi, I have successfully restored one of my keys that was dead when I bought my 2004 X5. I followed the instructions from the following link, including sourcing the replacement battery, and it works perfectly now. No special tools needed really.....
Here's the link:
replacing battery in key fob.... - E46Fanatics