chubs

Member Since: September 24, 2011

Country: United States

  • Product SEN-10183 | about 3 years ago

    Ok looks like the comment thread has garbled the code. You can just see it here:
    https://gist.github.com/1239034

  • Product SEN-10183 | about 3 years ago

    And the rest:
    void loop()
    {
    // Ask the accel to send us it’s XYZ values
    Wire.beginTransmission(DEVICE); // Start talking to the ADXL345 accelerometer on the SEN-10183 board: http://www.sparkfun.com/products/10183
    Wire.send(0x32); // The address on the accel we want to read
    Wire.endTransmission();
    // Receive the XYZ values
    Wire.requestFrom(DEVICE, 6);
    byte data[6];
    for (int i=0;i

  • Product SEN-10183 | about 3 years ago

    Here’s some arduino code we whipped together to read the accelerometer: https://gist.github.com/1239034
    #include
    #define DEVICE (0x53) // ADXL345 device address when the SDO pin (12) is grounded
    void setup()
    {
    Wire.begin(); // join i2c bus (address optional for master)
    Serial.begin(115200); // start serial for output
    // Wake up the accelerometer
    Wire.beginTransmission(DEVICE); // Start talking to the ADXL345 accelerometer on the SEN-10183 board: http://www.sparkfun.com/products/10183
    Wire.send(0x2D); // The address on the accel we want to set: POWER_CTL
    Wire.send(8); // The value on the address: Measure(8)
    Wire.endTransmission();
    }

No public wish lists :(