Closed speters0 closed 3 years ago
Sounds like a useful addition. Let me review the code and look at integrating this feature.
I integrated most of your changes, however I had to make some tweaks so there is not impact to people not using two tanks. In short you just need to add
nb_tanks = 2
to /etc/genmon/gentankdiy.conf and restart genmon. A refresh of the browser would need to be done if the browser is open while genmon restarted.
Two gauges are shown on the main page if this is enabled. Note: this only applies to type 1 DIY gauges. Type 2 DIY gauge only supports one instance at the moment.
Let me know if you have any issues.
@jgyates in the same idea as @speters0 I also live in the Northern Laurentians in Quebec and for the same reasons I have 3 tanks instead of 2. How much work would it be to be able to monitor 3 tanks instead of 2?
That is do-able. I will try to do that soon. I will update this thread when complete. Let me know once you have a chance to test this as I do not have three tanks to test with :)
@davisgoodman, just to clarify, are you OK with creating your own gauges with the method in this wiki entry:
See DIY tanks gauge method one. This is the only type of gauge that currently supports multiple instances.
Yes, that's the one with the original sensors from Rochester Gauges. I've reached out to them to find a place to get these sensors. That will probably be the toughest part as it seems only OEMs can get them. But technically I'm good to build it
OK. The DIY Tank Method 1 is the only one that supports multiple tanks.
Ok. As soon as I can put my hand on those sensors, I’ll update the thread.
From: jgyates @.> Sent: 10 avril 2022 22:21 To: jgyates/genmon @.> Cc: davisgoodman @.>; Comment @.> Subject: Re: [jgyates/genmon] Modification to allow a two propane tank gauges with [gentankdiy] (#548)
That is do-able. I will try to do that soon. I will update this thread when complete. Let me know once you have a chance to test this as I do not have three tanks to test with :)
— Reply to this email directly, view it on GitHub https://github.com/jgyates/genmon/issues/548#issuecomment-1094476693 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AI7MAZQHPDNJYYUWH2RE2JLVEOD7ZANCNFSM466HPBBQ . You are receiving this because you commented. https://github.com/notifications/beacon/AI7MAZUIRVYJWAPPWC63OKLVEOD7ZA5CNFSM466HPBB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOIE6GHFI.gif Message ID: @. @.> >
@davisgoodman
I have added support for up to 4 tanks (the max supported by the design of the circuit). These updates are checked in but I have not increased the version number yet. Let me know once you have an opportunity to test.
Wow.. Thanks. As soon as I can put my hands on those sensors I sure will.
I'll reach out to speter0 to find out where he got his.
From: jgyates @.> Sent: Monday, April 11, 2022 3:34:53 PM To: jgyates/genmon @.> Cc: davisgoodman @.>; Mention @.> Subject: Re: [jgyates/genmon] Modification to allow a two propane tank gauges with [gentankdiy] (#548)
@davisgoodmanhttps://github.com/davisgoodman
I have added support for up to 4 tanks (the max supported by the design of the circuit). These updates are checked in but I have not increased the version number yet. Let me know once you have an opportunity to test.
— Reply to this email directly, view it on GitHubhttps://github.com/jgyates/genmon/issues/548#issuecomment-1095480082, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AI7MAZRNCNCWTRCTMTIB5Q3VER5F3ANCNFSM466HPBBQ. You are receiving this because you were mentioned.Message ID: @.***>
Hi,
I'm living in the northern Laurentians Quebec, Canada where temperature can get as low as -40°C I have a 16KW Generac generator and a 5 burner Cooktop. They all run on propane gas. I have two 420lb propane tanks. And the reason why I have two tanks is: If It gets too cold the propane gas might freeze if I have only one tank. If the demand on pressurized gas is high, the pressure drop at the outlet of the tank regulator will lower the temperature substantially at that point. It is the thermodynamic law. By having two tanks, the pressure drop at each outlet is less and it minimize the chance of gas freeze. Lot of peoples on northern locations uses at least a two tank setup.
I'm using DIY thank Method 1 and adding two Propane Fuel Gauge (on on each tank). The liquid propane level on each tank can lower at a different rate depending on brass fitting diameter and the length of the gas line.
So I decided to modify Genmon Program to accommodate for a two Gauge setup.
The is a new option in the setup file: gentankdiy.conf
number of tanks (1 or 2)
nb_tanks = 1
If the value is 2
There is a new External Tank Gauge that will display on the [Status] page of Genmon. In the [Maintenance] page, the fields (Fuel Level Sensor) and (Fuel in tank (sensor)) are calculated with the mean value of both gauges.
The modification has been made on Version V1.16.09
It is only applied on Evolution Controller
Here is the list of the modified files:
/home/pi/genmon/conf/gentankdiy.conf /home/pi/genmon/genmonlib/gaugediy.py /home/pi/genmon/gentankdiy.py /home/pi/genmon/genmonlib/controller.py /home/pi/genmon/genmonlib/generac_evolution.py Genmon.zip
If you wish it could be interesting to have a look at the code, adjust it if needed, and merge it to the latest version.⍺
I will upload these files on github site.
Thank you!
@speters0 I just asked @jgyates for making this available for 3 tanks and he actually made it for up to 4.
I also live in the Northern Laurentians and was wondering where you sourced the sensors for the tanks. I reached out directly to Rochester gauges who sent me a few distributor/OEM located in Quebec. Reading on their website though, seems only those OEM can buy it. Most of them are IoT solutions resellers for tank metering. I doubt they'll be open to sell me just the sensors.
Hi,
I bought the gauges at: https://www.petroviron.ca/
Thanks, that’s actually one of the distributors they gave me.
I’ll phone them up.
From: speters0 @.> Sent: 11 avril 2022 17:53 To: jgyates/genmon @.> Cc: davisgoodman @.>; Mention @.> Subject: Re: [jgyates/genmon] Modification to allow a two propane tank gauges with [gentankdiy] (#548)
Hi,
I bought the gauges at: https://www.petroviron.ca/
— Reply to this email directly, view it on GitHub https://github.com/jgyates/genmon/issues/548#issuecomment-1095604583 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AI7MAZUTAVAJMSPAESCFQK3VESNNLANCNFSM466HPBBQ . You are receiving this because you were mentioned. https://github.com/notifications/beacon/AI7MAZU2HSCLDSHNEVLPBWDVESNNLA5CNFSM466HPBB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOIFGZSZY.gif Message ID: @. @.> >
@speters0Thanks for the lead, I have 4 sensors on their way.On 11 avr. 2022, at 17 h 53, speters0 @.> wrote:Hi,I bought the gauges at: https://www.petroviron.ca/—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: @.>
Still wating to get my sensors but updated genmon on my RaspPI.
Maybe just something that was missed but the gentankdiy.conf still shows:
nb_tanks = 1
I guess only the comment needs to reflect the update
From: jgyates @.> Sent: 10 avril 2022 23:33 To: jgyates/genmon @.> Cc: davisgoodman @.>; Mention @.> Subject: Re: [jgyates/genmon] Modification to allow a two propane tank gauges with [gentankdiy] (#548)
OK. The DIY Tank Method 1 is the only one that supports multiple tanks.
— Reply to this email directly, view it on GitHub https://github.com/jgyates/genmon/issues/548#issuecomment-1094508087 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AI7MAZSCEGGSG2O546BNAE3VEOMOFANCNFSM466HPBBQ . You are receiving this because you were mentioned. https://github.com/notifications/beacon/AI7MAZWWQGLR4TNSNCRBRT3VEOMOFA5CNFSM466HPBB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOIE6N4NY.gif Message ID: @. @.> >
The file /etc/genmon/gentankdiy.conf does not get updated however the file in /home/pi/genmon/conf/gentankdiy.conf does get updated. If the files in /etc/genmon were updated every update it would wipe out your site specific settings.
Indeed, didn't realize it.
From: jgyates @.> Sent: Wednesday, April 13, 2022 10:38:23 PM To: jgyates/genmon @.> Cc: davisgoodman @.>; Mention @.> Subject: Re: [jgyates/genmon] Modification to allow a two propane tank gauges with [gentankdiy] (#548)
The file /etc/genmon/gentankdiy.conf does not get updated however the file in /home/pi/genmon/conf/gentankdiy.conf does get updated. If the files in /etc/genmon were updated every update it would wipe out your site specific settings.
— Reply to this email directly, view it on GitHubhttps://github.com/jgyates/genmon/issues/548#issuecomment-1098652367, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AI7MAZVPLMCSWSX45IALTSLVE6AJ7ANCNFSM466HPBBQ. You are receiving this because you were mentioned.Message ID: @.***>
Tank gauges still working great with the last mod!
Glad to hear!
Can’t wait to get my 3 tanks hooked up.
From: speters0 @.> Sent: 14 avril 2022 20:34 To: jgyates/genmon @.> Cc: davisgoodman @.>; Mention @.> Subject: Re: [jgyates/genmon] Modification to allow a two propane tank gauges with [gentankdiy] (#548)
Tank gauges still working great with the last mod!
— Reply to this email directly, view it on GitHub https://github.com/jgyates/genmon/issues/548#issuecomment-1099742043 , or unsubscribe https://github.com/notifications/unsubscribe-auth/AI7MAZUJIYCMYLE7BNRFRB3VFC2PDANCNFSM466HPBBQ . You are receiving this because you were mentioned. https://github.com/notifications/beacon/AI7MAZSPK2RVTQ6SA7O34Q3VFC2PDA5CNFSM466HPBB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOIGGLWWY.gif Message ID: @. @.> >
Well got my gauges today and all installed.
Few questions, when 3 gauges are installed is the "20%" averaged across all 3 gauges? Do they need to be calibrated? Is there a config for setting the threshold (20%)? Is there a way to send out only "Low Fuel" emails as I may want to send the emails directly to my Propane provider but wouldn't want have any other kind of notifications from Genmon?
Also would there be a way to export the tank readings through MQTT, would allow to integrate them with Home Assistant
Genmon will send email notices at 10% and 20% fuel levels. Short message notices for add ons (SMS, etc) are sent at 20%. When multiple tanks are configured this is the average of the total tanks.
I will leave the calibration question to others as I do not know the answer. For type 1 gauges, i assume no but I do not know for sure.
There is not a configuration setting for fuel level percentage notices.
Low Fuel messages are sent in the "warn" category on the Notifications page. and in "Warning" category for short messages for Add ons. Other types of messages are also in the warning category.
I can look into the MQTT export.
Thanks for the response. I suppose there are other kind of warning that would go out in this category which I wouldn't want to send them. For now I'll notify them when I get it.
I checked in a mod to show readings of each tank on the maintenance page and they will also be exported via MQTT.
Upgraded to the latest. On the maintenance page I only get the average as well as in MQTT
any errors in /var/log/genmon.log?
any errors in /var/log/genmon.log?
Nothing particular: 2022-04-18 18:33:11,945 : GenMon Loaded for site: 105 Des Gardénias, Val-David using python 3.9 2022-04-18 19:46:47,400 : Generator Monitor Shutdown 2022-04-18 19:46:50,903 : Selected Controller: generac_evo_nexus 2022-04-18 19:46:52,093 : GenMon Loaded for site: 105 Des Gardénias, Val-David using python 3.9 2022-04-18 20:10:20,725 : Generator Monitor Shutdown 2022-04-18 20:10:23,570 : Selected Controller: generac_evo_nexus 2022-04-18 20:10:24,767 : GenMon Loaded for site: 105 Des Gardénias, Val-David using python 3.9
send your logs from the about page. This requires outbound email to be working. If you don't have outbound email let me know and we can to this a different way.
Done!
try this:
edit the file /etc/genmon/gentankdiy.conf
add the line
debug = True
to the end of the file, save the file, restart genmon, wait 20 seconds, then send me the logs again
I don't have the hardware on the i2c but if you enable "debug" in the gentankdiy.conf file it will ignore fatal errors and output more info to the log. The gauges data is displaying for me with debug enabled.
also the info on the maint page is displaying for me.
Try updating the repository again. I think I forgot to push the update. Hopefully that corrects the issue. Let me know
also, if this works take out the debug=True from the /etc/genmon/gentankdiy.conf file as that extra log info can put unneeded wear on your SD card.
:-(
Still....
Just submitted the logs .....
update to the latest, then send logs
Upgraded and sent logs. Still only seeing the average
it looks like github is not updating the repository at your location or for some other reason you are not getting the update. I put some additional log output in the latest update but your logs do not show this info.
For example link 92 of ./genmon/gentankdiy.py should be
self.LogDebug("Num Tanks: " + str(self.nb_tanks))
and I am showing this in the repository but I would guess that your pi does not have this update.
https://github.com/jgyates/genmon/blob/f1a01f7af3433bf7cbda5c39d4ac71042a01d4e2/gentankdiy.py#L92
Did a test I created a separate directory and when trying to clone the repo I'm getting this: pi@generac:~/gitdownload $ git clone https://github.com/jgyates/genmon.git Cloning into 'genmon'... error: git-remote-https died of signal 4
Ok so the issue is definitely the update.
For testing I copy/pasted gaugediy.py from the repo into a new file and diff and the one on my side missed 12 lines of codes
you can also manually update with this command from the genmon folder.
./genmonmain.sh -u
This ends up calling these commands:
git fetch origin
git reset --hard origin/master
If you have some sort of connectivity issue with github this would cause the problem we are seeing.
when you select update form the web interface it ends up calling genmonmain.sh
So you're right, some issues with GitHub.
pi@generac:~/genmon $ ./genmonmaint.sh -u This script will update genmon to the latest version from the github repository. This script requires internet access. If you have modified any files in the genmon directory, they will be overwritten. Configuration files in the configuration directory will not be overritten. Continue? (y/n) y Updating genmon... error: git-remote-https died of signal 4 HEAD is now at 02f447e V1.18.10 Done.
Just let me know which files been mofidied, I'll pickup only those ones and replace them
I believe gaugesdiy.py, controller.py, tooltips.txt, gettankdiy.py
/genmon/gentankdiy.py /genmon/genmonlib/controller.py /genmon/genmonlib/gaugediy.py
toottips.txt also, but that one is not critical, just some text for the UI help bubbles related to multiple tanks.
Well I now see all three gauges in the Maintenance, though MQTT has lost the Maintenance export
send logs
And something doesn't jive in the numbers. Fuel Level Sensors seems to be the average which makes sense but then we should have 3 more readings 1 for each tank. Or have only 3 readings 1 per tank.
Just submitted the logs
Hi,
I'm living in the northern Laurentians Quebec, Canada where temperature can get as low as -40°C I have a 16KW Generac generator and a 5 burner Cooktop. They all run on propane gas. I have two 420lb propane tanks. And the reason why I have two tanks is: If It gets too cold the propane gas might freeze if I have only one tank. If the demand on pressurized gas is high, the pressure drop at the outlet of the tank regulator will lower the temperature substantially at that point. It is the thermodynamic law. By having two tanks, the pressure drop at each outlet is less and it minimize the chance of gas freeze. Lot of peoples on northern locations uses at least a two tank setup.
I'm using DIY thank Method 1 and adding two Propane Fuel Gauge (on on each tank). The liquid propane level on each tank can lower at a different rate depending on brass fitting diameter and the length of the gas line.
So I decided to modify Genmon Program to accommodate for a two Gauge setup.
The is a new option in the setup file: gentankdiy.conf
number of tanks (1 or 2)
nb_tanks = 1
If the value is 2
There is a new External Tank Gauge that will display on the [Status] page of Genmon. In the [Maintenance] page, the fields (Fuel Level Sensor) and (Fuel in tank (sensor)) are calculated with the mean value of both gauges.
The modification has been made on Version V1.16.09
It is only applied on Evolution Controller
Here is the list of the modified files:
/home/pi/genmon/conf/gentankdiy.conf /home/pi/genmon/genmonlib/gaugediy.py /home/pi/genmon/gentankdiy.py /home/pi/genmon/genmonlib/controller.py /home/pi/genmon/genmonlib/generac_evolution.py Genmon.zip
If you wish it could be interesting to have a look at the code, adjust it if needed, and merge it to the latest version.⍺
I will upload these files on github site.
Thank you!