Hi,
Was playing with ESP32 and BMP280 using the examples from the MicroPython programming book – getting some errors in the BME280.py module..I am wondering if this is because I am using the BMP280 rather than BME280? Or is it something else?
>>> from machine import Pin, SoftI2C
>>> i2c = SoftI2C(scl=Pin(22), sda=Pin(21))
>>> bme= BME280.BME280(i2c=i2c)
Traceback (most recent call last):
File “<stdin>”, line 1, in <module>
File “BME280.py”, line 155, in __init__
File “BME280.py”, line 161, in _load_calibration
File “BME280.py”, line 121, in readU16LE
File “BME280.py”, line 104, in readU16
OSError: [Errno 19] ENODEV
Hi.
It’s probably because of the module.
They are different and probably have difference I2C addresses.
I recommend using a specific library for your sensor like this one for example: https://github.com/dafvid/micropython-bmp280
Regards,
Sara