Strategies for tracing movement vectors across a sensor grid

hi there

I would like to connect a bunch of light sensors in a grid so that I can trace a flashlight moving across them.

My goal is to measure acceleration and, ideally, direction, always from the one sensor in the grid that currently outputs the highest number (= receives the most light) to the next and so on.

Ideally I would like to trace greater movement vectors, that is, movement direction and acceleration/speed across multiple sensors in the grid.

Can anyone advise what would be a good strategy for doing this?

here's an illustration:
grid|609x488

Need more information. Do you mean a point light source, rather than a "flashlight", which will illuminate a swath of sensors?

A point light source will probably illuminate several nearby sensors, in which case you can use interpolation to estimate its position at a point in time.

From a set of positions and timestamps, it is easy to calculate velocity and acceleration.

Well, I figured you can convert the flashlight into a point light source by only using data from the sensor that gives out the highest value at a given time.

Exact position is not needed, simply which sensor outputs the highest value at time x.

What are solutions for velocity and acceleration? I know this is very simple but I'm quite new to programming ...

A basic law of motion is that if you measure position x1 at time t1, and x2 at time t2, velocity in the x direction is (x2-x1)/(t2-t1). Similar for acceleration.

thanks!

Start with keypad where pressing each button will turn on LED corresponding to that button, then replace buttons by light sensor, if you need more LEDs use keyboard program

Need diodes to resolve multiple key "presses". Can actually use a matrix with analog inputs if wired correctly. Nano has 8 analog inputs.

Thank you.

What would be a programming solution to produce output such as:
"light has moved upward/downward/left/right/diagonal etc."?

Take the current X/Y position, and subtract the previous X/Y position. That gives you the velocity vector. Then you need to partition what angles count as which direction.

Thanks for the reply. I am using an optical flow solution in MaxMSP now, which works wonderfully.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.