Page 1 of 3

[Visualization] Charts for SensorValuesLogging Module

Posted: 01 Mar 2015 02:54
by dolpheen
Ok, here is my the very first try as a developer for wonderful RaZberry platform, maybe it will be usefull for someone else.
I use logging module for testing purposes and made a simple visualization for it. Let's name it Z-Charts :) .
At the moment the code is not optimized, just a working draft.

How it works.
The Z-charts scans for all currently running sensor logging modules and displays values from them as charts .
You can find and set-up logging module in HomeAutomation UI/Modules/Data Logging/SensorValueLogging.
It tested with 2.0.1-rc16 and Chrome browser.

What you can do with it
  • You can see charts ;)
  • Save Logs to local file on comuter (name generated automatically, saved to your default directory)
  • Open Logs from local file on your computer
  • Select time range for Chart (minimum and maximum times generated automatically)
  • Move with slider to any position in time
  • Scale with slider
  • Open 'raw' JSON log for sensor
  • Reset log file
How to install it
Just copy content of archive to /opt/z-way-server/htdocs/ (or where your z-way is installed)
And go to http://[your RaZberry IP]/user/charts/
That's all!

Update 0.0.1
Added Binary Sensor Chart, Scale slider.

Update 0.0.2
Added DatePicker, Save/Load Log, Some statistic info.

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 01 Mar 2015 10:26
by pz1
Interesting module.
  • It raises the question where these [userModules] that produce graphic output should be stored in the overall architecture. That location should 'survive' upgrades.
  • It is also nice because it gives added value to the SensorValueLogging module. I am defnitely interested, as I may use it with the PVlogger that I am working on.

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 01 Mar 2015 11:17
by dolpheen
A rich RaZberry API provide a great possibilities of visualization - for ex. I'd like to experiment with Metro UI style dashboard where I could arrange info and controls in any way I prefer. Or what about SNAP! for RaZberry? http://snap.berkeley.edu/ :)
For me, it would be a good thing that 'modules' not only could include JS code but also Visualization with great HTML technologies, some kind of 'plugins' that could be accessed from HA or Expert UI after installation .

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 01 Mar 2015 11:31
by pz1
Indeed snap and blockley are interesting concepts. IIRC Zipato and Fibaro do use such approaches. Especially for a rule editor they give a compact and easy to read format.

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 01 Mar 2015 11:43
by dolpheen
Thank you for the Blockley link - I wasn't aware of it, I see it's more affordable for integration than SNAP.

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 02 Mar 2015 01:21
by dolpheen
Update 0.0.1
Improved code optimization.
Descrete charts type changed to continuos type , when every logged value is shown from history.
Added binary sensor type (0n - 1, Off - 0)
Added scale slider.

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 02 Mar 2015 15:16
by pz1
I just submitted feature request #226 for a "persistent" user directory under htdocs.

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 02 Mar 2015 21:31
by dolpheen
pz1 wrote:I just submitted feature request #226 for a "persistent" user directory under htdocs.
Ok, great.
And here is a Metro UI prototype I talked about. (inspired by Metro CSS framework)

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 02 Mar 2015 23:01
by pz1
Wow, looks great!

Re: [Visualization] Charts for SensorValuesLogging Module

Posted: 03 Mar 2015 14:54
by dolpheen
My Logs getting bigger :)
So, added DatePicker and ability to save/load logs locally, also some statistic info added.