I am using arduino and accelerometer MMA7341 to measure the acceleration in x direction of an oscillating metal table. But the mounting of the accelerometer is tilted by a small angle (say Q) . Is it affect the acceleration?. If it is affect the acceleration in x direction , how can correct it without changing the tilt of the acceleration sensor.
3D trigonometry is your friend (!) You have a 3-axis accelerometer so you have the full 3D vector to play with. Determine the direction of maximum oscillation by taking some measurements and then you just have to resolve in that direction thereafter by taking the vector dot-product.
Say your oscillation is in a direction given by x=50, y=7, z=-4, then you just calculate: