I'm playing around with motion detection for fun and came across the problem of detecting the motion of uniform objects (e.g. cubes, balls, etc) from a fixed position. Concise: electronically capture the path of such a small object that enters an open empty space (field, flat ground, no other objects).

QUESTION: What sensors do you employ to fulfill the following requirements (within the given enrionment).

Environment and scenario:

  • empty, cubic space (air only),
  • no side longer than 40 feet / 12 meters.
  • different but natural outdoor or indoor air pressure.
  • no temperature difference between object and sensor.
  • temperature between 5° and 55° celcius
  • objects enter space from one side of the cube only.
  • sensor must be opposite of the object entry side.


  • location of object must be captured highly frequenty (min 10 times) within 1-3 seconds.
  • each measurement event must deliver x, y and z (full relative position to the sensor).
  • the sensing angel must be 80° (from what I read, that is really high. However, I think that can be resolved by installing multiple sensors to reach the 80°.)

So, dear e-engineers. What sensor is to solve that problem best under the given conditions? ultrasonic sensors?

Thanks for hints (that go beyond my concrete question).

  • \$\begingroup\$ Well, I think you'll need at least 3 sensors to get a x,y,z coordination system \$\endgroup\$
    – Chris
    Commented Dec 4, 2013 at 12:52
  • \$\begingroup\$ What kind of precision is required? If the lighting and background is controllable I'd go straight for a computer vision solution. \$\endgroup\$
    – pjc50
    Commented Dec 4, 2013 at 12:53
  • \$\begingroup\$ @user1410908 yep, that makes sense. I thought that too, and is absolutely doable on the host system. \$\endgroup\$
    – feder
    Commented Dec 4, 2013 at 13:01
  • \$\begingroup\$ @pjc50 The required precison is given by the need to compute the speed of the object. The speed of the object is not linear. Might go up and down. Because of that I need to measure multiple times. At the end I certeinly want a speed that is accurate within +-3kmh, +-1.5mph. Think of a baseball scenario, hm.. tennis outdoor, a speedy tractor on a field, etc. background is not something I could influence. And since there is no other object in this cubic space, I thought ultrasonic might make sense (though, I have no clue on their professional capabilities). \$\endgroup\$
    – feder
    Commented Dec 4, 2013 at 13:08

1 Answer 1


Trouble with ultrasound is that it doesn't stay in the box - you still have reflections from background. So for objects that are more than a few tens of cm from the sensor you need to do signal processing to find the target. In which case you might as well pick a solution using visible light to make it easier to debug. Computer vision tracking of moving objects against static background is a solved problem; see OpenCV for a free implementation. It works best against neutral backgrounds, but doesn't require that. Two cameras gives you stereo imaging and three positions.

If you just want ball speed along an axis you can get off-the-shelf radar guns for this purpose. Building your own radar system is an extremely difficult prospect.

Edit: 50m/s should have been in the original spec, that's quite fast. Ultrasonic usually works by sending out "chirps" and timing the response. Speed of sound is ~340m/s. So it takes 35ms for sound to traverse the 12m box. During that time a 50m/s target has moved 1.75m. You need to wait until your first pulse has gone out and back before sending the next, so pulse interval is at least 70ms. So you can only get one measurement every 3.5m.

You should also spec the latency: are you trying to interact with the moving object, or is it sufficient to work out where it was after is has passed? Do you care about the exact trajectory, or just speed of passing through the box (which can be found with doppler methods with ultrasound or radar).

  • \$\begingroup\$ @pic50 Even if there is no other object within the space? From what I have seen, sensor have a given min and max range. How "bad" are the disturbing signals beyond that? Also, I migth be hard to catch the objects if they are as fast as 50m/s, isn't it? I certainly want something that can take advantage from the fact that the cubic space is empty - except the moving object. \$\endgroup\$
    – feder
    Commented Dec 4, 2013 at 13:51
  • \$\begingroup\$ I think you've accepted my answer a bit early - you won't get other suggestions now. See edit. \$\endgroup\$
    – pjc50
    Commented Dec 4, 2013 at 14:14
  • \$\begingroup\$ @pic50 No interaction required. Tracability is focused, not limtied to the speed. I want to draw the intrapolated trace on a 3D map afterwards. I look into the doppler method. Surely try visual tracing, too. Thanks for the ramp up. Highly appreciated. \$\endgroup\$
    – feder
    Commented Dec 4, 2013 at 14:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.