Page 3 of 3

Re: Toon app: Zon op Toon using PVoutput

Posted: Sun Aug 20, 2017 10:53 pm
by marcelr
Interesting solution. You might pass the digital signal from your raspi straight into the meter adapter, without the leds and the phototransistor (which together form an optocoupler, basically).

Re: Toon app: Zon op Toon using PVoutput

Posted: Mon Aug 21, 2017 8:26 am
by TheHogNL
Yeah I want to try that later. Was not sure if the mini jack input could just receive the digital input and don't know the power levels and pin layout. When I have more time I will try to figure that out.

Re: Toon app: Zon op Toon using PVoutput

Posted: Mon Aug 21, 2017 8:36 am
by TheHogNL
Also, using my solution, it is important that the collected Watts from the different installations is almost realtime (30s at most?).

As the Toon receives the P1 realtime (I think it is each 10 seconds or so) the solar power generated Watts should be in that order of precision also. Or else the Toon would make garbage of the 'power usage' statistics, especially on a cloudy day. The Toon calculates the power usage in a formule like (SolarWatts - P1meterReturnWatts = Power usage)

Re: Toon app: Zon op Toon using PVoutput

Posted: Tue Aug 22, 2017 12:01 pm
by Ierlandfan
I do not have the P1 meter and I do not have the entry in the projects.xml for the solar. If I remember correctly there was a different version (SW) for Solar. Can someone confirm that?

Re: Toon app: Zon op Toon using PVoutput

Posted: Tue Aug 22, 2017 6:09 pm
by marcelr
Not really. All firmwares, starting from 3.2.18, should have it.
The entry is in config_happ_scsync.xml, not qmf_project.xml.

Re: Toon app: Zon op Toon using PVoutput

Posted: Tue Aug 22, 2017 6:59 pm
by Ierlandfan
Can you share the entry? I do not have an entry for Solar in config_happ_scsync.xml but I also don't have a digital energymeter. Maybe that's the reason.

Re: Toon app: Zon op Toon using PVoutput

Posted: Tue Aug 22, 2017 7:14 pm
by marcelr
This is it:

Code: Select all

<SolarDisplay>1</SolarDisplay><SolarActivated>1</SolarActivated>

Re: Toon app: Zon op Toon using PVoutput

Posted: Wed Aug 23, 2017 7:20 am
by TheHogNL
If you are not connected to a P1 meter, activating the solar (if even possible) would break stuff. Because it uses the same analog port of the meter-adapter which in your situation is (i think) used for your analog meter (led).

Re: Toon app: Zon op Toon using PVoutput

Posted: Wed Aug 23, 2017 5:14 pm
by TheHogNL
marcelr wrote:Interesting solution. You might pass the digital signal from your raspi straight into the meter adapter, without the leds and the phototransistor (which together form an optocoupler, basically).
Just tried to figure out the wiring of the sensors. There are 3 wires. On seems to be 3v, one seems to be a ground and one again with 3v. When I connect the first 3v to the ground the toon module records that as a pulse. So probably the ground is the pull-down input of the toon module, counting a pulse when provided with the 3v. That is great News! I am not sure what the other 3v does yet, it can not be used as a source to get the pulse to be counted.

However, the toon modules does some kind of booting for the first seconds connected to the powerline. The sensors will then flash blue, stay blue etc and the toon module leds blink a few times. When the boot is over, the sensor blue led will turn of when a red flashing led is detected or will stay on if not (probably if a reflector is used on old meters).

I can not simulate this bootstart yet. So when just connecting the Rasperry Pi directy (electrically) to the Toon module, I can not give the pulses anymore. So I need to boot with the original sensor connected, let the Toon module detect that it is using a red pulsing led and then disconnect the led and connect the Toon module to the Rasp. This makes this solution not boot-proof. I still need more time to figure out how to simulate the sensor behaviour more.

Re: Toon app: Zon op Toon using PVoutput

Posted: Mon Jul 30, 2018 5:03 pm
by timkoers
bwbboot wrote:This is one of the last tests that i did. A strace on for example HCBv2 happ_pwrusage reveils the following messages being sent:

Code: Select all

read(3, "<action class=\"response\" uuid=\"eneco-002-XXXXXX:hcb_config_61127789807\" destuuid=\"eneco-002-XXXXXX:happ_pwrusage\" serviceid=\"urn:hcb-hae-com:serviceId:specific1\" requestid=\"1295-1266\">\n    <u:GetRraDataResponse xmlns:u=\"urn:hcb-hae-com:service:specific1:1\"><requestId>1295-1266</requestId>\n   <rraData>{ \"1502218800\": NaN}</rraData>\n   <firstSample>1344430800</firstSample>\n   <lastSample>1502218800</lastSample>\n   <tzOffset>2</tzOffset>\n    </u:GetRraDataResponse>\n</action>\0", 16384) = 477
gettimeofday({1502218412, 425384}, NULL) = 0
read(3, "<notify uuid=\"5f195db2-8ae7-4e75-a7ba-d227f556c166\" serviceid=\"urn:hcb-hae-com:serviceId:ElectricityQuantityMeter\">\n    <CurrentElectricityQuantity>10798938</CurrentElectricityQuantity>\n</notify>\0", 16384) = 196
read(3, "<notify uuid=\"713aa639-1f74-42fd-a978-4558f50d1159\" serviceid=\"urn:hcb-hae-com:serviceId:ElectricityQuantityMeter\">\n    <CurrentElectricityQuantity>10857074</CurrentElectricityQuantity>\n</notify>\0", 16384) = 196
read(3, "<notify uuid=\"5f195db2-8ae7-4e75-a7ba-d227f556c166\" serviceid=\"urn:hcb-hae-com:serviceId:ElectricityFlowMeter\">\n    <CurrentElectricityFlow>890</CurrentElectricityFlow>\n</notify>\0", 16384) = 179
write(2, "\33[01;34m[\33[01;36mhdrv\33[0m\33[01;34m]\33[0m\33[01;35mDS: \33[0mdatasetUpdate powerUsage\n", 79) = 79
write(2, "\33[01;34m[\33[01;36mhdrv\33[0m\33[01;34m]\33[0m\33[01;35mDS: \33[0mUpdate for dataSet \33[01;35mpowerUsage\33[0m\n", 96) = 96
write(2, "\33[01;34m[\33[01;36mhdrv\33[0m\33[01;34m]\33[0m\33[01;35mDS: \33[0mSend full \33[01;35mpowerUsage\33[0m update to \33[01;35meneco-002-XXXXXX:qt-gui\33[0m\n", 133) = 133
write(3, "<action class=\"invoke\" uuid=\"eneco-002-XXXXXX:happ_pwrusage\" destuuid=\"eneco-002-XXXXXX:qt-gui\" serviceid=\"urn:hcb-hae-com:serviceId:specific1\">\n    <u:UpdateDataSet xmlns:u=\"urn:hcb-hae-com:service:specific1:1\"><powerUsage><value>890</value>\n    <dayCost>4.70</dayCost>\n    <valueProduced>0</valueProduced>\n    <dayCostProduced>0.00</dayCostProduced>\n    <valueSolar>NaN</valueSolar>\n    <maxSolar>NaN</maxSolar>\n    <dayCostSolar>NaN</dayCostSolar>\n    <avgSolarValue>NaN</avgSolarValue>\n    <avgValue>34.61</avgValue>\n    <avgDayValue>830.57</avgDayValue>\n    <avgProduValue>296.56</avgProduValue>\n    <avgDayProduValue>7117.43</avgDayProduValue>\n    <dayUsage>5605</dayUsage>\n    <dayLowUsage>3391</dayLowUsage>\n    <meterReading>10857074</meterReading>\n    <meterReadingLow>10960915</meterReadingLow>\n    <meterReadingProdu>6669844</meterReadingProdu>\n    <meterReadingLowProdu>2570472</meterReadingLowProdu>\n    <isSmart>1</isSmart>\n    <lowestDayValue>0</lowestDayValue>\n    <solarProducedToday>NaN</solarProducedToda"..., 1073) = 1073
write(2, "\33[01;34m[\33[01;36mhdrv\33[0m\33[01;34m]\33[0m\33[01;35mDS: \33[0mSend full \33[01;35mpowerUsage\33[0m update to \33[01;35ma0b6a2690-f343-11e1-a21f-0800200c9a66\33[0m\n", 147) = 147
write(3, "<action class=\"invoke\" uuid=\"eneco-002-XXXXXX:happ_pwrusage\" destuuid=\"a0b6a2690-f343-11e1-a21f-0800200c9a66\" serviceid=\"urn:hcb-hae-com:serviceId:specific1\">\n    <u:UpdateDataSet xmlns:u=\"urn:hcb-hae-com:service:specific1:1\"><powerUsage><value>890</value>\n    <dayCost>4.70</dayCost>\n    <valueProduced>0</valueProduced>\n    <dayCostProduced>0.00</dayCostProduced>\n    <valueSolar></valueSolar>\n    <maxSolar></maxSolar>\n    <dayCostSolar></dayCostSolar>\n    <avgSolarValue></avgSolarValue>\n    <avgValue>34.61</avgValue>\n    <avgDayValue>830.57</avgDayValue>\n    <avgProduValue>296.56</avgProduValue>\n    <avgDayProduValue>7117.43</avgDayProduValue>\n    <dayUsage>5605</dayUsage>\n    <dayLowUsage>3391</dayLowUsage>\n    <meterReading>10857074</meterReading>\n    <meterReadingLow>10960915</meterReadingLow>\n    <meterReadingProdu>6669844</meterReadingProdu>\n    <meterReadingLowProdu>2570472</meterReadingLowProdu>\n    <isSmart>1</isSmart>\n    <lowestDayValue>0</lowestDayValue>\n    <solarProducedToday></solarProducedToday"..., 1072) = 1072
write(3, "<action class=\"invoke\" uuid=\"eneco-002-XXXXXX:happ_pwrusage\" destuuid=\"a0b6a2690-f343-11e1-a21f-0800200c9a66\" serviceid=\"urn:hcb-hae-com:serviceId:specific1\">\n <u:UpdateDataSet xmlns:u=\"urn:hcb-hae-com:service:specific1:1\"><powerUsage><value>890</value>\n

Based on that last write line, i constructed a XML that would update a "known" dataset and destination uuid. Something in the lines of:

Code: Select all

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<action class="invoke" uuid="eneco-002-XXXXXX:happ_pwrusage" destuuid="a0b6a2690-f343-11e1-a21f-0800200c9a66" serviceid="urn:hcb-hae-com:serviceId:specific1" commonname="eneco-002-XXXXXX" xmlns:u="urn:hcb-hae-com:service:specific1:1" 
    <u:UpdateDataSet>
    	<powerUsage>
        <Value>8000</Value>
        </powerUsage>
    </u:UpdateDataSet>

Have you got any idea on how to use bxt to update the datasets?

Re: Toon app: Zon op Toon using PVoutput

Posted: Tue Feb 26, 2019 7:48 pm
by jerver
Hi all,
I am very interested in having my PV data visible in Toon. I wondered if some progress is made or that someone can help me figuring things out.
I understand that injecting the Toon database with solar data is a kind of no go area as it is too complex.
An other solution is the standard Toon op zon measuring of pulses. To achieve this a pulse based on the measured kwhs has to be created. The challenge here is that the interval on which the pulses have to be created cannot be larger then eg 10/15 secs, which is way less then the 5 minute interval in which I get the Solar data.
Is the following approach feasible?
Each 5 minutes I get new solar data. The difference in kwh between two measurments is the amount of kwhs in the last five minutes. Based on this delta kwhs and a constant pulses per kwh the frequency of pulses can be calculated and be fed to Toon in the next 5 minutes. So Toon gets the solar data semi real time with a delay of 5 minutes. Will this delay have any impact?

Re: Toon app: Zon op Toon using PVoutput

Posted: Tue Mar 10, 2020 6:19 pm
by PurpleBlue
Hi,

I am using Toon for reading P1 and "Zon op Toon" for our Solarpanels.
On PVoutput I have an account from the past, and i was wondering if it also been posible to upload data to PVoutput, instead of reading it.

So Toon "upload" the data to PVoutput, So that I can compare my graphs.

Re: Toon app: Zon op Toon using PVoutput

Posted: Sat Apr 10, 2021 3:15 pm
by memo1996
Zon op Toon werkt ook zo prima!!!!
Zojuist geinstalleerd

- Meteradapter met 2 vlammen
- Analoge sensor
- KWH meter

Zie foto's!