uni-directional object counter circuit

Discussion in 'Digital Circuit Design' started by ahsan ali 3, Nov 14, 2017 at 11:14 AM.

  1. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    i have been given the project of uni-directional counter.......using logic gates................

    i have google it and found that all the circuit given there are bi-directional...... using ir sensor , 555 ic and decode counter for 70-segment...

    what i need is to make a circuit which only counts when someone gets it.... it should give "1" output when someone comes out of room....

    i have to make this using logic gates.... what comes in my mind is to use two ir sensors so one works if it gets output first............or something like that.......

    share your suggestions....

    upload_2017-11-14_21-14-13.png
     
  2. dl324

    AAC Fanatic!

    Mar 30, 2015
    5,239
    1,147
    Is this homework?
     
  3. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    dld project......
     
  4. dl324

    AAC Fanatic!

    Mar 30, 2015
    5,239
    1,147
    What does "dld" mean?

    Is this a school project for which you will receive a grade?
     
  5. Reloadron

    Well-Known Member

    Jan 15, 2015
    2,226
    963
    You need to better explain your project and if this is schoolwork you need to state it is so the thread can be relocated to where you will get help with this sort of assignment.

    When working with counters you need to get the terms correct. Counters can up count (increments) and down count (decrements). Counter basics go a long way. This sounds like you want a people counter circuit. Normally as a person enters a room the counter increments and if a person leaves the room the counter decrements. This provides a count of how many people are in a room at any given time. Anyway, you need to better explain your objective. A simple Google of People Counter Circuits will yield a dozen results.

    Ron
     
  6. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    yes this is a school project.................

    i need to construct a people counter which output "1" at seven segment display when someone enters into room..... and outputs nothing when someone comes out of the room.... or decrement in counted values using logic gates.
     
  7. absf

    Senior Member

    Dec 29, 2010
    1,705
    467
    How does the sensor know that you are leaving or entering?

    I think you need 2 sensors to do it. Let's call them Sensor A and Sensor B. They are placed 6 inches apart. If Sensor A is detected 0.5S before Sensor B, then someone is entering. And if Sensor B is detected before Sensor A, then someone is leaving... Does that make sense?

    Allen
     
  8. dendad

    Active Member

    Feb 20, 2016
    720
    177
    It will be better to use an Up/Down counter using quadrature counting technique. As mentioned above, you need 2 sensors. Otherwise some one can enter and get multiple counts if they rock back and forward in the beam.
    A quadrature counter will help limit this.
     
  9. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    yes i thought of this idea...... but could come up how to get output when A is "1" before B. and if B is "1"before A it should give direct 0 instead of decrement......... do it simple..... if some one enters it should gives 1 and if someones goes out, it shows not count and remains zero..... now what logic should be used here....... i tried but could now come up with desired outcome....
     
  10. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    i require to make it just count when someone enters otherwise zero in any condition....... now how could i do this
     
  11. Reloadron

    Well-Known Member

    Jan 15, 2015
    2,226
    963
    I suggested in post #5 you Google people counter circuits and provided a link. This is one of many popular circuits.
    People Counter.jpg

    I suggest you look at the photo sensors along with the gates and figure out how it works. Think about the sensor spacing and why the gates behave logically as they do. I am not going to explain circuit operation. I also suggest you look at other similar circuits. Looking at the photo cells or photo diodes and thinking about what they do is what it is all about.

    Ron
     
    absf likes this.
  12. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    beyond my sense
     
  13. Reloadron

    Well-Known Member

    Jan 15, 2015
    2,226
    963
    Then maybe you need to go back and understand how basic gates work as this stuff is not really very difficult. Ask your instructor for some help and mentoring,

    Ron
     
  14. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    look brother what i want is the counter only counts one when some one is coming inside......

    i am using two sensors ..... 2nd is some inches away from 1st...... know there are 4 possiblities......

    1::::
    upload_2017-11-15_20-20-59.png

    2:::::
    upload_2017-11-15_20-21-26.png

    3::::::::
    upload_2017-11-15_20-21-51.png

    4:::::::::
    upload_2017-11-15_20-22-12.png

    Now brother tell me is this correct..... the only situation which I require is the third when the 1st sensor get high output answer is high....
    means when any person passes through the the sensor 1..... it give 1 output other wise no output.....


    am i correct....
     
  15. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    brother check my above reply
     
  16. Reloadron

    Well-Known Member

    Jan 15, 2015
    2,226
    963
    I don't quite get why U3 is in there? Rather than aa AND you could use a NAND similar to the above but adding an inverting buffer is fine I guess and since you only want an UP count I guess what you have would work at a glance.

    Ron
     
  17. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    is there any other technical problem in it..... and how much far apart ,should i place the sensors......
     
  18. Reloadron

    Well-Known Member

    Jan 15, 2015
    2,226
    963
    The idea of the sensors is to detect direction of an object (person) going in or out. So the sensor spacing needs to be no greater than the with of a person. Most doing this exercise seem to choose 6 to 12 inches or 15 cm to 30 cm. You just want to trigger the leading sensor before the lagging sensor.

    Ron
     
    ahsan ali 3 likes this.
  19. absf

    Senior Member

    Dec 29, 2010
    1,705
    467
    The 7400 can be used as NOT gates but the AND gates cannot. So if you design your circuit with NOR chip, you won't need the inverter chip....

    cct_12.PNG

    So the rest is just experimenting with the distance of the 2 sensors. Do you just want to count people that are entering?

    Allen
     
    ahsan ali 3 likes this.
  20. ahsan ali 3

    Thread Starter New Member

    Aug 18, 2017
    19
    0
    thanks ....... for making more easy....


    yes i just want to calculate the people coming in......
     
Loading...