Yeah then there is simply no valid communication happening. If you have a logic analyser or something similar that could help to find out what the issue is. Did you try lowering the frequency set for the SPI in the ADXLs library? Or tried using another SPI port?
Regarding I2C, that should be fast enough too, you dont have too read the accelerometer that often. The official limit on the I2C ports the mbed uses is 100kHz (normal mode), but from my experience 400kHz (fast mode) I2C works fine too. I also have had I2C ICs running at 1MHz without problems. But if you want it on an Ipad application I assume you dont need 200Hz sampling rate, especially with the delays wifi adds, anything above a few Hz is overkill.
If you are really worried about I2C overhead, you can try the MODI2C library. It allows for non-blocking I2C communication, so you can do other stuff at the same time.
Hey everyone,
I'm currently working on an ADXL345 accelerometer as part of a university project, I've been having issues with getting the ADXL345 library to work.. although the I2C version works perfectly fine.
Here is a link to the accelerometer I have:
http://babelduck.com/index.php/en/reference/user-manuals/1427-adxl345-3-axis-accelerometer-sensor-module-product-manual
i'm unsure what the issue is but i'm currently only receiving 0,0,0 as a result. my wiring configuration is:
3V3 > Vout GND > GND SDA > P6 SDO > P5 SCL > P7 CS > P8
If anybody has any similar issues and/or insight i'd be very greatful.
Mike