update enviro module to not create copies

This commit is contained in:
Thomas Göttgens
2023-02-02 15:26:31 +01:00
parent a13adfb598
commit f6c6c2912f
2 changed files with 9 additions and 1 deletions

View File

@@ -36,7 +36,7 @@ class EnvironmentTelemetryModule : private concurrency::OSThread, public Protobu
private:
float CelsiusToFahrenheit(float c);
bool firstTime = 1;
const meshtastic_MeshPacket *lastMeasurementPacket;
meshtastic_MeshPacket *lastMeasurementPacket;
uint32_t sendToPhoneIntervalMs = SECONDS_IN_MINUTE * 1000; // Send to phone every minute
uint32_t lastSentToMesh = 0;
uint32_t sensor_read_error_count = 0;