BME
Public Functions
| Name | |
|---|---|
| BME() | |
| bool | begin(uint8t ADR =0x77) Initialize the BME280. |
| float | getPressure() Atmospheric pressure. |
| float | getHumidity() Relative humidity. |
| float | getTemperature() Air temperature. |
| String | getHeader() Northern Widget CSV header string. |
| String | getString() Northern Widget CSV data string. |
| void | beginRawReadings() Prepare for raw reading collection. |
| uint16_t | takeRawReading(char * buf, uint16_t offset) Take one raw reading and write CSV data into buf at offset. Writes: pressure [mBar], humidity [%], temperature [°C], each followed by a comma. Max bytes written per call: 24. |
| void | endRawReadings() End raw reading collection. |
| float | GetPressure() |
| float | GetHumidity() |
| float | GetTemperature() |
| String | GetHeader() |
| String | GetString() |
Public Functions Documentation
function BME
BME()
function begin
bool begin(
uint8_t ADR_ =0x77
)
Initialize the BME280.
Parameters:
- ADR_ I2C address (default 0x77).
Return: true if sensor found and initialized successfully.
function getPressure
float getPressure()
Atmospheric pressure.
Return: Pressure in mBar.
function getHumidity
float getHumidity()
Relative humidity.
Return: Humidity in %.
function getTemperature
float getTemperature()
Air temperature.
Return: Temperature in °C.
function getHeader
String getHeader()
Northern Widget CSV header string.
Return: “Pressure Atmos [mBar],Humidity [%],Temp Atmos [C],”
function getString
String getString()
Northern Widget CSV data string.
Return: Comma-separated pressure, humidity, temperature with trailing comma.
function beginRawReadings
void beginRawReadings()
Prepare for raw reading collection.
function takeRawReading
uint16_t takeRawReading(
char * buf,
uint16_t offset
)
Take one raw reading and write CSV data into buf at offset. Writes: pressure [mBar], humidity [%], temperature [°C], each followed by a comma. Max bytes written per call: 24.
Parameters:
- buf Caller-managed destination buffer.
- offset Starting write position in buf.
Return: New offset after writing.
function endRawReadings
void endRawReadings()
End raw reading collection.
function GetPressure
float GetPressure()
function GetHumidity
float GetHumidity()
function GetTemperature
float GetTemperature()
function GetHeader
String GetHeader()
function GetString
String GetString()
Updated on 2026-05-15 at 05:04:17 +0000