I'm looking for a low cost solution for a recognition of 2 or more devices (arduino uno) to each other at a distance of about 2 meters. The devices don't know each other.
Example: Person A has a device in his pocket. Person B has also a device in his pocket. If both meet accidently lets say on a street and come closer than about 2 meters to each other the devices should recognize it and do some acion (e.g. start blinking or something like this).
At first I looked for a RFID solution but for such a distance it becomes MUCH to pricy and "over engineered" because I don't need unique identifiers or tags.
Bluethooth? Don't know how this should work because the devices should recognize automatically completly unkown devices without any user input.
Do you have an idea for a max. 20 Euro solution?
The 315MHz/433MHz modules are very simple. Perhaps you could use that. But it will be hard to detect the distance. They could trigger between 20 meters or 50cm.
Use a receiver with a crystal, not the tuned coil.
They have to transmit every second or so, that would reduce battery life.
Those modules are often used with the VirtualWire library: http://www.airspayce.com/mikem/arduino/
Short range, no attenna radio is what I was thinking as well. Both units will need to broadcasting, receiving, and analyzing all the time. Power consumption could be an issue.
It's not necessary for them to transmit/receive all the time. What you need is a system in which there will be overlap between transmission and reception within a reasonable period (perhaps 5 seconds?).
For example I THINK if each device transmits and receives for 10millisecs with gaps of 30, 20, 10, 30, 20, 10 etc. there will be an overlap every few transmissions but the radios will only be operating for 30% of the time. This may not be correct, but I hope it will convey the idea. You could probably experiment with a spreadsheet.
I implemented a scheme like this to save power in the listener but I THINK it should work both ways.