Technical description:
This is a very small light sensor. A photocell changes (also called a photodetector, photoresistor, CdS or photoconductive cell) resistance depending on the amount of light it is exposed to. As more light shines of the sensor’s head, the resistance between its two terminals decreases. These little sensors make great ambient light triggers (when a light in the room turns on, do something). They’re easy-to-use, and an essential component in projects that require ambient-light sensing.
Limitations:
Photocells only use resistance as a way to illustrate the luminosity which is not straightforward. If it gets darker, the resistance should go up. If it gets lighter, the resistance should go down. (see below)
To get a more accurate result, go to the digital light sensor.
Photocells are light-sensitive, variable resistors. To turn the photocell’s variable resistance into a readable voltage, we’ll combine it with a static resistor to create a voltage divider.
Resistor kit
Skill:
Core Skill: Electrical Prototyping
Skill Level: Noob
Sample Sensor:
Mini Photocell
https://www.sparkfun.com/products/9088?_ga=2.172429030.434451597.1551129096-109088928.1551129095&_gac=1.3998340.1551129096.EAIaIQobChMInZT4kubX4AIVmI3ICh3h3AdNEAAYASAAEgJgtvD_BwE
Sample Exercise and basic codes:
Example codes
https://learn.sparkfun.com/tutorials/photocell-hookup-guide?_ga=2.184362339.434451597.1551129096-109088928.1551129095&_gac=1.49623058.1551129096.EAIaIQobChMInZT4kubX4AIVmI3ICh3h3AdNEAAYASAAEgJgtvD_BwE#example-program