Photo resistor GP1A57HRJ00F

I have melted 5 out of the 6 photo interrupters that I purchased as a replacement. The first one was using the breakout board that came from sparkfun. I can verify that things were plugged into the right terminals as the photo-transistor has 3 terminals and the LED has 2 terminals, so its not like I can wire it backwards. The next thing I tried as using a bread board. The breadboard worked, I can attach videos if needed. The next step was to remove the bread board and wire everything directly, which fried the transistor. I did this again to see if it was just a minor issue with the terminals touching or something, but they melted again. I’m only powering it with an arduino. I only have 1 left and I dont have time to order more before the project is finished. How do I wire this without blowing it.

If you’re melting these, you’re connecting them the wrong way.

Can you provide photos of your setup and a schematic diagram that show your connections? We may be able to spot the issue from those.

I tried to upload the video here directly but without youtube compression its over 200Mb. So I provided a link. In the video I misspoke and meant to say the output pin doesn’t draw enough power to power the whole system. I know this because when I plugged in power, the sensor gives off a digital one by default. Which is why I switched them around so much.

https://www.youtube.com/watch?v=DI-GF9HGzDo

https://www.sparkfun.com/datasheets/Com … HRJ00F.pdf

https://cdn.sparkfun.com/datasheets/Sen … ut-2.2.pdf

I based my circuit off of these diagrams, I suspect that the transistor is labeled backwards which is why I’ve been blowing it.

It’s hard to tell from your video what wire goes where, but if red is positive and black is negative, you have the photo transistor hooked up backwards. That’s likely causing an excessive amount of current to flow and burn out the photo transistor.

The transistor isn’t labeled backwards, I think you’re looking at the bottom view and swapping pins 3 and 5. (Red text are my edits)

When you’re trying a new part like this and it’s not working or burning up the first go around, double check your connections to make sure you have everything the right way around. Before trying a replacement part, it would be wise to pop a 1K resistor in series with the part just to limit current in case something isn’t right. That will prevent you from burning out another part if you have it connected wrong.

Don’t rely on the Arduino to limit current! 40mA is the maximum you’re supposed to pull from a IO pin, not what the Arduino will actually deliver. Some microcontrollers will happily deliver more current than specified as a maximum and that damages the part you’re powering and the microcontroller. (Sometimes killing both.) If you’re unsure, just pop a series resistor in line to limit current just in case you have something wrong. That will save you from killing a part and possibly other pieces in your project. In the diagram below I’ve added a 1K resistor as a safety to protect the part just in case you have connected it wrong. Once you’re happy things are functioning correctly you can omit it.

Capture2.jpg

It sucks to learn the hard way, but it’s also helpful that you will remember what you’ve learned. Keep at it and don’t get discouraged!