walid Posted March 21, 2007 Report Posted March 21, 2007 HiI built a circuit that when a person pass some red led illuminateThis signal is connected to a pic to count.The problem is that when that person pass, the led is Intermittent lighting glows irregular and weaken and boosted in a very short time The pic see that several persons How can stabilize it at 5 volts Thank you very much Quote
audioguru Posted March 22, 2007 Report Posted March 22, 2007 Hi Walid,You forgot to attach the schematic of the "person detector" that drives the LED.I think it uses a light sensor and a comparator. The comparator must have hysteresis for it to be a snap action very fast switch. Datasheets for comparators show that hysteresis is a small amount of positive feedback.Without hysteresis, the comparator reaches a condition where both inputs are at the same voltage then the comparator amplifies its own noise or it oscillates. Quote
walid Posted March 22, 2007 Author Report Posted March 22, 2007 Hi guruYes I forgot to attach the schematic of the "person detector" that drives the LEDThe schematic is attached below from: http://www.electronic-circuits-diagrams.com/alarmsimages/alarmsckt19.shtmlAs u see, it is a Tx and RxI used one IR LED and not twoI put the two units in front of each other and not beside as the designer saidMy module is on until some one pass so I replace the NPN transistor by PNP oneI did not use a relay, the emitter of PNP connected directly +9V and collector connected to a RED LED through a 680 ohm resistorThe main o/p is taken from the collector point to the picNow, I am not interested in pic (microcontroller)When I walk in between the two units and stop for a moment (This possibility can happen in practice ) the LED (and so the o/p) is Intermittent lighting glows irregular What can I do to change this o/p to be one short 5v pulseThank you guru very much Quote
audioguru Posted March 23, 2007 Report Posted March 23, 2007 Hi Walid,I think the very high supply current spikes from the 555 are interfering with the IR receiver.A 555 creates current spikes of 400mA on the power supply. The datasheet for an LM555 warns that the current spikes can affect other ICs on the same power supply and recommends using two supply bypass capacitors at the 555.The datasheet for the TSOP IR receiver shows a resistor that feeds it supply current which is missing in your circuit and is very important for it to avoid interference.The datasheet for the 7805 shows a capacitor at its input and another capacitor at its output.The circuit shows an NPN transistor that is being destroyed by high voltage spikes from the relay coil. The coil should have a diode across ir to arrest the spikes. Quote
elix Posted March 25, 2007 Report Posted March 25, 2007 that circuit needs some work, i'd trash it and start from scratch. Quote
elix Posted March 25, 2007 Report Posted March 25, 2007 sorry i should have said that differently, keep the ir diodes on without the 555, measure vo on the detector and make sure that you have the detector in a black tube away from outside light and you'll find the problem. you need a 2200uf cap in front of that regulator if your going to use a relay like that. Quote
audioguru Posted March 25, 2007 Report Posted March 25, 2007 The IR detector is tuned to about 40kHz and doesn't work if the IR is steady. The IR must be modulated at the same frequency as the IR receiver IC is tuned to. Quote
elix Posted March 25, 2007 Report Posted March 25, 2007 he wants to change how long the led stay so you need to calculate the rc time constant, put a on capacitor on vo+ to ground, it will determine how long the transistor stays on for, also when the .47uf cap is down to .6v it's going to cause intermittent operation (a series of rapid clicks at the relay) so it needs a high value resistor going from base to ground so that it has a sharp cutoff. Quote
walid Posted March 25, 2007 Author Report Posted March 25, 2007 Hi dear guruHi Walid,I think the very high supply current spikes from the 555 are interfering with the IR receiver.A 555 creates current spikes of 400mA on the power supply. The datasheet for an LM555 warns that the current spikes can affect other ICs on the same power supply and recommends using two supply bypass capacitors at the 555.The datasheet for the TSOP IR receiver shows a resistor that feeds it supply current which is missing in your circuit and is very important for it to avoid interference.The datasheet for the 7805 shows a capacitor at its input and another capacitor at its output.The circuit shows an NPN transistor that is being destroyed by high voltage spikes from the relay coil. The coil should have a diode across ir to arrest the spikes. you are absulutely trueYou are wonderful,you are the better man i have dealt with him in the electronics you our great teacher,thank you very much Yes, using two supply bypass capacitors at the 555 fixed the problemWhatever I said I will not be able to express my deep gratitude to you Quote
walid Posted March 25, 2007 Author Report Posted March 25, 2007 I am sorry I forgot to thank elix for his interest and involvement Thank you very much Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.