7 years, 5 months ago.

problem with communication with BMP180 pressure and temperature sensor

Hello,

I am trying to get pressure and temperature measurements out of the BMP180 sensor, I`m using NUCLEO F401RE, connecting the the sensor to the I2C interface of the board as recommended in the Data sheet

/media/uploads/Mias/bildschirmfoto_vom_2016-10-24_11-59-54.png

As I`m trying to initiate the communication with BMP180 by checking whether the value of thr Chip_ID is as fixed 0x55 I getting "error with communicating with BMP180"

/media/uploads/Mias/bildschirmfoto_vom_2016-10-24_11-52-04.png

I am using this code for the test, setting the frequency of the I2C interface to 100KHz https://developer.mbed.org/users/kgills/code/BMP180_example/

anyone has any idea what might be the mistake? is there anyway to test if the BMP180 is working?

Thanks in advance, Maria

1 Answer

7 years, 5 months ago.

Make sure you have proper connections between PB_8, PB_9 and the BMP I2C pins, proper common GND between the devices and check that pull-ups are working (SDA and SCL should be high level in idle condition). Make sure the power is OK on the BMP180.

Next thing to do would be using a scope or better yet a logic analyser to monitor the I2C traffic and see what goes on.

thanks Wim for answering me, I have just checked the pin, pull ups, power connections everything seem ok, except SDA is low level in all cases! at SCL I got 3.296 v at SDA I got 0.015 v any suggestion?

posted by Maria Sadek 26 Oct 2016

Disconnect the SDA pin of the BMP and of the F401. Make sure the pullup is not shorted to GND and the level goes high. Next connect the BMP again and see if that pulls down the level, finally disconnect the BMP and connect the F401 SDA to check if it is pulling down the line. Are you sure there is not some shorted pin on the F401 SDA or another DigitalOut declaration using the same SDA pin.

posted by Wim Huiskamp 27 Oct 2016

thanks Wim for your help, I disconnected and reconnected the SDA and the BMP and I got the SDA as well the SCL pulled up to high level in idle condition, but I am still not getting the measurements what possibilities I have now 1- check other data types (not float) will get me the measurements 2- check if I need to shift left by 1 for the passed addresses 3- try different clock frequencies (I`m using now 100 KHz) can you suggest any other possible solution?

posted by Maria Sadek 02 Nov 2016