ADXL345 Accelerometer


29 posts   Page 2 of 2   1, 2
by garym1957 » Fri Nov 02, 2012 3:10 pm
Hey all.
I’m still trying to get (understand, grasp, comprehend) what I need to do to get the RPi to read data from the ADXL34 3-axis accelerometer. I would be happy if i could call some command line function to get a reading or await interrupts or something.

I’m not smart enough to figure out the few examples I’ve found.

Does someone have a COMPLETE, idiot’s guide to making this happen?

I have no idea if I should use SPI or I2C and there appear to be no wiring schematics in any but one example.

So please, anyone… the world needs a COMPLETE solution for stupid people like me.

0. What am I to expect? is this a command line program or just a library example?? Is this a logging function or will I see something on my screen when I tap the module? People love to post step-by-step instructions for things without mentioning what the end result will be.

1. Wiring diagram – seriously – Its not even funny, how many “examples” are out there where the schematic was considered unnecessary.

2. What (libraries, programs) do I need installed for the way its wired?

3. What do I do if something doesn’t work?

4. Perhaps EXPLAIN a little about why each of the previous steps was performed. Not everyone knows linux that well.

Thank you very much
Posts: 11
Joined: Fri Aug 24, 2012 6:04 am
by garym1957 » Fri Nov 02, 2012 3:24 pm
Hey all.

Anyone got this to work? Anyone have a CANNED, WORKING example they can share? I'm not smart enough to do this myself.

I’m still trying to get (understand, grasp, comprehend) what I need to do to get the RPi to read data from the ADXL34 3-axis accelerometer. I would be happy if i could call some command line function to get a reading or await interrupts or something.

Does someone have a COMPLETE, idiot’s guide to making this happen?

I have no idea if I should use SPI or I2C and there appear to be no wiring schematics in any but one example. I've mentioned a photograph of another person's wiring, but there are no connections for CS or anything... just from the PI to the Accel board.

So please, anyone… the world needs a COMPLETE solution for stupid people like me.

Wish list:
0. What am I to expect? is this a command line program or just a library example?? Is this a logging function or will I see something on my screen when I tap the module?

1. Wiring diagram – seriously – Its not even funny, how many “examples” are out there where the schematic was thought of as unnecessary.

2. What do I need installed for the way its wired?

3. What do I do if something doesn’t work?

4. Perhaps EXPLAIN a little about why each of the previous steps was performed. Not everyone knows linux that well.

Thank you very much
Posts: 11
Joined: Fri Aug 24, 2012 6:04 am
by joan » Fri Nov 02, 2012 3:36 pm
The ADXL345 is a chip manufactured in many forms. It is installed in many different boards with different names. These may all have unique interfacing requirements.

What did you buy?
User avatar
Posts: 1810
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK
by garym1957 » Fri Nov 02, 2012 9:02 pm
Its a Chinese breakout board from eBay.
All pins come directly out to headers. Among a half-dozen manufacturers, I have seen this to be the same in every case.

There is a LDO regulator chip and jumper for those who want to use either 5V or 3.3V for power.

I can run
i2cdetect -y 0
and it returns hex 53. I can disconnect any of the data wires and it returns nothing, so I know my Pi is seeing the board.
Posts: 11
Joined: Fri Aug 24, 2012 6:04 am