TCRT5000 - faulty?
Moderators: grovkillen, Stuntteam, TD-er
TCRT5000 - faulty?
I just got to testing a TCRT5000 I bought a couple of weeks ago but i'm beginning to think that it's faulty...
I have connected gnd to gnd, vcc to 3,3v and DO to D7 (GPIO 13) on my Nodemcu V3.
No matter what I do I can't get it to change state. I have tested with mirrors just in front of the diodes, I have tried putting my fingers directly over both diodes etc and nothing happens. The only way I can get it to change state is to turn the adjustment screw but this is the ONLY way and even after adjusting I can't get it to change state no other way but to turn the screw backwards again. I have looked at the diodes with my phones camera and I see to light coming from the IR diode, shouldn't it be on constantly?
Could this be faulty or have I connected this wrong somehow? Is the voltage from my Nodemcu v3 to low? I have meassured 3.3v on the TCRT5000.
Any suggestions would be appreciated!
I have connected gnd to gnd, vcc to 3,3v and DO to D7 (GPIO 13) on my Nodemcu V3.
No matter what I do I can't get it to change state. I have tested with mirrors just in front of the diodes, I have tried putting my fingers directly over both diodes etc and nothing happens. The only way I can get it to change state is to turn the adjustment screw but this is the ONLY way and even after adjusting I can't get it to change state no other way but to turn the screw backwards again. I have looked at the diodes with my phones camera and I see to light coming from the IR diode, shouldn't it be on constantly?
Could this be faulty or have I connected this wrong somehow? Is the voltage from my Nodemcu v3 to low? I have meassured 3.3v on the TCRT5000.
Any suggestions would be appreciated!
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: TCRT5000 - faulty?
What's the incoming voltage level? A long wire might give a too weak signal back from the counter.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: TCRT5000 - faulty?
Have you used any resistors ?
The datasheet says the forward current through the diode is to be no larger than 60mA. With 3.3 V supply and an emmitter forward voltage of about 1V there should be a (3.3-1)/0,06 = 36 Ohms resistor in series with the diode. I would go for a little bit more, say 47 Ohms.
Otherwise one of these things may happen:
- you blow the IR diode (overcurrent)
- if your supply is weak you blow the voltage regulator on the nodemcu board or
- the supply voltage simply breaks down each time you try to drive/connect the diode.
Also make sure you have a pull-up resistor at the input as shown here:
https://cdn.instructables.com/FC2/G3QM/ ... MEDIUM.jpg
The datasheet says the forward current through the diode is to be no larger than 60mA. With 3.3 V supply and an emmitter forward voltage of about 1V there should be a (3.3-1)/0,06 = 36 Ohms resistor in series with the diode. I would go for a little bit more, say 47 Ohms.
Otherwise one of these things may happen:
- you blow the IR diode (overcurrent)
- if your supply is weak you blow the voltage regulator on the nodemcu board or
- the supply voltage simply breaks down each time you try to drive/connect the diode.
Also make sure you have a pull-up resistor at the input as shown here:
https://cdn.instructables.com/FC2/G3QM/ ... MEDIUM.jpg
Re: TCRT5000 - faulty?
Thanks for your quick replys.
I'm a bit confused. According to the wiki it seems that it's more or less plug and play with the TCRT5000. And since it has a control diode that shows if it detects the ir-signal or not I don't even have to connect the GPIO to test the function of the device.
Since I use the board to count IR-flashes for my electricity meter as well I'm sure the nodemcu board is fine. But perhaps I did blow the IR diode on the TCRT5000 since I didn't use any ressistor...?
And the incoming voltage is 3.303V.
,Olle
I'm a bit confused. According to the wiki it seems that it's more or less plug and play with the TCRT5000. And since it has a control diode that shows if it detects the ir-signal or not I don't even have to connect the GPIO to test the function of the device.
Since I use the board to count IR-flashes for my electricity meter as well I'm sure the nodemcu board is fine. But perhaps I did blow the IR diode on the TCRT5000 since I didn't use any ressistor...?
And the incoming voltage is 3.303V.
,Olle
Re: TCRT5000 - faulty?
which board are you refering to ? I was refering to the plain TCRT5000 as described in the data sheet.
As for your meter. Which type is it ? Does have a communication interface ? This is often a round window with a IR led in it which sends a burst of data every second or so.
As for your meter. Which type is it ? Does have a communication interface ? This is often a round window with a IR led in it which sends a burst of data every second or so.
Re: TCRT5000 - faulty?
I'm using the Nodemcu with a photoresistor that sends a swtich command for each IR blink and then sends this data in bursts to domoticz each minute.
Just to avoid confusion, this is the device I'm talking about:
https://www.aliexpress.com/item/Free-Sh ... 83ad75f1d1
,Olle
Just to avoid confusion, this is the device I'm talking about:
https://www.aliexpress.com/item/Free-Sh ... 83ad75f1d1
,Olle
Re: TCRT5000 - faulty?
allright, the pullup seems to be on the PCB already.
So, no data interface then? Just a IR pulse ?
What does your board do if you shine a flashlight on it ? Does the LED indicate this ?
So, no data interface then? Just a IR pulse ?
What does your board do if you shine a flashlight on it ? Does the LED indicate this ?
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: TCRT5000 - faulty?
I would cover the IR diode on the device or else the signal from the electric meter is lost in the noise.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: TCRT5000 - faulty?
For some clarification:
The TCRT5000 itself consists just of a IR LED and a photo transistor.
The little chip on the breakout board is a so called "Comparator", usually a LM393, LM358 or similiar.
The chip only does one thing: It takes the analog output from the photo transistor and forms the waveform into sqare wave.
The TCRT5000 is made for reading mechanical devices, the black mark on an old-fashioned electricity counter's disk
or the little wheel on a water counter.
For this the IR-LED has to be on permanently, the photo transistor takes up the changes from dark to reflecting and back.
Datasheet Sensor: http://www.vishay.com/docs/83760/tcrt5000.pdf
A similiar schematic: http://www.electrodragon.com/analog-and ... schematic/
The photo transistor is used best for the reflections of the IR-LED at a distance of around 2,5 mm.
If you want to read simple IR pulses ("x pulses per kWh" scheme) from a electricity meter you should disconnect the IR LED. As grovkillen said, the pulses will get lost otherwise.
The sensor should be placed near to the IR LED of the meter.
If your electricity meter sends data pulses (encoded power data) per IR i doubt if this sensor is suitable at all.
If your breakout board has an "AO" analog output, it shoud be possible to check if the sensor itself is broken.
Just check the voltage between AO and GND with a black and a white paper in front of the sensor.
Regards
Shardan
The TCRT5000 itself consists just of a IR LED and a photo transistor.
The little chip on the breakout board is a so called "Comparator", usually a LM393, LM358 or similiar.
The chip only does one thing: It takes the analog output from the photo transistor and forms the waveform into sqare wave.
The TCRT5000 is made for reading mechanical devices, the black mark on an old-fashioned electricity counter's disk
or the little wheel on a water counter.
For this the IR-LED has to be on permanently, the photo transistor takes up the changes from dark to reflecting and back.
Datasheet Sensor: http://www.vishay.com/docs/83760/tcrt5000.pdf
A similiar schematic: http://www.electrodragon.com/analog-and ... schematic/
The photo transistor is used best for the reflections of the IR-LED at a distance of around 2,5 mm.
If you want to read simple IR pulses ("x pulses per kWh" scheme) from a electricity meter you should disconnect the IR LED. As grovkillen said, the pulses will get lost otherwise.
The sensor should be placed near to the IR LED of the meter.
If your electricity meter sends data pulses (encoded power data) per IR i doubt if this sensor is suitable at all.
If your breakout board has an "AO" analog output, it shoud be possible to check if the sensor itself is broken.
Just check the voltage between AO and GND with a black and a white paper in front of the sensor.
Regards
Shardan
Regards
Shardan
Shardan
Re: TCRT5000 - faulty?
Thanks for all replys! I think I might have expressed myself a bit unclear.
I have a phototransistor connected to the same Nodemcu board that I connected the LM393 to. The reason for saying this is that I guess that this tells us that there's no problem with my Nodemcu board itself since the electricity meter function is working just fine.
BUT this has nothing to do with the LM393. I just connected it to see what it could do and perhaps use it as an alternative to a magnetic door switch. My problem is that it doesn't seem to work. No matter what I do: shine a light directly on it, put a mirror directly in front of the diodes or put my fingers around the two diodes. Nothing gives me a reading (I can see this directly on the LM393 since it has a led that shines when it detects the ir reflection). I have looked at the IR diode through my camera and I can't detect any light at all - shouldn't this be on constantly?.
So my questions is: Have I connected this wrong somehow (GND > GND, VCC > 3V and DO to GPIO13), is the Nodemcu not strong enough to drive the LM393 or is there a good chance that it's actually faulty?
I have a phototransistor connected to the same Nodemcu board that I connected the LM393 to. The reason for saying this is that I guess that this tells us that there's no problem with my Nodemcu board itself since the electricity meter function is working just fine.
BUT this has nothing to do with the LM393. I just connected it to see what it could do and perhaps use it as an alternative to a magnetic door switch. My problem is that it doesn't seem to work. No matter what I do: shine a light directly on it, put a mirror directly in front of the diodes or put my fingers around the two diodes. Nothing gives me a reading (I can see this directly on the LM393 since it has a led that shines when it detects the ir reflection). I have looked at the IR diode through my camera and I can't detect any light at all - shouldn't this be on constantly?.
So my questions is: Have I connected this wrong somehow (GND > GND, VCC > 3V and DO to GPIO13), is the Nodemcu not strong enough to drive the LM393 or is there a good chance that it's actually faulty?
Re: TCRT5000 - faulty?
Yes, the LED should be "on" constantly.
There is no circuit driving the LED its just connected to power via a resistor.
I've just tested my module - the same one as you use.
LED is permanently on, it shows "on" if i get near with my finger.
Works with 5V and 3.3V, 3.3V is less sensitive as the IR LED is darker.
Seems that something is wrong with your sensor board.
Is the red LED on when powering the board?
Regards,
Shardan
There is no circuit driving the LED its just connected to power via a resistor.
I've just tested my module - the same one as you use.
LED is permanently on, it shows "on" if i get near with my finger.
Works with 5V and 3.3V, 3.3V is less sensitive as the IR LED is darker.
Seems that something is wrong with your sensor board.
Is the red LED on when powering the board?
Regards,
Shardan
Regards
Shardan
Shardan
- grovkillen
- Core team member
- Posts: 3621
- Joined: 19 Jan 2017, 12:56
- Location: Hudiksvall, Sweden
- Contact:
Re: TCRT5000 - faulty?
Also, have you tried to adjust the threshold by screwing on the potentiometer?
But as Shardan said, if the IR LED not shining the board seems to be malfunctioning.
But as Shardan said, if the IR LED not shining the board seems to be malfunctioning.
ESP Easy Flasher [flash tool and wifi setup at flash time]
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
ESP Easy Webdumper [easy screendumping of your units]
ESP Easy Netscan [find units]
Official shop: https://firstbyte.shop/
Sponsor ESP Easy, we need you
Re: TCRT5000 - faulty?
Yes, the power led on the LMA393 is on, although it's green on my version. I'm gonna test 5V power supply when I get the chance and have ordered a new sensor as well.
Adjusting the sensor doesn't work but if I adjust it far enough it goes to a state where it's always "on" and the second led lights up.
Thanks for all input!
Adjusting the sensor doesn't work but if I adjust it far enough it goes to a state where it's always "on" and the second led lights up.
Thanks for all input!
Who is online
Users browsing this forum: No registered users and 0 guests