Page 4 of 29

Re: Toon App: Water

Posted: Fri Feb 12, 2021 6:47 pm
by westpat
Thank you for this great app! I have been waiting for this.
I use the analog gas sensor from Toon to read the water usage and produce JSON output with Node-red on a Raspberry Pi.

but here is my problem, I am unable to get into the configscreen to set the IP address and initial reading.
Every water tile I click brings me to the graph screen.

How do get into the configscreen?

Re: Toon App: Water

Posted: Fri Feb 12, 2021 8:54 pm
by Arnout2000
Ali is very slow in sending the parts. Days after ordering still not sent. I am impatient. :roll:

The Wemos is easy to find in NL, but does anyone have a link to a Webshop who can deliver the sensor?

Re: Toon App: Water

Posted: Fri Feb 12, 2021 8:57 pm
by oepi-loepi
Arnout2000 wrote:Ali is very slow in sending the parts. Days after ordering still not sent. I am impatient. :roll:

The Wemos is easy to find in NL, but does anyone have a link to a Webshop who can deliver the sensor?
Not cheap. But a user is also testing with the optical sensor which came with toon: viewtopic.php?f=99&t=13090&start=30#p97119

Re: Toon App: Water

Posted: Fri Feb 12, 2021 8:59 pm
by Jasper
Arnout2000 wrote:Ali is very slow in sending the parts. Days after ordering still not sent. I am impatient. :roll:

The Wemos is easy to find in NL, but does anyone have a link to a Webshop who can deliver the sensor?
Maybe because you are ordering during Chinese New Year, they don't work much during their holidays.

Re: Toon App: Water

Posted: Fri Feb 12, 2021 9:02 pm
by Jasper
https://www.benselectronics.nl/inductie ... 7sQAvD_BwE

Wel eens iets gekocht daar, persoonlijk denk ik dat heel veel gewoon van AliExpress komt. Kan het mis hebben maar kijk zelf maar even op z'n website rond.

Re: Toon App: Water

Posted: Fri Feb 12, 2021 9:13 pm
by oepi-loepi
Jasper wrote:https://www.benselectronics.nl/inductie ... 7sQAvD_BwE

Wel eens iets gekocht daar, persoonlijk denk ik dat heel veel gewoon van AliExpress komt. Kan het mis hebben maar kijk zelf maar even op z'n website rond.
Goed gevonden echter helaas niet de 5 vdc versie. Kan wel maar dan heb je een externe voeding voor de sensor nodig.

Re: Toon App: Water

Posted: Fri Feb 12, 2021 9:16 pm
by Jasper
Ik heb precies dezelfde, ook 6v en werkt prima op 5v

Re: Toon App: Water

Posted: Fri Feb 12, 2021 9:33 pm
by oepi-loepi
Jasper wrote:Ik heb precies dezelfde, ook 6v en werkt prima op 5v
Ok, bij mij niet maar prima. Dan had ik mss een defecte..Als je toch moet wachten op ali dan zou ik toch de 5 vdc zoals in de link adviseren. Gewoon voor de zekerheid.

Re: Toon App: Water

Posted: Fri Feb 12, 2021 9:56 pm
by Jasper
Kan ook net het vermogen van de adapter zijn natuurlijk.

Beter wachten dan op een supported versie.

Re: Toon App: Water

Posted: Fri Feb 12, 2021 9:58 pm
by westpat
westpat wrote:Thank you for this great app! I have been waiting for this.
I use the analog gas sensor from Toon to read the water usage and produce JSON output with Node-red on a Raspberry Pi.

but here is my problem, I am unable to get into the configscreen to set the IP address and initial reading.
Every water tile I click brings me to the graph screen.

How do get into the configscreen?
Figured it out and feeling a bit stupid about it! :oops:
When adding the water tiles for "Nu" and "Vandaag", choose the ones from the "Algemeen" section and not the ones from the "Water" section.

The optical gas sensor that came with Toon, now has been given a new life as a watermeter reader! :)

Re: Toon App: Water

Posted: Fri Feb 12, 2021 10:14 pm
by Arnout2000
Jasper wrote:
Arnout2000 wrote:Ali is very slow in sending the parts. Days after ordering still not sent. I am impatient. :roll:

The Wemos is easy to find in NL, but does anyone have a link to a Webshop who can deliver the sensor?
Maybe because you are ordering during Chinese New Year, they don't work much during their holidays.
Good point! Hadn’t thought of that.

Re: Toon App: Water

Posted: Fri Feb 12, 2021 10:19 pm
by oepi-loepi
westpat wrote:
The optical gas sensor that came with Toon, now has been given a new life as a watermeter reader! :)
Great, i will search for such sensor tomorrow and will check. Could you plae send met some pictures and a description how you connected the sensor?

Re: Toon App: Water

Posted: Fri Feb 12, 2021 10:57 pm
by Daniel
@oepi loepie On you Toon I see in "grafiek stroom gas water" But my Toon does not show the water in the graph screen.
Firmware is 5.39.7

Re: Toon App: Water

Posted: Sat Feb 13, 2021 12:41 am
by westpat
Short version of using a Toon optical (gas)sensor to read your watermeter.
The full description and flow source can be found here: flows.nodered.org

Place de optical sensor on the water meter (I have a sensus 620 from Vitens):
Image
It does take some tinkering to get it positioned right, but the way it is positioned in above picture works for me.

The 3.5 mm jack electrical assignment:
Image
I used a 3.5 mm female jack connector and soldered some Dupont jumper wires onto it, with the colors in the picture.
Then just plug the original white wire that came with the sensor in the sensor and the female jack.

Connect jumper wires to the Pi:
Image
Using Dupont jumper wires might not be the best kind of wires to use, since they are very thin and are susceptible to electrical interference causing false readings.

Now I use Node-red to receive and convert the information from the sensor, but that's just how I do it.

In Node-red add a pi gpiod node and configure like below:
Image
Make sure you set the resistor to Pull-up and give enough Debounce time.
Change the host to whatever IP address your Pi is running at or use the rpi-gpio in node if the pins are local to Node-red.

This will give you a 1 or 0 as output from the node everytime the metal part on the wheel in the meter passes along the optical sensor.
The sensor will generate a pulse when going from red plastic to metal and vice versa.
This means that 2 pulses equal 1 liter of water, so remember to divide the number of pulses by 2 to get water consumption in liters.

I also incorporated the P1 data into my Node-red flow, which I need to convert to DSMR 2.2 to feed my Meetmodule.
And since we have all the data at hand, why not output it over a TCP connection and MQTT as well.
This is what my flow looks like:
Image

I don't think this forum is the right place to go into detail about this flow, but this is what happens:
  • The PIN 7 feeds the counterGlobal with pulses and these are added up to the meter total and stored in memory
  • From that total the previous reading from 15 seconds ago is subtracted, giving us the usage in liters
  • This usage is multiplied by 4 to get a flowrate of liters per minute, which is also stored in memory
  • Whenever the http in node receives a request, the stored values are returned as a JSON string: {"waterflow":"0","waterquantity":"438730"}
So besides feeding Toon with data this way, I can feed any number of devices with data.
Like for example Domoticz:
Image
Or my Node-red Dashboard:
Image

That's all folks! :)

Re: Toon App: Water

Posted: Sat Feb 13, 2021 9:19 am
by oepi-loepi
Daniel wrote:@oepi loepie On you Toon I see in "grafiek stroom gas water" But my Toon does not show the water in the graph screen.
Firmware is 5.39.7
Did you do the app install, set the ip adress an did you click save on the configuration screen? The toon should restart and after that the tiles in. The water tab become visible. Select the grap with the 3 vertical bars and click that tile.