Thanks for the suggestion. This is what I have in my loop now:
void loop() {
struct allData {
float temp = bme.readTemperature();
float pres = { bme.readPressure() / 100.0F };
float alt = { bme.readAltitude(SEALEVELPRESSURE_HPA) };
float humid = { bme.readHumidity() };
}
radio.write(&allData, sizeof(allData));
}
It now comes with the error: "expected initializer before '.' token".
Does anyone know what this means?