Amateur in trouble with GP1A57HRJ00F photo interrupter

For the discussion of Arduino related topics.

Moderator: phalanx

Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby Donkey » Sat Apr 21, 2012 12:55 pm

Hi guys,

I bought a GP1A57HRJ00F photo interrupter and now I want to connect it to my Arduino, but my problem is that I didn’t buy the breakout board (BOB-09322) which makes it hard for me to figure out how to connect this the right way to the arduino since I can’t read data sheets, and I kind of need to do it till Monday for a small project. So if one of you has one of these and maybe could show me a picture of how you connected it on a breadboard and to the Arduino, something very simple, I will be very thank full, as I am an amateur at this…

Best regards,
The Donkey
Donkey
 
Posts: 1
Joined: Sat Apr 21, 2012 12:20 pm

Re: Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby fll-freak » Wed May 02, 2012 7:34 am

If you plan on doing electronics, you need to learn to read a data sheet. You can find it here: http://www.sparkfun.com/datasheets/Comp ... HRJ00F.pdf
You can find a tutorial on how to read a datasheet in the Sparkfun tutorial section.

On page two you will see the internal schematic. One set of pins if for the LED and the other for the transistor used as a switch.

Pin 1 will go to 5V.
Pin 2 will go to a resistor.
The other end of that resistor goes to ground.
From the table on page 4, you will see the forward voltage is about 1.14V at 7ma. That means the resistor need to be (5-1.14)/(.007) or 551 ohms. But since the LED can go up to as much as 50ma a standard 330 ohm resistor should do just fine.

Now the transistor side is even simpler.
Pin 3 goes to 5V
Pin 5 goes to ground
Pin 4 goes to a digital input pin on the Arduino.

Edit: Deadline has come and gone and no reply from OP. Why does this continue to surprise me...?
Edit: Any news on this? I hate threads that just end without resolution...
fll-freak
 
Posts: 1507
Joined: Tue May 12, 2009 8:23 am
Location: New Hampshire, USA

Re: Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby Philba » Wed May 02, 2012 9:49 am

maybe he got some one to do his class assignment for him.
Philba
 
Posts: 2503
Joined: Sun Feb 13, 2005 11:33 pm
Location: Seattle

Re: Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby armaan » Wed Sep 04, 2013 7:26 pm

Hey, just wanted to pop on and thank you fil-freak writing this post. Perhaps OP didn't get anything out of it, but as someone new to reading datasheets, I found it useful. :-)
armaan
 
Posts: 1
Joined: Wed Sep 04, 2013 7:24 pm

Re: Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby fll-freak » Thu Sep 05, 2013 12:18 pm

Glad someone did. Sometimes I think I write these answers for my own amusement. Now at least I know someone else got something out of my labor.
fll-freak
 
Posts: 1507
Joined: Tue May 12, 2009 8:23 am
Location: New Hampshire, USA

Re: Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby mp88 » Thu Jan 23, 2014 12:48 pm

Hey fll, so ive got a project that requires me to design a linear slide that can go to a position, wait for a few seconds and return to its original location. To make it simple, I decided to go with a belt driven IGUS linear slide using a stepper. I want to use the photo interrupter mentioned as a limit switch for the two locations I need to slide to go and from. I've got both the stepper and photo interrupter working independently using Arduino UNO but I am having difficulty coding the combination. Any coding tips...or atleast a starting point?

Thanks,
Matt
mp88
 
Posts: 1
Joined: Thu Jan 23, 2014 12:35 pm

Re: Amateur in trouble with GP1A57HRJ00F photo interrupter

Postby Mee_n_Mac » Sat Jan 25, 2014 1:21 pm

Post your code(s).

{click on below)
CodeButtonTags.jpg
Mee_n_Mac
 
Posts: 4328
Joined: Thu Apr 28, 2011 4:10 pm


Return to Arduino

Who is online

Users browsing this forum: No registered users and 5 guests