By Jón Ellingsgaard
Step 1: The Belt Unit
Get someone to build a conveyor belt with a ultrasound unit mounted on a gate.
This might require some sort of bribe or possible magic. I dunno.
Step 2: The Parts
A micro controller unit.
A grove board.
A ultrasound unit
Step 3: Assembly
Tahe the grove shield and jam it on top of the Uno. Then plug in the ultrasound unit, using the wires. Use D7.
The picture is only an example, using a different component in a different plug.
Step 4: The Code
Use this code:
Step 5: Using It.
Assuming that you got it to work, you now have a devise that can scan, recognize and count three different objects. What you use this for I don't know. But now you have it.