The day after I returned from SteamCon in Seattle I got into the car to go to the day job and discovered that my battery light was on in my 2007 Toyota Yaris. Being an old Volkswagen man I resisted the urge to get out and hammer on the the alternator with a monkey wrench. Instead I turned everything off and then listened carefully to the engine RPM as I turned on the rear window defroster. When I pressed the defrost button the engines revs did indeed drop about 100 and the engine lugged for a moment until the ECU gave it a bit more gas to smooth out the idle. Good. This exercise told me that the alternator was charging the battery and that the problem was with the warning light itself. I could safely drive the car for the rest of the week and figure things out at my leisure.
This morning I started working the problem . . . by googling "toyota yaris battery light comes on" which lead me to this Technical Service Bulletin EL002-07 Charging System Warning Light "on" . I removed the alternator from the car and disassembled it as per the TSB and discovered corrosion exactly as described. The suggested action was to replace the regulator assembly but, radical makerpunk that I am, I decided to repair it.
Only, it din't need repair. I cleaned it up and scraped away all of the corrosion expecting to find bad connections that I could solder or otherwise fix. Only there was no sign of any problem beyond the surface corrosion on what appeared to be contacts exposed to facilitate testing of the regulator during the manufacturing process.
I quickly came to the conclusion that the battery light was coming on due to conduction between these two test points caused by the build-up of dirt on the surface of the regulator.
So, Toyota's suggested process for re-mediating a problem caused by a design flaw introduced to facilitate their manufacturing process is to sell you a replacement for a part that simply needs to be cleaned? Screw that!
I scraped out the corrosion with a sharp pick, and cleaned up the regulator with a stiff brush and some dish detergent and then filled the holes that were the culprit with some RTV to keep them from collecting the troublesome dirt. I re-assembled the alternator and put it back in the car. It started right up and no battery light! Total repair time was about an hour.