alaudet / raspi-sump

A sump pump monitoring system using Python and Raspberry Pi
https://www.linuxnorth.org/raspi-sump/
MIT License
92 stars 36 forks source link

Overhaul chart reporting #39

Closed alaudet closed 2 years ago

alaudet commented 5 years ago

I am opening this issue as a feature request. There have been requests to provide more options with chart generation;

This issue will track progress on chart options and other issues will be closed.

revendoc commented 5 years ago

Al,

I’m going to try to find some time to look into D3.js https://d3js.org/. I think I can figure out how to read in the cvs files with php (maybe using jquery also) and create dynamic charts. This should be less cpu intensive for the pi also because the charts will be rendered in the browser instead.

alaudet commented 5 years ago

I think it would be an interesting as an add-on. I really know nothing about php/jquery so would have trouble maintaining it. Not sure I could roll it into master. Like to see what you come up with though.

MarkPinches commented 5 years ago

Guys it would be pretty straight forward to create small shell scripts to create data sets of different size length and granularity to support a simple extensions to the front end. e.g. an daily all time, a 6mtd, 3 mtd, ytd etc.. These could have different output .csv files that could be pointed at in the charting function. see my other issue as an example.

alaudet commented 5 years ago

MarkPinches I am going to create a branch called charting to start throwing around some ideas there. Any work toward modifying charting will be done on that branch specifically.

alaudet commented 5 years ago

Version 1.2.1 available for download on pypi added [charts] section to conf file. Can now change line color of chart.

USAFPride commented 5 years ago

I'm new to this project, but have you thought of using a database instead to store the data vs. CSV? A simple RRD (or you could go full out with sqlite3) would allow easy storing, mapping, etc.

alaudet commented 5 years ago

Yes I have considered sqlite3 and will probably go that way. I have to brush up on that before doing so. I have a few changes planned that will coincide with the dropping of Python2 and Wheezy support.

USAFPride commented 5 years ago

I can help with the DB portion. I'll start roughing some items up in sqlite3. I have another project that I can pull dbase creation and writing from. I pretty much stink at UI, but I can get the data in/out.

alaudet commented 5 years ago

i appreciate the offer for help. Before getting too far though I would like to consider adding a db for version 2 of raspisump. I had already planned to start adding other features. I was looking to have it coincide with dropping support for Python2 in January.

I think what I will do is start a new thread for version2. I will also add a label for RaspiSump2 for all issues that need to be tracked.

By all means try some proof of concept code but db support will be targeted for version 2.

I am going to add the thread with all features I am looking to add and provide guidelines for contributors so that anyone who wants to contribute has a framework to work within.

Version2 Main Thread

alaudet commented 2 years ago

Since this thread has died I have added extra chart reporting capability to version 2. If there is interest I can revive.