Detecting classroom occupancy with IR

Discussion in 'The Projects Forum' started by elex09, Mar 18, 2010.

  1. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    hi

    im trying to implement a circuit for detecting occupancy in a clasroom using an IR led to transmit a beam..and once its interrupted(meaning that there is someone in class) the tsop1738 gives a signal to uC to keep the relay turned on so that supply continues..else if there is no interruption the uC gets a signal from tsop1738 to cut off the supply using a relay.
    Now i tried pressing a remote towards the tsop..also connected an LED to Vout of tsop..but led is blinking when i press the remote and not when remote isnt pressed..isn't that opposite to what tsop is supposed to do?
     
  2. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
  3. bertus

    Administrator

    Apr 5, 2008
    15,648
    2,346
  4. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    thanks for your replies..i did go thro the links but i want to implement it using a simple ir led..
    i am unable to move forward in my project as the transmitter itself isn't working satisfactorily....i am attaching the schematic of my ir transmitter..also i have connected a tsop1738 in the circuit but the output does not change due to the ir led..but changes when i press a remote towards it..and even then drop is just about 0.3-0.4 volts...
    can someone pls help me out ?[​IMG]
     
  5. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
    Are you getting anything out of the emitter? What voltage are you supplying it with?
     
  6. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    the ir led seems to be glowing..i checked it out on a camera...even the drop across the ir led is around 1.1V....and im using a 5V power supply with 7805 ic..
     
  7. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
    Your current is probably way to low to the IR led. If you want more distance, you will need to increase it.
     
  8. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    is there a need to connect a pull up at the output of the tsop (if yes could u pls suggest a value? is 4.7k enough) ...i have directly connected a current limiting resistor of 470 ohm to output of tsop and then an led to the other end of resitor to indicate status of tsop output..now the supply to tsop is 5V and output is as low as 1.75 but its irrespective of ir led..
     
  9. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    is there a way of connecting phototransistors to 8051 microcontroller?
     
  10. retched

    AAC Fanatic!

    Dec 5, 2009
    5,201
    312
    Do you have the IR LED datasheet of at least the part number?
     
  11. Markd77

    Senior Member

    Sep 7, 2009
    2,803
    594
    I've used a TSOP reciever. The current output is 5mA so shouldn't be used to power an LED. Also it is active low so you should expect logic high if no IR recieved.
    I'm guessing something is wrong with the transmitter circuit - wrong frequency or not enough power.
     
  12. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    hi
    im planning to implement a circuit using ir transmitter and receiver to detect occuapncy in a room.....if the infrared beams emitted are interrupted it means someone is present in the room and the tsop detects it and gives a logic low...this signal is given to microcontroller 8051 which then energizes the relay and keeps the supply ON....if beams are not interrupted it means noone is present and tsop1738 gives high signal which causes relay to open and cut the supply...

    my problem is that the ir led is glowing but the receiver is not behaving the way it should...it is not responding to the ir led...only responding to remote..pls help!

    [​IMG]
     
  13. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    hey thanks Markd77 for yr response...but can u please share yr tsop1738 receiver circuit diagram? did u use it for a similar application?
    i also wanted to know if the transmitter that im using how different is it from the remote transmitter circuitry? the tsop output falls from 4.9 to abt 4.5 volts when it receives the ir light from remote..but does not respond to ir led.
     
  14. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    can we connect a photransistor to detect the ir light..and if yes can a comparator be used with it to generate logic levels 1 and 0 to be used with microcontroller 8051??

    pls help..
     
  15. elex09

    Thread Starter Member

    Mar 17, 2010
    39
    0
    im now using a comparator ic to implement both transmitter and receiver...for a model having a distance of 30cm is it enough to use 2-3 ir LEDS...as i think it should cover the entire area..and i only need to detect if any 1 beam is interrupted or no.
     
Loading...