Let's Make Robots!

phototransistor problem

hi

 

I used to have my QRD1114 with a 10K pull-up resistor and everything was fine... but look I replaced it with IR emitter and IR receiver/phototransistor... I put a 12K pull-up to 5V on the collector, and between the collector and the resistor I get the signal... but I got only around 1.4 - 1.6 why?

 

Any simple ideeas?

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

schematic isn't hard

 

+-------------390R--------|>|-----------GND

 

+----------12K-----|-----\_/->----------GND

                  digital out

 

 

I use them in a triangular formation

 

Ptrans        Ptrans           Ptrans          Ptrans           Ptrans

            IR              IR                   IR                IR

 

lie this

 

this is in paralell, from regulated 5V 

Hmm. A schematic would help, but...

If I understand your setup, you expect a logical high near 5V when the phototransitor is off, because the input to the microcontroller signal will be pulled high by the pull up resistor when the phototransistor is completely off. If the phototransistor is completely on, you expect a logical low close to ground.

Assuming all this is correct, maybe you are partially saturating your phototransitor and it is a little bit on when you think it is completely off. If it is allowing current to flow it will drop the voltage.

How are your testing your on and off conditions? What is the ambient lighting? What are your trying to reflect the IR from the LED from? Is your phototransitor getting some bleedover from the IR LED even when nothing is in front of it? Try putting some shrink tubing or some other material to block any bleedover. Mouting your phototransistor slightly in front of the IR LED can also help prevent bleed over. See OddBot's post on the subject.