day 2
TRANSCRIPT
Day 2R-tist
INTRODUCTION OF SENSOR
WHAT IS SENSOR???
RGB LED
RGB
RED
GREEN
BLUE
D6
D3D5
Led pin configuration
How to identify IR Transister
See from top to both Led . You will see black spot on one led. On another one you will see grey spot. The led consisting of black spot is the
iR receiver (ir transister). Another one is ir emmiter. If you see only white spot then it is
normal led.
Circuit diagram or coulor detector sensor
Working process of ir sensor Ir sensor work on property of ir light that
ir light absorbed by black surface and totally reflected by white surface.
Ir led emit ir light which is reflected by surface is absorbed by ir transistor(ir receiver).
Ir receiver work on property that when light fall on an transister on his base emitter resion than its CE current increases due to emition of electron.
The ir receiver work on reverse biased.
LDR CONCEPT
Ldr work on the principle of that when light on the metal its resistance decreases.
Pin diagram of lm 324
Today’s program…..
Q-:Write a program to show 255x255x255 colour on RGB led…………?Q-: write a program to blink led using ir sensor if sensor value is 1 then it glow although it in dark …
Home work………….
Write a Program on variation of intensity of RGB using LDR sensor.
Program on variation of intensity of RGB using LDR sensor.
PROGRAM OF VARIATION RGB USING LDR
int sec1=3; int sec2=5; int sec3=6; int temp=A3; int sem;
void setup() { pinMode(3, OUTPUT); pinMode(5, OUTPUT); pinMode(6, OUTPUT); }
void loop() { sem` 1 21` =
analogRead(temp); analogWrite(3,sem); analogWrite(5,sem); analogWrite(6,sem); }
Any question…………..