Go Down

Topic: Arduino connection with a beam-break sensor (Read 10775 times) previous topic - next topic

jbvidigal

Hi
I'm working on a project that needs to identify the amount of people in a room. I'm doing that by using 2 break-beam IR sensors.
I bought a DIY kit in maplin to see if it works. It was cheap and it seems it does. However, now I don't know how to connect ir to the Arduino!
The assemble sheet and the product site will have to come in the next post since this is my first question here!!!
Sorry!!!
Any suggestions for how to connect it to the arduino? I actually only need a high/low signal!

Thanks!

jbvidigal

The product site
http://www.velleman.eu/distributor/products/view/?id=342937

The assembly sheet
http://www.velleman.eu/downloads/0/manual_mk120.pdf

thanks


graynomad

#3
Aug 13, 2010, 03:44 pm Last Edit: Aug 13, 2010, 03:44 pm by graynomad Reason: 1
Remember that a simple beam breaker can't deal with two people entering/leaving at the same time or someone half entering then changing their mind.
Rob Gray aka the GRAYnomad www.robgray.com

jbvidigal

Ok... I should have said it in the first post... I'm an artist and electronics are not my super strong issue!
Where you have the schematics for the arduino board, you're just connecting the 5v and the ground right?
If so, 5v to + and ground to -?
This in the arduino. In the IR board... do you think I can connect it to the buzzer + and - or should it be anywhere else?

thanks

jbvidigal

The door I'm using is really narrow and it was selected exactly for that, so there's no way 2 people are passing at the same time through the beam! Thanks for the notice anyway!

PaulS

Quote
I'm working on a project that needs to identify the amount of people in a room.

The amount of people? By weight? By volume? By headcount?

The project you have proposed is not as simple as you describe. As has been mentioned, you need to account for people passing on their way in and out (the narrow opening might be sufficient in this regard), someone breaking the beam, but then backing out (two sensors positioned a sufficient distance apart would be needed), and the difference between entering and leaving (again, two sensors a sufficient distance apart will tell you direction). You'll also need to account for the difference between a person entering and some other object entering, like a person pulling a suitcase. A person pushing a stroller might present a challenge, too.

However, if all you want to know is whether there is at least one person in the room, there are other ways to determine that. At least, if they are moving.
The art of getting good answers lies in asking good questions.

jbvidigal

All that has been thought about and solved! I don't really care about the absolute accuracy of the information on how many people pass the beam in and out... at least for now!
Now I really just need to connect the sensor to the Arduino and I don't have a damn clue about it! Looking at the schematics is for me the same as trying to read chinese!
If possible tell me how to do it in a veeeeery basic/retard way... That I think I'll get!
Thanks

PaulS

One part is the sender. It connects to +V and ground. The other side is the receiver - a switch. One side connects to a digital pin. The other side connects to ground. Read, in loop() when the switch is HIGH or LOW.
The art of getting good answers lies in asking good questions.

jbvidigal

Great!!
I got that!
Now the question is... If the buzzer terminal or the LED are just a + and a -... what should go where? should I split the + in 2 (one to 5v and the other to gnd)?
Else... the IR device I assembled uses a 9v battery... does it interfere anywhere in the process!?
Sorry about all the questions... I'm working at the same time with the hardware and the sofware (pd) and it's being a hustle as I have a show comming up in 2 weeks!

PaulS

Quote
If the buzzer terminal or the LED are just a + and a -... what should go where? should I split the + in 2 (one to 5v and the other to gnd)?

The + side goes to +V. The - side goes to ground.

Quote
the IR device I assembled uses a 9v battery

Is it powering the sender side?
The art of getting good answers lies in asking good questions.

jbvidigal

both sides have 9v batteries!
did you see images of the IR device?
http://www.velleman.eu/images/products/0/mk120.jpg
http://www.velleman.eu/downloads/files/schema/receiver.jpg
http://www.velleman.eu/downloads/files/schema/transmitter.jpg

jbvidigal

Ok... so review before I screw up!

side one: transmitter _ 2 blue IR LED's powered with a 9v battery.
side two: reciever _ 1 transparent IR LED, with a buzzer and a red LED that indicate when the beam is broke, powered with another 9v battery.

a) don't touch/modify side one!
b) connect the receiver to the arduino.

  How!?
from the buzzer's - (or the red LED's -) to arduino's GND

what should go to digital pin to read?
once the whole device is powered should anything connect to 5v?

Am I missing anything?

Doup... I'm such an electronics newb! Thanks guys!

retrolefty

If you haven't yet aquired parts yet, You might consider the below linked sensor. It's advantage is that it's a one piece sensor, you don't need a emitter at one side of the door opening and a detector at the other. It's super simple to wire up, three wires, ground, +5vdc power, and one wire to a digital input pin. Detects up to 20" away.

http://cgi.ebay.com/Arduino-Infrared-Reflectance-Sensor-Sensor-Shield-/150471710772?pt=LH_DefaultDomain_0

Lefty

jbvidigal

I have! And I'm so running out of time!... I've got my MA final show in 2 weeks! I'm dead!

Go Up