This is a wrapper for Adafruit BMP280 library: https://github.com/adafruit/Adafruit_BMP280_Library
Usage example:
Usage example:
B4X:
Sub Process_Globals
Public Serial1 As Serial
Private bmp As Adafruit_BMP280
End Sub
Private Sub AppStart
Serial1.Initialize(115200)
Log("AppStart")
If bmp.Initialize Then
Log("Successful")
Log(bmp.ReadAltitude(1013.25))
Log(bmp.ReadPressure)
Log(bmp.ReadTemperature)
Else
Log("sensor not found!")
End If
End Sub