Will Apache OS talk I2C with Bosch BME280 Sensor? (Temperature + Humidity + Air Pressure) ... Let's find out!

github.com/lupyuen/bme280-nutt

has a peculiar I2C Port ... We need to send the I2C Sub Address (Register ID) separately from the I2C Data ... This might cause the BMP280 Driver to fail

github.com/lupyuen/bme280-nutt

I2C Driver expects us to provide the I2C Sub Address ... Let's patch the BMP280 Driver to pass the Register ID as I2C Sub Address

github.com/lupyuen/bme280-nutt

Follow

Here's how we patch the BMP280 Driver to send the Register ID as I2C Sub Address (instead of I2C Data)

github.com/lupyuen/bme280-nutt

BMP280 Driver says it's 29 °C with air pressure 1,006 millibars ... Yep looks right for Sunny Singapore by the Seaside 👍

github.com/lupyuen/bme280-nutt

BMP280 Driver works OK with our BME280 Sensor ... But we're missing one thing: Humidity ... Can we port the BME280 Driver from Zephyr OS? 🤔

github.com/lupyuen/bme280-nutt

Zephyr BME280 Driver looks similar to BMP280 Driver ... So porting Zephyr BME280 Driver to NuttX might not be so hard 🤔

github.com/lupyuen/bme280-nutt

Our BME280 Driver reads the Sensor Data from Zephyr Driver in two steps: 1️⃣ Fetch the sensor sample 2️⃣ Get the channel data

github.com/lupyuen/bme280-nutt

Power Management works a little differently in vs Zephyr ... Here's how our NuttX BME280 Driver calls the Zephyr Driver to do Power Management

github.com/lupyuen/bme280-nutt

BME280 Standby Duration is static in Zephyr but configured at runtime in ... So we set it in our NuttX BME280 Driver

github.com/lupyuen/bme280-nutt

doesn't have a Sensor Type that supports BME280 Temperature + Humidity + Pressure ... So our NuttX BME280 Driver combines 2 Sensor Types: 1️⃣ Barometer Sensor (Pressure + Temperature) 2️⃣ Humidity Sensor

github.com/lupyuen/bme280-nutt

Each Sensor defines its operations for 1️⃣ Activating the sensor 2️⃣ Fetching sensor data 3️⃣ Setting the standby interval

github.com/lupyuen/bme280-nutt

Our BME280 Driver appears as 2 sensors: 1️⃣ "/dev/sensor/baro0" (Barometer Sensor) 2️⃣ "/dev/sensor/humi0" (Humidity Sensor) ... Here's how we read the Air Pressure, Temperature and Humidity

github.com/lupyuen/bme280-nutt

Show newer
Sign in to participate in the conversation
CleverLibre Social

CleverLibre Social is an inclusive social instance for open discussion, learning, and community.
All cultures welcome.
Hate speech and harassment strictly forbidden.