As we see, Led is connected between two pins of microcontroller, GP0 and GP1 (it can be any pins). If GP0 = 1, and GP1 = 0 then Led is ON (that is a normal situation). If we change state so that GP0 = 0, and GP1 = 1, then Led has inverse voltage and it is OFF (that is also normal). But if we put GP1 after this state to high-z state and measure the time until GP1 came to zero state, we will take different result for different level of ambient light. Short falling time = more ambient light.
I think that you may not use Led in some special device for measuring ambient light, but it is interesting to use that Led-sensor in some simple and not commercial application.
Here is a sample code – Led Sensor.bas. When you turn on this device, Led is off (it must be daylight), but when you make a shadow around Led, it will begin to shine!
I think that I changed your thinking about Led, as we gave a new way of use.
You can download the hex file here:
Led Sensor.hex