Snap4Arduino icon indicating copy to clipboard operation
Snap4Arduino copied to clipboard

Pressure sensor BMP180

Open seteahconnoc opened this issue 7 years ago • 3 comments

Hello.

I am trying to use the pressure sensor BMP180 with Snap4Arduino.

My internet search lead me to this thread https://groups.google.com/forum/#!msg/s4a-community/sNhqLSwHd74/nSiPFDOKDQAJ in the "S4A Community Mail List". There, the issue remained unsolved. "jguille2" wrote: "... the problem is you have to open Sparkfun library and program all the actions and calculations into Sn4A. I have not much time and also I haven't this sensor to test it... but if you want to work with it, we can help you..."

Any further suggestions would be welcome.

Thanks.

seteahconnoc avatar Jan 13 '18 18:01 seteahconnoc

Hi @seteahconnoc.

Since this is an i2c device, you'll need to use the i2c library for Snap4Arduino.

The datasheet for the device can be found here, and the i2c interface specs start in page 19. In particular, page 21 has a table with the register address and the control register values for different readings.

Untested because I don't have one of these sensors at hand, but here's how you'd supposedly read the temperature out of this device:

untitled script pic

i2c can be tricky, I hope it works for you! :)

bromagosa avatar Jan 19 '18 08:01 bromagosa

Yes... And I also point you to the Arduino library to help you in the calculations.

In fact, you can follow the library algorithm and leave aside the spec. This would be my way... but you'll see it takes a bit of time!

If you don't need immediately, I guess soon I'll do this work, because I'm waiting to doc some other keyestudio sensors. But I want to have these sensors before to test my proposals.

Joan

jguille2 avatar Jan 19 '18 10:01 jguille2

Thank you! Hopefully, this does not exceed my skills. I 'll see. @jguille2 Please, keep me in touch, if you 'll achieve something.

seteahconnoc avatar Jan 19 '18 14:01 seteahconnoc