LESSON 05. Photoresistor


Connecting an photoresistor to a micro:bit

Photoresistor is a kind of special resistance based on internal photoelectric effect. Its resistant value is opposite to the brightness of light. Brighter light leads to lower resistant value. Usually photoresistor is the core component of a photoswitch. In the following experiment, we are going to use photoresistor to control the brightness of 5*5 LED screen on micro:bit.


What you will need





2 × SOKIT CONNECTOR "I" 16cm

  • 1 × micro:bit SOKIT (BBC micro:bit + SOKIT Pad)

  • 1 × Micro USB cable

  • 1 × Photoresistor Module

  • 1 × Resistor Module

  • 2 × SOKIT CONNECTOR "I" 16cm

  • 1 × SOKIT CONNECTOR "Y"

Hardware Connect​


Programming

You can see the whole program in the page below. Click “Edit” on the right top corner, and then “download”, you can download your code into Micro:bit.


VIDEO