Connect 3 accelerometers to Arduino Uno

Hi!

I'm new with Arduino, and searched a lot on the internet, but I didn't find the answer.
Is it possible to connect 3 analog or digital accelerometers to Arduino Uno. If not, which Arduino panel can I achieve this. I need data from all 3 accelerometers at the same time. I would like to use 3 piece from this ADXL345 accelerometer (http://www.wide.hk/img/ADXL345_2.JPG). Here is the wiring diagram (http://www.wide.hk/img/ADXL345_4.JPG) which I found. Can I wire the other 2 like this?

This is the description of the accelerometer:
This new version adds 2 standoff holes as well as an extra decoupling capacitor. The ADXL345 is a small, thin, low power, 3-axis accelerometer with high resolution (13-bit) measurement at up to ±16 g. Digital output data is formatted as 16-bit twos complement and is accessible through either a SPI (3- or 4-wire) or I2C digital interface.

The ADXL345 is well suited to measures the static acceleration of gravity in tilt-sensing applications, as well as dynamic acceleration resulting from motion or shock. Its high resolution (4 mg/LSB) enables measurement of inclination changes less than 1.0°.

Features:

•2.0-3.6VDC Supply Voltage
•Ultra Low Power: 40uA in measurement mode, 0.1uA in standby@ 2.5V
•Tap/Double Tap Detection
•Free-Fall Detection
•SPI and I2C interfaces

Thx for the help guys.

Just to be certain here, you do realize the ADXL345 is a 3 axis device that reads X,Y & Z all on one chip? Do you really need 3 of these?

You could connect three three-axis devices to a Mega, but because the Mega has only one ADC, the update rate would be one third the rate for a single three-axis accelerometer.
Digital devices are normally I2C, and if you can specify a different bus address for each device, then you can attach more than one.

Riva:
Just to be certain here, you do realize the ADXL345 is a 3 axis device that reads X,Y & Z all on one chip? Do you really need 3 of these?

Yes, I know that. I need the tree axis acceleometers, because I want to recognize finger guestures in the space, so I need to read the data of all 3 axis.

What others are telling you is that adxl345 is a 3 axis accelerometer - it tells you acceleration on 3 axis, from 1 adxl345.

Redy029:

Riva:
Just to be certain here, you do realize the ADXL345 is a 3 axis device that reads X,Y & Z all on one chip? Do you really need 3 of these?

Yes, I know that. I need the tree axis acceleometers, because I want to recognize finger guestures in the space, so I need to read the data of all 3 axis.

My apology but I obviously did not word my question very well and am having difficulty understanding your answer to it. You want to wire 3x 3 axis accelerometers (9 axis in total) to one arduino, maybe one per finger?
Datasheet says device can use SPI or I2C comunications but it can only have one of two fixed I2C addresses. Theoretically you could connect 3x devices using SPI or 2x I2C & 1x SPI.

My apology but I obviously did not word my question very well and am having difficulty understanding your answer to it. You want to wire 3x 3 axis accelerometers (9 axis in total) to one arduino, maybe one per finger?
Datasheet says device can use SPI or I2C comunications but it can only have one of two fixed I2C addresses. Theoretically you could connect 3x devices using SPI or 2x I2C & 1x SPI.

Yes exactly, I want to wire 3x 3 axis accelerometers, one per finger. So can I connect 3 ADXL345 to Arduino Uno, via SPI? Or I can do it only with the Mega?

The chip supports SPI and i2c so you can hang them together with 2+ wires.

...however there are only 2 I2C addresses available.

AWOL:
...however there are only 2 I2C addresses available.

And why is this problem? Sorry, but I don't know about these things, because I've never worked with accelerometers and microcontrolers yet.

Redy029:
And why is this problem?

You need to assign a unique address to each device. If you have more devices than addresses, obviously you can't.

I found this wiring diagram (http://tronixstuff.files.wordpress.com/2011/05/sspiss2.jpg). Is is possible to connect 3 accelerometers like this, and choose between them with the 3 separated SS line?

It is possible to connect as many as adxl345 sensors together as your money allows, all explained in the datasheet.

If you are attaching the sensors to a glove, you may want to consider flex sensors.
Maybe use one 3 axis accelerometer for hand position, and 3 or four flex sensors for the fingers.

The accelerometer could be I2C and the flex sensors wired to the analog pins.

Something like this? Long Flex sensor : ID 182 : $12.95 : Adafruit Industries, Unique & fun DIY electronics and kits

They were used in the Nintendo power glove.

JD3:
If you are attaching the sensors to a glove, you may want to consider flex sensors.
Maybe use one 3 axis accelerometer for hand position, and 3 or four flex sensors for the fingers.

The accelerometer could be I2C and the flex sensors wired to the analog pins.

Something like this? Long Flex sensor : ID 182 : $12.95 : Adafruit Industries, Unique & fun DIY electronics and kits

They were used in the Nintendo power glove.

Thank you for the great idea, I will read and think about these things. :wink:

dhenry:
It is possible to connect as many as adxl345 sensors together as your money allows, all explained in the datasheet.

Ok, I found it in the datasheet. http://www.analog.com/static/imported-files/data_sheets/ADXL345.pdf. It says, use OR logical gate to prevent bus traffic errors. Is the OR gate necessary, if I don't use any of the I2C buses? And what is the difference between the the 3 and 4 wire SPI connection?