www.homeseer.com    
 

Go Back   HomeSeer Message Board > HomeSeer Products & Services > HomeSeer General Discussion Area

HomeSeer General Discussion Area General discussion about HomeSeer that does not fall into any other category or are not specific to 1.x or 2.x versions of HomeSeer.

Reply
 
Thread Tools Display Modes
  #21  
Old December 30th, 2017, 04:55 PM
vasrc's Avatar
vasrc vasrc is offline
Seer Master
 
Join Date: May 2003
Location: Locust Dale, VA
Posts: 1,214
Quote:
Originally Posted by vasrc View Post
Here's my settings. ini
ScriptingReferences=System.Web.Script;System.Web.Extensions. dll

System.Web.Extensions.dll is located in:

/bin/scripts

Z
make that:

/bin/scripting/
Reply With Quote
  #22  
Old December 30th, 2017, 05:08 PM
macrho's Avatar
macrho macrho is offline
Seer Deluxe
 
Join Date: May 2015
Location: Middle of Nowhere
Posts: 291
Ok, I have now:

ScriptingReferences=System.Drawing;System.Drawing.dll;System .Web.Script;System.Web.Extensions.dll

System.Web.Extensions.dll located in: C:\Program Files\HomeSeer HS3\Bin\scripting

I only edited the lines noted in your VB file and it still throws error after restarting hs3:

Code:
Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Type 'JavaScriptSerializer' is not defined.

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Type 'JavaScriptSerializer' is not defined.

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Type 'JavaScriptSerializer' is not defined.
Dec-30 4:04:14 PM	 

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Namespace or type specified in the Imports 'System.Web.Script.Serialization' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Namespace or type specified in the Imports 'System.Core' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.
Reply With Quote
  #23  
Old December 30th, 2017, 06:25 PM
vasrc's Avatar
vasrc vasrc is offline
Seer Master
 
Join Date: May 2003
Location: Locust Dale, VA
Posts: 1,214
Quote:
Originally Posted by macrho View Post
Ok, I have now:

ScriptingReferences=System.Drawing;System.Drawing.dll;System .Web.Script;System.Web.Extensions.dll

System.Web.Extensions.dll located in: C:\Program Files\HomeSeer HS3\Bin\scripting

I only edited the lines noted in your VB file and it still throws error after restarting hs3:

Code:
Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Type 'JavaScriptSerializer' is not defined.

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Type 'JavaScriptSerializer' is not defined.

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Type 'JavaScriptSerializer' is not defined.
Dec-30 4:04:14 PM	 

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Namespace or type specified in the Imports 'System.Web.Script.Serialization' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.

Error Compiling script C:\Program Files\HomeSeer HS3\scripts\TankUtility.vb: Namespace or type specified in the Imports 'System.Core' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.
Put a comma in between the two entries:
ScriptingReferences=System.Drawing;System.Drawing.dll,System .Web.Script;System.Web.Extensions.dll
Reply With Quote
  #24  
Old December 30th, 2017, 06:40 PM
macrho's Avatar
macrho macrho is offline
Seer Deluxe
 
Join Date: May 2015
Location: Middle of Nowhere
Posts: 291
Quote:
Originally Posted by vasrc View Post
Put a comma in between the two entries:
ScriptingReferences=System.Drawing;System.Drawing.dll,System .Web.Script;System.Web.Extensions.dll
bingo! that worked! but how on Earth did you know that? I'm not sure why I have the drawing reference... Off to see if I can find a decent graphic to mimic the TankUtility app -- battery percentage isn't clean enough

Happy New Year
Reply With Quote
  #25  
Old January 1st, 2018, 10:24 PM
wpiman's Avatar
wpiman wpiman is offline
Seer Master
 
Join Date: Jun 2002
Location: Carlisle, MA
Posts: 931
Interesting. I will post the one I wrote. I assumed the device and token won't change-- so mine makes the one JSON call to tank utility, but you have to get your token and device number.

The line below would need to be updated....

'Change 012345 with your device number
'Chance abcdef.ghijkl.mnop-qrst-uvwyz with your token
Dim Query As String = hs.GETURL("https://data.tankutility.com/api/devices/012345?token=abcdef.mnop.qrst-uvwyz","",False,80)

The procedure here would need to be followed to obtain the token and the device number...

http://apidocs.tankutility.com/#introduction

Mine will create the devices at the Room and device Letter..

It will also show you how much is in the tank and how many days you can expect to last using the same amount as the previous day... I will probably change that to use a moving average.

I posted a picture of the devices in the room it creates...

I'll have to try to load this other script....
Attached Images
 
Attached Files
File Type: txt tankUtility.txt (5.3 KB, 45 views)
__________________
HS3 Pro Edition 3.0.0.368 (Windows Server 8 on ESXi box)
2 Znets- Ecobee
Reply With Quote
  #26  
Old January 2nd, 2018, 03:14 PM
macrho's Avatar
macrho macrho is offline
Seer Deluxe
 
Join Date: May 2015
Location: Middle of Nowhere
Posts: 291
I'm trying to get your code to run but I keep getting an error:
Code:
Exception has been thrown by the target of an invocation.
Unexpected character encountered while parsing value: E. Path '', line 0, position 0.
I'm not sure what is going on here?
Reply With Quote
  #27  
Old January 2nd, 2018, 04:47 PM
macrho's Avatar
macrho macrho is offline
Seer Deluxe
 
Join Date: May 2015
Location: Middle of Nowhere
Posts: 291
Turns out that I was using the wrong device number, I was using the ID. Once I got a token, I was able to get my device number:

https://data.tankutility.com/api/dev...OUR_TOKEN_HERE

Jon00 has a device grouping utility so that all the fields can be grouped in one logical container
Reply With Quote
  #28  
Old January 2nd, 2018, 05:01 PM
vasrc's Avatar
vasrc vasrc is offline
Seer Master
 
Join Date: May 2003
Location: Locust Dale, VA
Posts: 1,214
Quote:
Originally Posted by wpiman View Post
Interesting. I will post the one I wrote. I assumed the device and token won't change-- so mine makes the one JSON call to tank utility, but you have to get your token and device number.

The line below would need to be updated....

'Change 012345 with your device number
'Chance abcdef.ghijkl.mnop-qrst-uvwyz with your token
Dim Query As String = hs.GETURL("https://data.tankutility.com/api/devices/012345?token=abcdef.mnop.qrst-uvwyz","",False,80)

The procedure here would need to be followed to obtain the token and the device number...

http://apidocs.tankutility.com/#introduction

Mine will create the devices at the Room and device Letter..

It will also show you how much is in the tank and how many days you can expect to last using the same amount as the previous day... I will probably change that to use a moving average.

I posted a picture of the devices in the room it creates...

I'll have to try to load this other script....

Nice work !

Z
Reply With Quote
  #29  
Old January 2nd, 2018, 06:55 PM
scorp508 scorp508 is offline
Seer Deluxe
 
Join Date: Jun 2016
Location: Boston, MA
Posts: 262
Wow I'm stoked this thread exists. We're changing propane providers in a couple weeks and I plan on using TankUtility. Nice to see some of you pioneers already went and did the hard work.
Reply With Quote
  #30  
Old January 2nd, 2018, 07:42 PM
wadesready wadesready is offline
Seer Deluxe
 
Join Date: Mar 2017
Location: cabo rojo puerto rico
Posts: 293
I've been following this thread with keen interest also. I have a class A rv with a 32 gallon propane tank and I would like to adapt your work to it. Thanks!
Reply With Quote
  #31  
Old January 3rd, 2018, 02:40 PM
wpiman's Avatar
wpiman wpiman is offline
Seer Master
 
Join Date: Jun 2002
Location: Carlisle, MA
Posts: 931
Quote:
Originally Posted by scorp508 View Post
Wow I'm stoked this thread exists. We're changing propane providers in a couple weeks and I plan on using TankUtility. Nice to see some of you pioneers already went and did the hard work.
Where in Boston are you? We have Eastern Propane and they are terrible. Switching to Haeffner's in the spring. About 35% cheaper...
Reply With Quote
  #32  
Old January 3rd, 2018, 03:36 PM
scorp508 scorp508 is offline
Seer Deluxe
 
Join Date: Jun 2016
Location: Boston, MA
Posts: 262
Quote:
Originally Posted by wpiman View Post
Where in Boston are you? We have Eastern Propane and they are terrible. Switching to Haeffner's in the spring. About 35% cheaper...

I'm actually about 45 miles south in Lakeville and just put Boston there so people quickly have a general idea where.
Reply With Quote
  #33  
Old January 3rd, 2018, 06:36 PM
wpiman's Avatar
wpiman wpiman is offline
Seer Master
 
Join Date: Jun 2002
Location: Carlisle, MA
Posts: 931
Quote:
Originally Posted by scorp508 View Post
I'm actually about 45 miles south in Lakeville and just put Boston there so people quickly have a general idea where.
Oh yeah. We have a family beach house on the water in Wareham, so go by there in the Summer. I actually have a Znet there and a VPN to my house so I can control that house too...
Reply With Quote
  #34  
Old January 5th, 2018, 09:47 AM
macrho's Avatar
macrho macrho is offline
Seer Deluxe
 
Join Date: May 2015
Location: Middle of Nowhere
Posts: 291
Looks like the TankUtility only takes reading once a day
I added a few more fields to the script
Attached Images
 
Reply With Quote
  #35  
Old January 5th, 2018, 10:01 AM
wpiman's Avatar
wpiman wpiman is offline
Seer Master
 
Join Date: Jun 2002
Location: Carlisle, MA
Posts: 931
Quote:
Originally Posted by macrho View Post
Looks like the TankUtility only takes reading once a day
I added a few more fields to the script
Yeah, for the most part that makes sense as usage is often gradual.

I have a generator and when that thing kicks on, the usage can go way up.

Looks good; glad someone else is making use of it. Are you getting that propane price remotely or is that something you are manually entering?

The cheapest propane I found around here is $1.99 a gallon. My company is boning me at $2.70.
Reply With Quote
  #36  
Old January 5th, 2018, 10:06 AM
macrho's Avatar
macrho macrho is offline
Seer Deluxe
 
Join Date: May 2015
Location: Middle of Nowhere
Posts: 291
They are talking about -30 this weekend, hopefully that doesn't happen
Last time the power went out at around -20 and the generator didn't kick on
I manually entered the propane price
I modified your code to retrieve the device id so I shouldn't have to touch the code again (or until their API changes)
I wonder how much work it is to create a plugin. I'm not a vb.net guy but can work my way through it, more or less
Reply With Quote
  #37  
Old January 5th, 2018, 11:51 AM
wpiman's Avatar
wpiman wpiman is offline
Seer Master
 
Join Date: Jun 2002
Location: Carlisle, MA
Posts: 931
I don't think their API will change much. It is published, so usually if they were to modify it, they would add to it. I think I read there was talk about reporting battery status. That can be kind of tricky.
Reply With Quote
  #38  
Old January 5th, 2018, 01:16 PM
scorp508 scorp508 is offline
Seer Deluxe
 
Join Date: Jun 2016
Location: Boston, MA
Posts: 262
The ability to temporarily increase the reporting frequency would be a nice touch. Something that basically says "Decrease time between reports to X hours for the next Y reports." As someone mentioned if you're running on generator you may want a bit more vision into how you're doing if it is an extended power outage. Or just look at the gauge I suppose... but what fun is that?
Reply With Quote
  #39  
Old January 5th, 2018, 01:59 PM
wpiman's Avatar
wpiman wpiman is offline
Seer Master
 
Join Date: Jun 2002
Location: Carlisle, MA
Posts: 931
I think there is a spot on it which will cause it to issue a reading if a magnet passes over it. Might be possible to have a little electro magnet fire from HS. Maybe a 9 volt battery might be needed...
Reply With Quote
  #40  
Old January 6th, 2018, 09:34 PM
steevireno steevireno is offline
Seer
 
Join Date: Jan 2016
Location: Pennsylvania
Posts: 27
Multiple tanks...

Hi guys. So glad I found this script.

What do you do when you have multiple tanks? I have 3 and want to get them all into HS.

Thanks!

Steve
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Propane level monitoring with RD3 hall-effect sensor Rico ADI Ocelot 23 March 25th, 2015 12:39 PM
Monitoring HS3 log Lio HS3 / HS3PRO Discussion 2 January 30th, 2015 11:09 AM
wireless propane sensor collegeboyslive HomeSeer General Discussion Area 11 April 2nd, 2010 09:08 PM
UPS Monitoring donstephens Script & Plug-In Library Discussion 2 June 23rd, 2007 03:49 PM
2.6.192 monitoring bunkers mcsSprinklers 0 July 17th, 2006 01:18 AM


All times are GMT -4. The time now is 04:04 AM.


Copyright HomeSeer Technologies, LLC