This insane demonstration shows a Lego factory separating out blocks based on color. It moves 48 items a minute down a conveyor belt and the arms catch and move the blocks using sensors in the system. The entire belt took months to build and develop and essentially simulates a real pick/place system used in factories.
Each robot operates independently. The robots receive a signal from the master, which in this case is the NXT that controls the light sensors. The signal contains information about the color, lane, and position of each object. When the signal is received, the data is stored in a chronological array. When the object gets close enough, the robot goes through a preprogrammed series of movements based on the information in the array.
You can read much more about it here but all I can say is that I’m in awe of the power of this little Lego robot factory. Clearly the sentient robots will soon be able to build their own helpmates out of Lego and program them to separate our heads from our bodies.