Best aproch for sending/storing sensor values

I am working on a project to send communications site telemetry data to an SQL database for further processing.

Info will include the temperature of several sensors, humidity, battery voltage, utility voltage, and current draw of several items. Some values will not change often; just poling them over time is fine. However, some values need to be captured in as close to real-time as necessary. Such as current and TX/RX state.

My thought is to poll and update all values on the ESP32 and then only send them if certain values are different or significantly different than of X amount of time before. I am unsure how fast I can send the data to the HTTP server as it may be done over a LORA connection. In this manner, I would like to send ALL values as one string.

Other thought...
Send all the slower-changing values once every minute and then only send the frequently changing values as they change.

The biggest difference, I think, will be the DB structure on the remote server.

If anyone has done this before, I am looking for a suggestion on DB structure.

Thanks

There are specific "time series database" engines optimized for storing data as key value pairs, for example InfluxDB.

They have built in compression for repeated values so you don't need to implement that on the microcontroller.

For visualizing the data you need something like Grafana.
To get these things talking to each other Node-red provides connectors.

Influx Data is a no-go due to the company screwing previous customers. I have no issues with the DB structure, but I will do it in SQL.

I have not tested sending all the data separately vs in one insert statement. My expectation is that one statement will take less overall time.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.