A few months ago NASA lost contact with the Mars Global Surveyor orbiter. The mission was by far the most successful Red Planet focused mission: it took photos proving the existence of water on Mars; it surveyed the climatic changes for over 3 Mars years (the mission lasted four times longer than projected); it took the first photos of Earth viewed from Mars and of other two Mars orbiters (ESA's Mars Express and NASA's Mars Odyssey).
A NASA board investigated the communication failure which was tracked back to a loss of power. This is supposed to have been caused by a faulty orientation of the spacecraft which exposed one of the batteries to direct sunlight. The battery overheated and ultimately led to the depletion of both batteries. The funny thing about this is that the cause of the misplacement was traced back to a computer error made five months before the actual thing happened.
More on this subject...
photo credit: aritst view, NASA/JPL-Caltech
Tech details: From NASA's website: "The solar arrays, which always point toward the Sun (when the spacecraft isn't behind the planet), provide 980 watts of electricity for operating the electronic equipment and for charging nickel hydrogen batteries." Thermal blankets were used to protect sensitive parts. Nickel hydrogen batteries are used in many missions, including ISS and modern geostationary satellites. They have a current cycle life of 4000 to 10,000 cycles at 60 percent DOD, which doesn't recommend them for LEO (>30000 cycles). Provided power: >1kW, modern versions being expected to provide >6kW. The MGS batteries were based on 20 Ah 2-Cell common pressure vessel (CPV) technology.