Reading a sensor without powering it?

Hello there!

So recently i was using my infrared sensors for line following, and i noticed i was getting readings from the sensor that were higher than usual but still there was a noticeable difference between white and black through the sensor readings... they just seemed to be scaled up.

Then i realized the sensors were not fully plugged into my arduino, i mean the ground and signal were plugged in normally but the power line was not....And i was still getting readings from the sensor...

How is this possible? Is this normal or ....

If someone could explain what might be happeining that would be great.

Thank you!

Without the model (and link) of the sensor we would be guessing. Also a drawing of how it is connected would help.

Weedpharma

This is the model SparkFun Line Sensor Breakout - QRE1113 (Digital) - ROB-09454 - SparkFun Electronics

This is how it is hooked up and coded:

http://garagelab.com/profiles/blogs/tutorial-line-sensor-with-arduino

but without the connection to power

You are not powering the LED, but the phototransistor is powered by the output pin during the read cycle.

And the sensor is reading reflection from ambient lighting.

Weedpharma