PZEM004 jednofazowy Licznik Energii Elektrycznej
-
Vilpro
- Posts: 1
- Joined: Tue Jun 23, 2020 11:46 am
Witam wszystkich.
istnieje 3 pzem-004t + Wemos D1 mini z oprogramowaniem ESP-Easy.
Wszystkie dane są przesyłane do Domoticz.
Jak mogę rejestrować energię elektryczną na podstawie dwóch taryf (dzień, noc)?
Czy możesz udostępnić skrypt, aby uwzględnić zużycie energii elektrycznej dla jednej lub 3 faz?
istnieje 3 pzem-004t + Wemos D1 mini z oprogramowaniem ESP-Easy.
Wszystkie dane są przesyłane do Domoticz.
Jak mogę rejestrować energię elektryczną na podstawie dwóch taryf (dzień, noc)?
Czy możesz udostępnić skrypt, aby uwzględnić zużycie energii elektrycznej dla jednej lub 3 faz?
You do not have the required permissions to view the files attached to this post.
Last edited by Vilpro on Thu Jun 25, 2020 6:06 am, edited 2 times in total.
-
Rafaello
- Posts: 108
- Joined: Sun May 29, 2016 1:34 pm
Dwa licznik z trzech zresetowały mi się samoczynnie podczas braku zasilania na dwóch fazach, czy w cloud da radę ustawić dla PZEM004 danej fazy stan początkowy, tak jak to jest chyba przy liczniku impulsów.
-
adamkody
- Posts: 33
- Joined: Tue Nov 14, 2017 10:33 am
Witam proszę o małą pomoc a w zasadzie gdzie popełniłem błąd ? esp zaprogramowałem z pierwszego link-a w aplikacji bez czy też z modułami pzem nie widzę żadnych danych . Z góry dziękuję za porady pozdrawiam
You do not have the required permissions to view the files attached to this post.
-
adamkody
- Posts: 33
- Joined: Tue Nov 14, 2017 10:33 am
witam, po części udało się rozwiązać problem soft z pierwszej strony obsluguje tylko jeden kanal (licznik) a tx i rx w wemocie to d3 i d4 .Jest na stronie 15 sposób polegający na wklejeniu kodu i podmianie bibliotek ja niestety nie umiem tego zrobic moja wiedza na temat arduino konczy sie na wgrywaniu badz podgladaniu plikow . No chyba ze znajdzie sie ktos chetny na jakis lopatologiczny opis jak to sie robi.
1. Usuń zainstalowaną bibliotekę SuplaDevice
2. Pobierz https://github.com/klew/arduino/archive/master.zip
3. Rozpakuj
4. Skopiuj to SuplaDevice z rozpakowanej ścieżki Pobrane/arduino-master/libraries/
5. Wklej do katalogu z bibliotekami Katalog domowy/Arduino/libraries/
6. Otwórz Arduino IDE
7. Utwórz nowy szkic
8. Wklej poniższy kod, wypełnij swoimi danymi
9. Wgraj na wemosa
2. Pobierz https://github.com/klew/arduino/archive/master.zip
3. Rozpakuj
4. Skopiuj to SuplaDevice z rozpakowanej ścieżki Pobrane/arduino-master/libraries/
5. Wklej do katalogu z bibliotekami Katalog domowy/Arduino/libraries/
6. Otwórz Arduino IDE
7. Utwórz nowy szkic
8. Wklej poniższy kod, wypełnij swoimi danymi
9. Wgraj na wemosa
Code: Select all
/*
Copyright (C) AC SOFTWARE SP. Z O.O.
This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
// this example will work only on esp8266 and esp32 boards. On Arduino mega it will not fly.
//dependence: Arduino library for the Updated PZEM-004T v3.0 Power and Energy meter https://github.com/mandulaj/PZEM-004T-v30
#include <SPI.h>
#include <SuplaDevice.h>
#include <supla/io.h>
#include <supla/sensor/three_phase_PzemV3.h>
// ESP8266 based board:
#include <supla/network/esp_wifi.h>
Supla::ESPWifi wifi("twoja_nazwa_sieci", "twoje_haslo_do_sieci");
void setup() {
Serial.begin(9600);
// Replace the falowing GUID with value that you can retrieve from https://www.supla.org/arduino/get-guid
char GUID[SUPLA_GUID_SIZE] = {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}; //wygeneruj z linku powyżej i podmień
// Replace the following AUTHKEY with value that you can retrieve from: https://www.supla.org/arduino/get-authkey zrobiłem
char AUTHKEY[SUPLA_AUTHKEY_SIZE] = {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00}; //wygeneruj z linku powyżej i podmień
//Ustaw GPIO jakie chcesz, RX jest wspólny
int rx=3;
int tx1=1;
int tx2=5;
int tx3=4;
new Supla::Sensor::ThreePhasePZEMv3(rx, tx1, rx, tx2, rx, tx3);
/*
* SuplaDevice Initialization.
* Server address, is available at https://cloud.supla.org
* If you do not have an account, you can create it at https://cloud.supla.org/account/create
* SUPLA and SUPLA CLOUD are free of charge
*
*/
//wifi.enableSSL(false); //jeśli nie będzie chciał się zarejestrować to wyłącz SSL
//podaj nr serwera i adres email
SuplaDevice.begin(GUID, // Global Unique Identifier
"svr1.supla.org", // SUPLA server address
"email@address", // Email address used to login to Supla Cloud
AUTHKEY); // Authorization key
}
void loop() {
SuplaDevice.iterate();
}
SOP 2023 
SOP 2024
Czekam na kolejne Supla Offline Party
:
cz->b
+ila
SOP 2024
Czekam na kolejne Supla Offline Party
