[vc_row][vc_column width=”1/1″][vc_tour][vc_tab title=”Module introduction” tab_id=”1393830389-1-56″][vc_column_text]Light intensity sensor is the main use of photosensitive resistance, the photosensitive resistance value vary linearly with the light intensity , So the size of the resistance value can reflect the size of the light intensity.
[/vc_column_text][/vc_tab][vc_tab title=”Accessories required for the experiment” tab_id=”1393830389-2-31″][vc_column_text]One Arduino UNO
One Light intensity sensor
Three Male to Female Dupont Line
Circuit connection as shown below:
[/vc_column_text][/vc_tab][vc_tab title=”Experimental code” tab_id=”1393830629717-2-8″][vc_column_text]
int sensorPin = A0;int ledPin = 13;int sensorValue = 0;void setup() { pinMode(ledPin, OUTPUT); Serial.begin(115200);}void loop() { sensorValue = analogRead(sensorPin); Serial.println(sensorValue); //Serial.write(sensorValue); digitalWrite(ledPin, HIGH); delay(100); digitalWrite(ledPin, LOW); delay(100); }[/vc_column_text][/vc_tab][vc_tab title=”The experimental results” tab_id=”1393830630875-3-6″][vc_column_text]When there is light
There is no light

Leave a Reply
You must be logged in to post a comment.