Shop OBEX P1 Docs P2 Docs Learn Events
Door entry program? — Parallax Forums

Door entry program?

clovatoclovato Posts: 3
edited 2007-03-09 14:35 in BASIC Stamp
Has anyone written a program that can detect people moving into a room, turn a light on if people are in the room and then detect people leaving the room and if the number of people in the room becomes 0 turn the light off?
We are having trouble working out the entire thing. We made a flowchart. We have written a program but it appears not to function as we expected it to.
Any already written programs out there we can look at to get some ideas?
·

Comments

  • allanlane5allanlane5 Posts: 3,815
    edited 2007-03-08 20:42
    You could use a 'ping' sensor to 'scan' the room.

    You could also use a 'PIR' sensor to detect the IR of the people in the room -- that's the more classic approach.
  • clovatoclovato Posts: 3
    edited 2007-03-08 21:24
    We will look at that thanks.
  • Bruce BatesBruce Bates Posts: 3,045
    edited 2007-03-08 22:14
    There are commercial products called occupancy detectors which will do what you want if this is not just a "fun" or learning project. They're a lot less expensive than using a microcontroller.

    Regards,

    Bruce Bates

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
  • clovatoclovato Posts: 3
    edited 2007-03-09 14:35
    Hello,
    This is a learning project for two of my 8th grade students. We used GW Basic last year and they did very well, but the Basic Stamp has them somewhat puzzled.
    I would really like to see the coding for such a system so I could stear them in the right direction.
Sign In or Register to comment.