Plot location on board

Hello,

I've had this idea in my head awhile, and have been looking around and found Arduino and thought it would be the "simplest" way to go about it. The basic idea would be to have clear board (plexiglass or the like) with a bunch of LEDs mounted behind it which would light up and "cascade" (think fireworks) out to the edges of the board, with the origin of the cascade being where an impact occurred. I've thought a bit about it and thought I'd throw it out there to see what those much more experienced than I might think...

I've been reading a lot about LED matrices and shift registers/multiplexing/charliplexing/etc. and from the looks of it it seems like the theory behind the LED part of the project would be doable. The thing I'm having a bit of trouble getting my head around is activating the sequences of LED events based on where the impact occurs. I've searched all over to find someone who's done this before but can't seem to find it.

After thinking about it for a few days, i'm thinking I may have a pretty simple (and cheap) way of figuring it out with piezo elements. Basically just having four elements positioned on the board (each located on the outer edge in the middle of the four sides). And using some caluculations on the four different readings to get a kind of x,y coordinate of the impact...

E.g. if i call the sensors (starting at 12 o'clock and going clockwise) p1, p2, p3 and p4, the x coordinate would be equal to

x = p1/(p1+p3)

and likewise,

y = p2/(p2+p4).

would that give me a proportion of how high/low and left/right the impact occurred relative to the very low left corner? So say p1=p3 and p2=p4 that would essentially mean the impact occurred in the center of the board (at coordinate (50,50)).

Next question, assuming all above is good to go theoretically, say I break down all the possible coordinates into 20 "zones" (I really don't have the time, skill or patience to create say a 100/100 LED matrix...although that'd be awesome) and space the LEDs out a bit from each other, do i need to have in my code 20 different routines for each possible zone where the impact originates from? I'm hoping not, but if it did, would the Arduino have the memory to hold all those different routines?

I haven't even thought of the power logistics this would take yet...I've mocked up an idea, just in Excel, and guesstimate I'll have around 280 total LEDs, however, the most on at one time would be 120.

any thoughts, guidance, reassurance would be most appreciated!

What is causing the impact? A resistive touch screen might do it. But, yeah, an acoustic solution as you suggested was my first thought.

Something similar to Surface Acoustic Wave teouchscreens:

http://en.wikipedia.org/wiki/Touchscreen#Surface_acoustic_wave

Another idea would be IR beam touchscreens.

I would think that one pattern would be all you would need as long as the matrix was evenly spaced. You would just use a mathematical routine with the origin being the center of your effect. You would store the state of the pixels in an array and just manipulate the array just like memory. In fact, you could test this without even soldering a single LED by just using the serial monitor to output your array.

The impact will be a wiffle ball hitting the board at sometimes a pretty high speed (70-80 mph), also the board is roughly 2' x 3' so a touchscreen wouldn't really work...well, for very long at least.

You've got me intrigued though on how I could do this with just one sensor (if I'm understanding you correctly). The matix will be evenly spaced across the board. Could you suggest a resource (website, book, etc.) where i could learn how to interpret that? Or, would it just be a matter of hooking it up and "touching" all the zones to see what the reading is and then program that? The only problem I could see is that the ball won't be hitting the board with the same force every time, so two readings in the same zone won't be the same...which is why i think i might need the four sensors I originally planned for.

Now i'll have to go read up on how to create/manipulate arrays with this thing :)

I think you misunderstood me. For positional sensing you would need more than one sensor. For Surface Accoustic Wave sensing, it uses at least 3 sensors. That sounds like the most complicated way, though since it requires doing pattern recognition of the sounds.

If the force will be pretty hard, you might look at load sensors like those used in digital scales. Another option would be to emulate an electronic dart board which actually just has panels that move a bit and trigger switches.

One method that I suggested above was IR sensing. This would require setting up a row and column of IR leds and receptors. You would sense the zone by which beams were broken.

Ok, I've been reading and doing some tutorials on arrays and I somewhat get them at this point. I've tried a couple things but to no avail to get to something you mentioned in your original reply:

you could test this without even soldering a single LED by just using the serial monitor to output your array

I'm totally lost on how i would display, say an 8x8 matrix in the serial monitor. My thought was that I'd have to read the state of all 64 values, and concatenate the first 8 bits, ending with Serial.println, then the second 8, then the next 8, and on and on until i have the 8 rows.

Is that the general way to go about it, or am I way off?

I haven't hooked up any sensors at this point, just trying to get my head around the theory of how this is all going to work...

Thanks!