-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature: Added "Tibber" Power Meter to support Tibber Pulse (via Tibber Bridge) #915
Feature: Added "Tibber" Power Meter to support Tibber Pulse (via Tibber Bridge) #915
Conversation
So, the Tibber Pulse is a fancy Hichi? Thanks for this pull-request! The part which reads the Tibber data stream and pushes it through the SML handler is very valuable. However, I do not approve the current implementation.
ToDo:
In my opinion, 3. is absolutely mandatory. If you manage to implement 3., I will merge this despite my strong objections. I can address those when I tackle the PowerMeter refactoring. Add a new Edit: Remove all files in |
@marvincarstensen Share your struggle with compiling, maybe I can help you easily. Are you compiling for the |
@schlimmchen I'm actually able to compile the firmware. It looks like a boot-loop with the following log:
I stripped down my code back to the development branch, but I'm still getting the boot-loop. As soon as I switch back to the "development"-branch on the same workspace and recompile, it works fine again. |
Yes, that's #950. Please work on an earlier version of the development branch, or wait a couple of hours when I hopefully have freed some flash such that non-S3 builds work again (building and booting). |
5daf239
to
93dd201
Compare
Thank you for your feedback and hint while debugging @schlimmchen!
Yes, but "Tibber" is actually a power company which fetches the power consumption in realtime from the power meter and charges only the current market prices. I just tried to "repurpose" the Tibber pulse because it already blocks the power meter.
The info text got moved to the wiki: https://github.com/helgeerbe/OpenDTU-OnBattery/wiki/Power-Meter
I'm totally fine with separating the Tibber into another PowerMeter type. I just didn't want to create redundant code, as the Tibber technically also is an "HTTP" Power Meter.
Done.
I duplicated the HttpPowerMeterClass and removed all unnecessary function, constants, etc. and added the modifications for Tibber. But I did not create a base class, but feel free to do that while refactoring the PowerMeter.
Done.
Also done.
I removed the files in webapp_dist from the changeset. |
Alright, this looks much better! Thanks for your efforts. I will rebase this onto the current development branch, solve the conflicts and update parts of your code for compatibility with ArduinoJson7. I then need you to test the feature once more on short notice, so we can merge this. Merging this is important to me, because as of today, I started the power meter refactoring, and it's best if my work is based on yours. However, I want to be sure that the feature is working okay before it is merged. If we need to do a maintenance release for some reasons, the feature will be included and published, and it shall be working then. Are you available to re-test on short notice? |
Nevermind. I think we should keep it generic, as there are possibly other devices out there which work the same way (HTTP server handing out SML data). |
6f25097
to
25dc707
Compare
@marvincarstensen Can you please test the firmware available in the PR build run? Could you also be so kind and download a copy of the binary obtained from your Tibber bridge at |
did check it ... and it works as expected. would reduce the need of another esp(32) for only "pulse" reading ... attaching a dump from my bridge ( serial cleared ... hopefully none crc-checks chime in :) ) btw., the pulse only sends the raw sml to the bridge over 433mhz ( longer range then most other non-wifi version, except lora, if any exists ) |
Sure! No problem.
I've tested that build too and it works as excepted.
I hope the dump of @noone2k works for you (thanks @noone2k !). |
Thanks for your feedback, @marvincarstensen @noone2k. The binary you provided works: I can have it served by a webserver and the power meter implementation will spit out 21W as result. I guess that's reasonable.
Does that mean that the actual power meter, to which the pulse is attached, will determine what data is received? Our goal should be to define SML handlers for the most common data? Something like this? (from https://tasmota-sml-parser.dicp.net/decode) I realized, while continuing the power meter refactoring, that this feature is actually very generic: HTTP/GET a binary from a webserver and interpret it as SML. I can see how other devices might do the same. That's why I am going to rename the class and settings to represent "SML over HTTP(S)" functionality. The GUI will mention "Tibber Pulse" explicitly as an example. The Wiki/docs are ready to help users setup this power meter interface to communicate with the Tibber bridge. As this will break the existing config you guys have, I will postpone including this feature in a public release. Please use the firmware from the PR build run you already tested to have support for this power meter. Let me know if this works for you. I will make sure that you, @marvincarstensen, remain author of the commit that introduces this feature. |
should be right ... ( have to lookup, to be 100% certain ) ...
yes ... the pulse send the raw data 1:1 and doesnt alter anything. this way: the same rules for hichi and co applies to this device. so, the data received depends on the meter(-settings) ( short, long, advanced dataset ) ^^should cover the next part ...
i'm fine with it ... but this question is more for @marvincarstensen :)
|
Sounds good to me! Update us as soon as you have refactored the power meters and implemented the "SML over HTTP(S)". I will here to test the implementation. |
Hello, I am also interested in that topic. I currently use a script in iobroker to get the power from the bridge and provide the value with mqtt. Your solution would be much better (no iobroker necessary). |
@arnhei Did you install one of these: https://github.com/helgeerbe/OpenDTU-OnBattery/actions/runs/8974757062?pr=915 ? Did you install the correct flavor? Maybe you installed "generic_esp32" but need "generic", as the latter has some default pins defined for the NRF24 module, but the former does not. If you are interested in cleaning that up, install an appropriate Device Profile. |
Hello, (I used Google Translate in case some things sound strange) Best regards |
25dc707
to
a28a57d
Compare
This feature will certainly be merged, however, not via this pull request. I will let you know (add a comment here) when the feature is merged into the development branch. You will have to observe when the first release is made which includes the feature (see changelogs). I highly anticipate that there will be another release which includes this feature, which will also run on ESP32 with 4MB of flash.
This sentence got garbled up... At least I don't understand what you are asking. German: Du möchtest wissen, ob du die oben verlinkte und im Kontext dieses pull request gebaute Firmware einfach weiterverwenden kannst? Klar. Zum einen basiert diese aber auf einem etwas älteren Stand des Projektes, und zum anderen wird dieser pull request wird nicht gepflegt, d.h. du wirst irgendwann abgehängt sein, wenn du neue Features nutzen möchtest, die Teil von Releases werden. Beantwortet das deine Fragen? Ich habe dieses Feature noch einmal auf den aktuellen development Branch aufgesetzt. Die daraus resultierende neue Firmware findest du im neuen Build Run. Die ist dann wie 2024.06.03 mit Tibber. |
Hallo Schlimmchen, Ich wollte nicht unhöflich sein und einfach auf Deutsch schreiben, vielen Dank für den Klartext! LG Thomas |
Hallo zusammen, ich verstehe es mal wieder nicht. Wo finde ich denn das aktuelle Release für den Tibber. Mit der offiziellen von Helge läuft es ja nicht oder? Zumindest bei mir nicht. Grüße Marco Update: man sollte sich einloggen und schon klappt der download. Allerdings komme ich trotzdem nicht an die Daten des Tibber. Die aktivierung des Webservers war erfolgreich. Die IP-Adresse stimmt auch, sowie auch die Zugangsdaten zum Tibber. Was kann man tun? |
Hallo Marco, Zum Update: Ich habe da auch so meine Probleme, weiß aber nicht genau was schief läuft. Zuerst hatte ich eine tibber-host.fritz.box Adresse die hinter aber nicht mehr wollte. Also nun direkt eingetragen. Und das Passwort will openDTU onBattery als echte Eingabe nicht als Copy and Paste. Musste ich mehrfach ausprobieren bis ich es geschafft habe. |
Hi,
habe ich gemacht. War nicht eingeloggt, daher kein Download.
Allerdings klappt es trotzdem nicht…
Hab mal ne Screenshot angehängt
Gruß marco
Von: Megathomas-de ***@***.***>
Gesendet: Freitag, 14. Juni 2024 14:37
An: helgeerbe/OpenDTU-OnBattery ***@***.***>
Cc: Marco Matterne ***@***.***>; Comment ***@***.***>
Betreff: Re: [helgeerbe/OpenDTU-OnBattery] Feature: Added "Tibber" Power Meter to support Tibber Pulse (via Tibber Bridge) (PR #915)
Hallo Marco,
nehme die Version aus dem letzten Beitrag von Schlimmchen "im neuen Build Run", das funktioniert genauso wie Ursprüngliche hier aus dem Tread. Das Offizielle von Helge unterstützt das noch nicht.
—
Reply to this email directly, view it on GitHub<#915 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/A6GKDTH4XSL3TPQUC77EBCLZHLPYDAVCNFSM6AAAAABGVMZZQ6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNRXHE2DCOBWGY>.
You are receiving this because you commented.Message ID: ***@***.***>
|
Leider sehe ich kein Bild |
Der Webserver hatte das "true" nicht übernommen. Allerdings bekomme ich jetzt bei Test folgende Meldung: [HttpPowerMeter] Unable to parse server response as JSON Muss den beim "JSON Pfad" noch etwas eingetragen werden? |
Wenn du das Feld JSON-Pfad sehen kannst, hast du etwas falsch eingestellt. Bei Stromzählertyp muss "Tibber Pulse (via Tibber Bridge" ausgewählt sein. |
Hmm, das kann ich nicht auswählen da nicht vorhanden. SDK-Version | v4.4.6-dirty -- | -- 0.1.28 2024.06.03 SDK-Version v4.4.6-dirty Konfigurationsversion 0.1.28 Firmwareversion / git Hash [2024.06.03](https://github.com/helgeerbe/OpenDTU-OnBattery/releases/tag/2024.06.03) |
Dann ist das nicht die Firmware hier aus dem Thread, nehme ich mal stark an. Meine heißt helgeerbe/OpenDTU-OnBattery/pr915-202406061134. |
Asche über mein Haupt. Manchmal sollte man solche Sachen nicht zwischen Tür und Angel machen. Ich hatte tatsächlich die falsche Firmware erwischt. LG Marco |
Superseded by #1077. |
Ich bekomme die Firmware nicht installiert. Bekomme immer einen invalid header nach der Installation. invalid header: 0xffffffff rst:0x10 (RTCWDT_RTC_RESET),boot:0x13 (SPI Habt ihr eine Idee? |
Nimm bitte Firmware aus #1077 oder aus dem letzten Build Run des development Branches. Du hast vermutlich die factory.bin über OTA ge-flash't, oder die non-factory.bin über esptool mit dem falschen Offset, oder du hast eine zu große Firmware in eine zu kleine Partition installiert, oder oder oder 😉 Lösche den Flash deines ESP32 und fang von Vorn an. |
Hab ich alles durchprobiert, denke ich. Die normale Webinstallation läuft ja. |
Dann hast du ja eine funktionierende OpenDTU-OnBattery, mit der du lediglich noch ein OTA Update machen musst. Beschreib bitte mal exact, was du tust. Welchen ESP hast du? Welche Datei verwendest du? |
Nach langem hin und her hat endlich alles geklappt. Vielen Dank für die Hilfe. |
okay warum auch immer. Es war das Netzteil. Sieht so aus als ob das Dev Board Probleme mit der Stromversorgung hat bei stärkeren Netzteilen oder das Netzteils Mist ist. Danke an alle. |
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new discussion or issue for related concerns. |
I've extended the "HTTP(S) + JSON" Power Meter (#153) to support the Tibber Pulse. The current power drawn from the grid is fetched using the local web server from the Tibber Bridge. No external requests through the internet (Tibber API).
Instructions on how to enable the web server permanently are also included in German and English:
Thank you to gvzdus and the discussion #123!
Pre-compiled binaries to directly test the feature:
opendtu-onbattery-generic_esp32.bin.zip
opendtu-onbattery-generic_esp32.factory.bin.zip