problems using BMP085 & HMC5883L with Adafruit Datalogger

Hi, I've been working with an Adafruit Datalogger shield for a while and I've just built a sensor array for it, but the sensors don't seem to be working. So far there's a MultiWii board (a BMP085 barometer and HMC5883L 3-axis compass, along with an accelerometer and gyroscope that I haven't tested yet, all on the same board, sharing the same I2C connectors). Near this is a DHT-11 that is wired in parallel with the MultiWii's ground and Vcc lines. The connections are as follows:

GND - MultiWii Ground, DHT11 Ground
5V - MultiWii Vcc, DHT11 Vcc
A0 - DHT11 Data
A4 - MultiWii SDA
A5 - MultiWii SCL

Here's the problem, when I try the example sketch for the HMC5883L, it seems to work but constantly gives the same bearing, except for every few seconds when it spits out 1 line of a totally different bearing then goes back. It doesn't change in response to movement or the presence of nearby magnets, apart from the 1 line fluctuations the heading is always the same.
The BMP085 example sketch just says that there is no valid BMP085 found and to check the wiring.
The DHT11 seems to work normally.

I've had the MultiWii sensor board working fine before, I'm wondering if I've damaged it with either the soldering iron or ESD, or if it's somehow incompatible with the datalogger. Testing the datalogger on it's own before adding the sensors it seemed to work fine, both the SD card and the RTC module. Has anyone else used these parts together? any ideas or advice?

Using different I2C devices is no problem.
You should test it one by one.

This is the shield ?

You could run the i2c scanner to see if the results are stable.
http://playground.arduino.cc/Main/I2cScanner

What is the total impedance of the pullup resistors for the I2C bus of all modules combined together ? You have to know that. If it is getting near 1k it might not work with some sensors.

Which Arduino board are you using ?
Does that shield have a level shifter for I2C ?

Thanks for the reply, that looks like the shield I’m using.

I ran that I2C sketch and got this:

I2C Scanner
Scanning…
I2C device found at address 0x68 !
done

The I2C sensors are all integrated into a single breakout board. I’m still learning to use these components so unfortunately I don’t actually know much about how it works internally, including the value of the pullup resistors, I don’t think the seller does either. I think the board includes it’s own level shifter, going by the claim “IIC communication protocol (fully compatible with 3-5V systems)”.

The arduino board I’m using is a Duemilanove.

Here is the schematic, https://github.com/adafruit/Data-Logger-shield/tree/master/pcb/
You can download a free Version of Eagle to view the *.sch file.

I think the level shifting is only for the SPI interface of the SD card.

There is also a tutorial at Adafruit.

The i2c_scanner found 0x68, that is the DS1307 RTC.
The address 0x68 is also for a MPU-6050 board. You didn't mention which accelerometer/gyro board you have, but I assume it is a MPU-6050 breakout board. If you have connected that board, you have a address conflict right away. The MPU-6050 board can be set to 0x69 with the AD0 line to avoid that conflict.

The Adafruit Shield has 2k2 pull-up resistors for SDA and SCL. That is already low, 4k7 would be better. I think you better remove the pullup resistors from additional sensor boards that use I2C.

The HMC5883L and the BMP085 should cause no problem when connected to the I2C bus. The i2c_scanner should detect them.
You could upload a (sharp or macro) photo, so we can spot the pullup resistors on all the boards.

Perhaps it is a good idea to buy a level shifter.
I use these : i2c level conversion module: Search Result | eBay
But you still have to calculate the total I2C pullup impedance by combining both the pullup of 5V and the 3.3V I2C bus. When a device on the 3.3V I2C pull the line down, it also has to pull the 5V I2C bus down.

This photo shows all the I2C sensors in the project, including the barometer, thermometer, magnetometer, accellerometer and gyroscope. The only sensor connected but not shown is the DHT-11 which is wired in parallel with the ground and 5v lines and uses it’s own non-I2C data line to pin A0.

I don't see the MPU-6050. So probably other sensors are used.

The smd componenent on the left is the voltage regulator.

I don't know if the smd component below the middle is a level shifter. It is surrounded by 4 resistors of 2k2.
If that would be the pullup resistors for I2C you have a total of three 2k2 resistors per I2C line. That is below 1k and some sensors have a weak I2C pull-down and don't like it.

Could you remove the Adafruit shield, and connect the sensor board to your Arduino board. Run the i2c_scanner and it should detect all the sensors.

When you add the Adafruit shield and the i2c scanner detects not all sensors anymore, it might be the pullup problem (but it could also be something else).

I use 4k7 on the 5V side of the I2C bus and 4k7 on the 3.3V side. That's all, I removed all other pullup resistors of various sensor boards.

I ran the scanner on another sensor board of the same model without the data logger and got this:

I2C Scanner
Scanning...
I2C device found at address 0x1E !
I2C device found at address 0x53 !
I2C device found at address 0x69 !
I2C device found at address 0x77 !
done

It might be a few days before I can give any more updates as I've just destroyed the data logger with some bad soldering, which kind of illustrates why I don't want to attempt removing any of the resistors on the sensor board. I notice Adafruit have an LSM303 board, so I might just get that instead.

Sorry to hear that the datalogger is destroyed.
The sensor board seems to be okay, 4 sensors are detected.
There are also seperate modules for an SD card and for RTC.

sorry to necro an old thread but I try to always post solutions when I have them.

After getting a replacement datalogger shield (same model and supplier as before), and testing it with a 2nd sensor board (again, same model as before), they worked without apparent problems.

Testing the old sensor board without the datalogger gave the same problems as before. So it looks like the 2 items are compatible without modification, I just fried the sensor board.

Thanks for your post. I’m glad it is solved.