please note that for simplification iv only drawn 2 "sensor things" which provide two outputs D0 and D1 in this diagram, however in the real circuit there are 8, and which range from D0 to D7.
ok heres the purpose of this circuit. threre is an IR transmitter and IR modulated reciever, which drives the IR transmitter. I am using this circuit on a robot to detect objects that the robot may collide into..... i therfore, bounce the IR signal off a wall for example, then it is recieved at the receiever.
When the IR signal is recieved by the reciever, the reciever gives out a "**LOW**" output at its Pin.2. When it ISNT recieving the IR signal it is giving out a *HIGH* at Pin 2.
The normal LED which is circled in green, lights up when pin 2 is low, this is because pin 2 is low, but the other end is 12V, therefore current flows and the LED lights up. When pin2 gives out a high, i.e 12V, because the other end is 12V and ther is no potential difference, no current flows, therefore, the LED doesnt light up.
Now, when i dont connect Pin2...... i.e the wires D0 and D1 to the PIC, this circuit works PERFECTLY. When nothing is detected, Pin 2 gives out a HIGH and the LED isnt on.. and if it detects something, Pin2 goes low and the LED comes on.
The problem..... As SOON as i connect D0 and D1 to the PIC, or emulation board the problem starts. When nothing is detected, all LEDs are off, however, if ONE reciever detects something, and it makes the LED light up, EVERY single LED lights up, not just that one!
Does anybody know what could be causing this problem?? remember, when i dont connect D0 and D1 to the pic, the sensors and LEDs work perfectly and light up when they are supposed to.
any help would be REALLY appreciated... im going mad over this
thanks
ok heres the purpose of this circuit. threre is an IR transmitter and IR modulated reciever, which drives the IR transmitter. I am using this circuit on a robot to detect objects that the robot may collide into..... i therfore, bounce the IR signal off a wall for example, then it is recieved at the receiever.
When the IR signal is recieved by the reciever, the reciever gives out a "**LOW**" output at its Pin.2. When it ISNT recieving the IR signal it is giving out a *HIGH* at Pin 2.
The normal LED which is circled in green, lights up when pin 2 is low, this is because pin 2 is low, but the other end is 12V, therefore current flows and the LED lights up. When pin2 gives out a high, i.e 12V, because the other end is 12V and ther is no potential difference, no current flows, therefore, the LED doesnt light up.
Now, when i dont connect Pin2...... i.e the wires D0 and D1 to the PIC, this circuit works PERFECTLY. When nothing is detected, Pin 2 gives out a HIGH and the LED isnt on.. and if it detects something, Pin2 goes low and the LED comes on.
The problem..... As SOON as i connect D0 and D1 to the PIC, or emulation board the problem starts. When nothing is detected, all LEDs are off, however, if ONE reciever detects something, and it makes the LED light up, EVERY single LED lights up, not just that one!
Does anybody know what could be causing this problem?? remember, when i dont connect D0 and D1 to the pic, the sensors and LEDs work perfectly and light up when they are supposed to.
any help would be REALLY appreciated... im going mad over this
thanks