I started to build a power consumption measurement sensor following this project (german, how to sense a reflective disk of the Ferraris meter): https://www.kompf.de/tech/emeir.html
Everything worked fine and the sensor is communicating with openhab2.
The problem I face now is: how do I record the collected data / save it to a Database so I can use it to track my KWh power consumption.
First I thought I just need to setup MySQL persistence in openhab2, but that was the wrong approach I think.
Then I thought, well now that I have a MySQL Database, just let the sensor write into the database and openhab2 just needs to connect to the db and read the values. But my investigations tell me that openhab2 does not offer such a solution.
So now I am stuck and I need help from you guys. Any idea how I can reach my goal: Show the actual power consumption per month in openhab2?