GEM Data Format
-
- Posts: 16
- Joined: Sat Mar 10, 2018 2:32 pm
GEM Data Format
I am trying to use the GEM raw data that is posted to my server but I do not fully understand how to convert it to kilowatt hours that match the Dashbox values.
I thought I could use the V x I x PF to get similar values to Dashbox and sometimes it matches up, but other times it is not even close.
Also what is the "polarized" data and can I determine generate/use data from it?
My goal is to display power readings in my own application. Is there any documentation that explains how to use this data to get actual kwh values? Any helpful info would be appreciated.
Thanks, Gary
I thought I could use the V x I x PF to get similar values to Dashbox and sometimes it matches up, but other times it is not even close.
Also what is the "polarized" data and can I determine generate/use data from it?
My goal is to display power readings in my own application. Is there any documentation that explains how to use this data to get actual kwh values? Any helpful info would be appreciated.
Thanks, Gary
-
- Site Admin
- Posts: 4269
- Joined: Fri Jun 04, 2010 9:39 am
Re: GEM Data Format
Gary,
There's some notes in the packet format manual (pg 29):
http://brultech.com/software/files/down ... at_2_1.pdf
Polarized counters are used for generation.
Deltas = Current Sample - Previous Sample (with a check for counter rollovers)
Watt = (Delta Wattseconds ) / Delta Seconds
kWh = (Delta Wattseconds ) / 3600000
If monitoring a net metered source:
NET Watt = (Delta Wattseconds - 2 * Delta Polarized) / Delta Seconds
NET kWh = (Delta Wattseconds - 2 * Delta Polarized) / 3600000
There's some notes in the packet format manual (pg 29):
http://brultech.com/software/files/down ... at_2_1.pdf
Polarized counters are used for generation.
Deltas = Current Sample - Previous Sample (with a check for counter rollovers)
Watt = (Delta Wattseconds ) / Delta Seconds
kWh = (Delta Wattseconds ) / 3600000
If monitoring a net metered source:
NET Watt = (Delta Wattseconds - 2 * Delta Polarized) / Delta Seconds
NET kWh = (Delta Wattseconds - 2 * Delta Polarized) / 3600000
Ben
Brultech Research Inc.
E: ben(at)brultech.com
Brultech Research Inc.
E: ben(at)brultech.com
-
- Posts: 16
- Joined: Sat Mar 10, 2018 2:32 pm
Re: GEM Data Format
Hi Ben,
That is what I was looking for, I'll see what I can do with this.
Thanks!
Gary
That is what I was looking for, I'll see what I can do with this.
Thanks!
Gary
-
- Site Admin
- Posts: 4269
- Joined: Fri Jun 04, 2010 9:39 am
Re: GEM Data Format
You could always use btmon.py to process the packets also and dump them into a database.pcrover wrote:Hi Ben,
That is what I was looking for, I'll see what I can do with this.
Thanks!
Gary
https://github.com/matthewwall/mtools/b ... n/btmon.py
Ben
Brultech Research Inc.
E: ben(at)brultech.com
Brultech Research Inc.
E: ben(at)brultech.com
-
- Posts: 16
- Joined: Sat Mar 10, 2018 2:32 pm
Re: GEM Data Format
It appears I don't understand the Polarized Counters concept. Using either of the formulas to calculate standard or polarized power I get identical readings, but neither are "Polarized" as in + or -. The results appear as a positive number even if Generation is happening on the port. What am I missing here?
Gary
Gary
-
- Posts: 2700
- Joined: Wed Dec 15, 2010 4:09 pm
- Location: The Bad Lands
Re: GEM Data Format
Unless you're generating power via solar, wind, that value will have zero meaning to you.pcrover wrote:It appears I don't understand the Polarized Counters concept. Using either of the formulas to calculate standard or polarized power I get identical readings, but neither are "Polarized" as in + or -. The results appear as a positive number even if Generation is happening on the port. What am I missing here?
Gary
I.e. Unless you're actually generating power you won't see any values. Also if you have a GEM the value can be changed to reflect positive vs negative in any channel.
Sent from my iPhone using Tapatalk
Teken . . .
My ongoing projects thread: http://www.brultech.com/community/viewt ... ?f=2&t=929
Buy me a cup of coffee: https://www.paypal.me/Teken https://gfinotify.com/ Discount Code: PC10
My ongoing projects thread: http://www.brultech.com/community/viewt ... ?f=2&t=929
Buy me a cup of coffee: https://www.paypal.me/Teken https://gfinotify.com/ Discount Code: PC10
-
- Site Admin
- Posts: 4269
- Joined: Fri Jun 04, 2010 9:39 am
Re: GEM Data Format
Did you enable NET Metering on the channel in the GEM Setup Webpage under Channel Option? It won't count generation unless you enable it.
Ben
Brultech Research Inc.
E: ben(at)brultech.com
Brultech Research Inc.
E: ben(at)brultech.com
-
- Posts: 16
- Joined: Sat Mar 10, 2018 2:32 pm
Re: GEM Data Format
I just found an error in my code that could be the problem. I'll see what happens today when the solar starts generating.
-
- Posts: 16
- Joined: Sat Mar 10, 2018 2:32 pm
Re: GEM Data Format
Yep, It was my code. All good now.
Thanks for the help!
Gary
Thanks for the help!
Gary