MEMS nano pressure sensor: 260-1260 hPa absolute digital output barometer.

Dependencies:   X_NUCLEO_COMMON ST_INTERFACES

Dependents:   HelloWorld_ST_Sensors MOTENV_Mbed mbed-os-mqtt-client LPS22HB_JS ... more

Revision:
1:33ddb62b31fd
Parent:
0:3de9cb936fd1
Child:
2:f7b403c70f6b
--- a/LPS22HBSensor.cpp	Mon Sep 04 16:06:45 2017 +0000
+++ b/LPS22HBSensor.cpp	Wed Sep 27 16:49:30 2017 +0200
@@ -48,19 +48,10 @@
  * @param i2c object of an helper class which handles the I2C peripheral
  * @param address the address of the component's instance
  */
-LPS22HBSensor::LPS22HBSensor(DevI2C &i2c) : _dev_i2c(i2c)
+LPS22HBSensor::LPS22HBSensor(DevI2C *i2c, uint8_t address, PinName int_pin) : 
+                            _dev_i2c(i2c), _address(address), _cs_pin(NC), _int_pin(int_pin)
 {
-  _address = LPS22HB_ADDRESS_HIGH;
-};
-
-
-/** Constructor
- * @param i2c object of an helper class which handles the I2C peripheral
- * @param address the address of the component's instance
- */
-LPS22HBSensor::LPS22HBSensor(DevI2C &i2c, uint8_t address) : _dev_i2c(i2c), _address(address)
-{
-
+    assert (i2c);
 };
 
 /**