Pages: [1]   Go Down
Author Topic: Is471Fe  (Read 865 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 31
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello,to evryone I have arduino from 2 days and I am like crazy at home.  smiley I have the above sensor IS471FE I wrote a code and it's work's well,but mine question to the audience is the following:
Is there a way to program the arduino and the sensor to activete the code I wan't in the smallest detect Ir light.(It's hard to explain  smiley-wink)
Logged

Greenwood, Indiana
Offline Offline
God Member
*****
Karma: 0
Posts: 508
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm not sure I understand. That is a sensor that will respond to a light source (LED) clocked off of pin 4 GL output. You an LED at 940 nanometers, an IR LED. You will need to connect the diode to the chip as shown in FIG 4 of the data sheet. You will need to run the V0 pin to the arduino. When the LED turns on with the GL output and there is nothing blocking the sensor V0 will respond. If there is something blocking it V0 will not respond. In this way you hae an optical switch.

V0 will be a LOW when the sensor detects the LED and a HIGH when blocked.

You must only use +5V to power this with the arduino. You need a 0.33uf capacitor at 5V and it seems a 280 ohm pullup on GL.

http://datasheet.octopart.com/IS471FE-Sharp-Microelectronics-datasheet-574864.pdf

« Last Edit: October 17, 2010, 09:17:33 am by mrmeval » Logged

If it was designed by man it can be repaired by man.

0
Offline Offline
Newbie
*
Karma: 0
Posts: 31
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Man I already did the schematic and write a code I just ask is there a way for more quick response,because sometimes the sensor don't detect fast the object and the platform smash it.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 31
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Anybody
Logged

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 634
Posts: 34518
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Man I already did the schematic and write a code
So man show us like.
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 31
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok that is the code:
Code:
const int sharpPin = 2;
const int sharpPin2 = 4;
const int ledPin =  13;
const int motorPin1 = 11;
const int motorPin2 = 10;

int sharpState = 0;  
int sharpState2 = 0;

void setup() {
  Serial.begin(9600);
  pinMode (motorPin1, OUTPUT);
  pinMode (motorPin2, OUTPUT);
  pinMode(ledPin, OUTPUT);      
  pinMode(sharpPin, INPUT);
  pinMode(sharpPin2, INPUT);  
}

void loop(){
  sharpState = digitalRead(sharpPin);
  sharpState2 = digitalRead(sharpPin2);

  if (sharpState == LOW) {
    analogWrite(motorPin2, LOW);    
    // turn LED on:    
    digitalWrite(ledPin, HIGH);  
    
  }
  else {
    delay(200);
    analogWrite(motorPin2, 100);
    // turn LED off:
    digitalWrite(ledPin, LOW);
  }
   if (sharpState2 == LOW) {
    digitalWrite (motorPin1, LOW);    
    // turn LED on:    
    digitalWrite(ledPin, HIGH);  
  }
  else {
    delay(200);
    analogWrite(motorPin1, 100);
    // turn LED off:
    digitalWrite(ledPin, LOW);
  }
}
Soon I will add l293 integral circuit,to control the motors in both directions.
Now the motors are controled via 2N3904 (work like a switch.)
Logged

Pages: [1]   Go Up
Jump to: