We have moved at community.getvera.com

Author Topic: New dataMine graphing and logging plugin  (Read 287703 times)

Offline JeroenZvZ

  • Newbie
  • *
  • Posts: 7
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #495 on: October 28, 2012, 07:14:52 am »
Chris,

It would be great if you could help us out on this one.

A separate plugin would be great  for it would give me an opportunity to learn how a (simple?) plugin is made and experiment a little. I read a couple of topics about plugin development but don't know how to start on programming a plugin. I would really appreciate it if you could come up with one for the NorthQ.


Offline Chris

  • Moderator
  • Hero Member
  • *****
  • Posts: 821
  • Karma: +3/-0
Re: New dataMine graphing and logging plugin
« Reply #496 on: October 28, 2012, 05:17:27 pm »
I'll take a look at it tomorrow. I don't think it will take very long (an hour or two). I'll post a separate thread in the plugin folder when I've got something to play with (since it's not strictly a dataMine issue).

Cheers
Chris

Offline JeroenZvZ

  • Newbie
  • *
  • Posts: 7
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #497 on: October 29, 2012, 05:22:47 pm »

Thanks Chris,

Looking forward to see what you come up with.

I've some book knowledge on programming and hope to learn from the source files how to setup a plugin. I've read up a bit on Lua but need a kickstarter. I think this would help me a lot.

Jeroen

Offline Chris

  • Moderator
  • Hero Member
  • *****
  • Posts: 821
  • Karma: +3/-0
Re: New dataMine graphing and logging plugin
« Reply #498 on: October 29, 2012, 05:30:57 pm »
Hi Joroen,
I've written the plugin - the easiest way to distribute, and for people to install the plugin was through the app store. So, it's currently awaiting MCV to approve it...

See http://forum.micasaverde.com/index.php/topic,12350.0.html and let me know how it goes...

Chris

Offline Francescobacchini

  • Newbie
  • *
  • Posts: 3
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #499 on: November 09, 2012, 07:37:51 am »
Hi! I'm very happy of having finally your plugin working. Great Job, but... I can't access to it from outside (https://fwd2.mios.com/dm/index.html) Is it a problem of my setup ?

Offline garrettwp

  • Master Member
  • *******
  • Posts: 6371
  • Karma: +227/-128
  • Vera 3, Lite, ISY994
Re: New dataMine graphing and logging plugin
« Reply #500 on: November 09, 2012, 07:50:06 am »
This has been discussed before in other posts of dataMine. Access outside of your network (especially from Mios's remote servers) is not possible.

- Garrett

Offline maaxmelbourne

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #501 on: December 11, 2012, 09:04:05 pm »
Greetings

Have one strange issue. All is working fine, but I try to log

a) inside temperature from the SQ Blaster
b) outside temperatire from Wunderground API

Both works well on the dashboard and SQ remote, but the logging throws both logs into one file, i.e both data sets in one graphical line. All other logs work without problem.

Any suggestion would be appreciated
Ax

Offline maaxmelbourne

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #502 on: December 11, 2012, 10:18:57 pm »
OK, solution!

It appears that the logger does not take room or device id into account when generating the log files. Though, I shut down vera, pulled the USB stick, format and back into vera.

Datamine at this stage does not yet record.

Make sure that the channels you want to log have different names (again, different room does not matter!), though rename them in the dashboard

In my case: Temperature (1) -> Inside Temperature & Temperature (2) -> Outside Temperature

Go back to DM setup and configure channels for recording.

Voila, all good (and as I have just started logging, no big loss in data, only the last 24hrs which is not a drama)

Have fun, and by the way, a fantastic application!!
Ax

Offline maaxmelbourne

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #503 on: December 12, 2012, 03:24:51 am »
Hi Chris

May I ask you to share some info about

a) the unit setting in the Variables Properties Section of the configuration tab?
b) what "drives" the y-axis scale? Some variables if graphed generate 2 unit scales, other just one which disturbs the graph

Example on b) is again the Wunderground API which logs beautifully, but when I graph wind direction and wind speed, the scale is translated to East/North/EastNorthEast etc overwriting the scale for wind from 1 to 10 (graph 1) or logging the direction full screen (graph 2)

Thanks for your feedback!!
« Last Edit: December 12, 2012, 03:27:08 am by maaxmelbourne »

Offline Chris

  • Moderator
  • Hero Member
  • *****
  • Posts: 821
  • Karma: +3/-0
Re: New dataMine graphing and logging plugin
« Reply #504 on: December 12, 2012, 06:17:34 am »
It appears that the logger does not take room or device id into account when generating the log files. Though, I shut down vera, pulled the USB stick, format and back into vera.

Datamine at this stage does not yet record.

Make sure that the channels you want to log have different names (again, different room does not matter!), though rename them in the dashboard
Yes, this is an issue that came up recently... DataMine uses the device name, and variable name to generate the filename. So, if you have the same device name for multiple devices, then this will generate the same filename. I started looking at putting a check into the software to stop this happening, but it's not completed yet as I've been away from home for the past week.

a) the unit setting in the Variables Properties Section of the configuration tab?
What is the question? Currently, this isn't used, but you can put W for Watts, C (or F) for temperature etc. Currently, dataMine uses the data type to put different channels onto the different axis, but I was considering changing this to use the "unit" setting as to me this makes more sense since sometimes different data types can still have the same data (if that makes sense!).

b) what "drives" the y-axis scale? Some variables if graphed generate 2 unit scales, other just one which disturbs the graph
I see your issue, but I'm not sure if I can change this. This is decided within the graphing library that I use - I don't think there's (easy) control over this I'm afraid.

Cheers
Chris

Offline maaxmelbourne

  • Newbie
  • *
  • Posts: 19
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #505 on: December 12, 2012, 08:23:15 pm »
Hi Chris

Thanks for the feedback. I thought that I may be able to force different axis by using the unit variable. Though, you plan sounds good.

Keep up the good work & Merry Christmas from Australia!
Ax

Offline skropko

  • Newbie
  • *
  • Posts: 8
  • Karma: +0/-1
Re: New dataMine graphing and logging plugin
« Reply #506 on: December 21, 2012, 11:23:40 am »
Chris,

I've been using dataMine for the last half year as it has been very helpful.  Thank you for the continued improvements.  One observation with the latest version.  I can no longer view my 'Thermostat - Mode State' data.  It appears to be logging ok in the dataMine directory but will not draw the graph when selected.  This had previously worked.  'Thermostat - Current Temperature' and 'Thermostat - Current Setpoint' continue to work and will draw the graph when selected.

Here is the contents of the dataMineConfig file...

{"Graphs":[],"Variables":[

{"Type":0,"Device":14,"Service":"urn:upnp-org:serviceId:TemperatureSensor1","Logging":1,"DataType":1,"Archive":"1 Thermostat - CurrentTemperature","LastRec":0,"Name":"Thermostat - CurrentTemperature","LastVal":0,"FirstRec":0,"Variable":"CurrentTemperature","Id":1,"Lookup":[]},

{"Type":0,"Device":14,"Service":"urn:micasaverde-com:serviceId:HVAC_OperatingState1","Logging":1,"DataType":0,"Archive":"2 Thermostat - ModeState","LastRec":0,"Name":"Thermostat - ModeState","LastVal":0,"FirstRec":0,"Variable":"ModeState","Id":2,"Lookup":[]},

{"Type":0,"Device":14,"Service":"urn:upnp-org:serviceId:TemperatureSetpoint1_Heat","Logging":1,"DataType":7,"Archive":"3 Thermostat - CurrentSetpoint","LastRec":0,"Name":"Thermostat - CurrentSetpoint","LastVal":0,"FirstRec":0,"Variable":"CurrentSetpoint","Id":3,"Lookup":[]}

],"nextId":4}



ID 1 and 3 work... 2 does not.

Here is the contents of the 2 Thermostat - ModeState [R2242].txt file...

1356106080,Idle
1356106600,Heating


I originally had 18 data points being logged.  I noticed some of them stopped drawing the graph in the latest update.  I removed dataMine (uninstalled the pluging and all the data in the dataMine folder) and did a clean install and added the 3 datapoints above but still have the issue.  Let me know your thoughts.

Thanks,
-Scott

Offline Chris

  • Moderator
  • Hero Member
  • *****
  • Posts: 821
  • Karma: +3/-0
Re: New dataMine graphing and logging plugin
« Reply #507 on: December 21, 2012, 12:44:06 pm »
Hi Scott,
I suspect a couple of issues... Firstly, I inadvertently commented out the code to draw graphs that have text data rather than numbers. I think it still should have graphed (??), but not printed the data correctly, but I'm not completely sure about that. The second issue is that as you've re-installed dataMine, you've lost some config data - the Lookup[] field in the config file is a conversion to numbers, and as this is now empty (due to the re-install) this will completely stop the graphing I think.

Now for the good news - I've fixed the initial problem, and the Lookup[] field will regenerate automatically as your thermostat mode changes over the next day or so...

Depending on how much time I get over the next day or so, I'll try and get a new version ready for MCV to approve on Monday (assuming they aren't on holiday!). Hopefully this will solve the problem - if it doesn't, let me know and I'll look into it again.

Cheers
Chris

Offline skropko

  • Newbie
  • *
  • Posts: 8
  • Karma: +0/-1
Re: New dataMine graphing and logging plugin
« Reply #508 on: December 21, 2012, 12:58:54 pm »
Thanks Chris for the quick response.  I will keep an eye on the lookup field to see if it regenerates the values in the config.  I'll also let you know on the code update once you find the time and the updated version is approved and installed.  Happy Holidays. -Scott

Offline jpitts

  • Sr. Newbie
  • *
  • Posts: 29
  • Karma: +0/-0
Re: New dataMine graphing and logging plugin
« Reply #509 on: December 23, 2012, 02:11:16 pm »
I've install the new datamine plugin on a vera3 following the overview doc and setup my usb drive. My /dataMine folder has a dataMineConfig.json file in it now, yet In the dataMine plugin I only have the dataMine and Advanced tabs I don't see a graph and config tab. I've tried restarting the vera3 multiple times and removed and reinstalled the plugin. Is there something else I need to do or a file I need to manually download to the vera3 ?