Cadmium Sulfide Photocell (Light Sensor)
General Information
- What's a good source? They're pretty cheap.
Hooking up to the LogoChip
- Plug the sensor from the +V row to the middle section.
Hook the same column of the middle section to your LogoChip pin. (A red jumper is the right size.)
Plug a 100KΩ resistor from the same column to the ground (-V) row.
LogoChip Code
I have it plugged into pin A0.
print read-ad 0
The LogoChip console should print out a number in the upper hundreds, representing the brightness of the light falling on it. Brighter light should increase the number; dimmer light or shadow should decrease it.
How It Works
The photocell's resistance decreases when bright light shines on it. It's wired in a voltage-divider bridge like a potentiometer, with the photocell on top.
When the light is bright and the photocell's resistance decreases, the bridge voltage climbs. When the light is dim and the photocell's resistance increases, the bridge voltage drops.
