Working Principle : A Headlight sensor can be used to switch on/off the LED beam light of the car when there is darkness and tantamount light. LDR sensor will be used in this project to detect the intensity of light and acts as a variable capacitor. While we note the readings of it through the Bolt IoT module to cloud, we set off a threshold value for it should operate. When the value exceeds the threshold, the LED light should blink and fade away when the values precedes the threshold.
Connection of LDR:
step 1: Insert the leads of LDR into a breadboard.
step 2: connect a resistor of 10k ohms to one of the two leads.( Let this be lead1)
step 3: From the bolt wifi module, connect the 3v pin with the free end of the lead of LDR using a jumper wire.
step 4: Connect the lead1 pin to the A0 pin of the bolt wifi module with the help of a jumper wire.
step 5: From the GND pin of the module, connect a jumper wire to the free end of the 10k ohms resistor.
Connection of LED:
step 1: Insert the leads of LED into the breadboard.
step 2: Connect a 1k resitor to one end of the LED lead.
step 3: Connect the free node of LED to the Output pin(O) of the bolt wifi module.
Final Circuit Connection:
1.Breadboard connection
2. Bolt Module Connection:
Code Part:
Comments