I am new to accelerometers and arduino in general. My project: I want to throw the arduino vertically up and at the highest point, right when it starts to fall, i want the arduino to turn on an LED. Which accelerometer should i use and how show i start the programming? I am using an arduino uno. I greatly appreciate your help.
Your idea won't work, because while the accelerometer/Arduino is in the air, the accelerometer will always read as close to zero as matters. This is because the Earth's gravity applies the same acceleration to everything.
The accelerometer measures the difference between the force applied to the accelerometer package, and a "spring/mass" system inside the accelerometer. When flat on a table, the accelerometer will measure 1g because the table is pushing up on the package while gravity is pulling down on the sensing element. In free fall, regardless of the direction of motion, the accelerometer measures zero.
They were able to do it, i just don't know about arduino and accelerometer that well.
"The microcontroller on the mainboard processes the data from the
accelerometer, integrates (sums up) the acceleration during launch and
from this calculates the launch velocity (speed at the moment when the
ball leaves the throwers hands)
• From the launch velocity it’s easy to calculate the rise time to the
highest point in the trajectory.
The ball is already in free fall when it flies up — one can visualize that fact when one knows how accelerometers work:
• There is a little test mass on a spring
• One measures the elongation of that spring
• When you hold the ball in your hand, the spring gets pulled down by
• When the ball flies up, the spring retracts and ball, accelerometer and test mass fly happily next to each other.
• There is no difference between going up or down"
You need to know the vertical speed of the ball when it is released. It should possible to determine that from a three-axis accelerometer and three-axis gyros, if you are clever enough. It would be quite challenging to do, though.
The "throwable panoramic camera" link that you posted is an extremely cool idea! The way you phrased your question, I thought you wanted the accelerometer to indicate when it had reached the high point of the trajectory, which it can't do.
Yes, as described you can estimate the time the projectile will take to get to the top of its trajectory. You integrate the launch acceleration to get the initial velocity, then calculate the time to zero velocity assuming constant acceleration due to gravity. This will only be approximate because of inaccuracy in the integration and the process to separate the acceleration due to gravity from that delivered by the throwing hand. As pointed out by PeterH, this is not trivial.
How about this... Throw a ball up in the air as hard as you can and record the maximum acceleration on the accelerometer during the first second of flight, then stop recording values (so you don't record the landing.) Then throw the ball rather weakly and record the max acceleration of that flight. Record the time it takes to complete both flights as well, and divide by two to get the midpoint in time.
Now you have four pieces of data from which you can use to approximate the time that the ball is at the top of its flight. By linearly extrapolating the g-forces to flight times, you ought to get pretty close to finding the apogee. I'd bet that you can get to within 20% of the top with this method. Keep playing with the extrapolation and you might do better.
It might be more practical to make a sensitive air speed sensor which can detect when the air speed reaches a minimum at the top of the arc.