Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Dynamic exporters for smartpireadout
The implementation of the software is progressing on github.

I by myself don't use the provided webserver.
Instead, I'm usinf smartpi as metering device and export the data towards emoncms.

I imagine the usage of the smartpi will be manifold.
Currently export towards
  • MQTT
  • CSV
  • SQLite3
  • Prometheus
are available or planned.
I expect more in the future.

Therefore I propose a generic interface to load and instanciate exporters dynamically.
The interface towards the hardware is implemented in ade7878.go.
It implements a function "ReadoutValues", which currently returns a list of 25 float values for further processing.
readout.go itself makes use of these values to export them to various receivers.

I propose to enhance the config file with a list of exporters and their configurations.
Depending on configured exporters, corresponding classes are instanciated and used via a common interface.
The interface should define the numbers of values, their meaning (e.g. name) and of course their values.
Each exporter could be implemented in a separated file, which keeps the code clean and more compact.

This way each user can easily decide which exporter to use, without wasting MIPS on embedded devices for unnecessary processing of the read values.

What do you think about?


Messages In This Thread
Dynamic exporters for smartpireadout - by TriCX - 05.05.2017, 10:45

Forum Jump:

Users browsing this thread: 1 Guest(s)