jantenhove / P1-Meter-ESP8266

Software for the ESP8266 that sends P1 smart meter data to Domoticz (with CRC checking)
GNU General Public License v3.0
79 stars 38 forks source link

No data from Iskra SMR 5.0 AM550-ED1 with Wemos D1 #6

Closed jildertviet closed 6 years ago

jildertviet commented 6 years ago

At first: thanks for the clear instructions and sketch! I didn't get output from my meter at first, but read something about adding resistors here (Dutch). image Since SoftwareSerial takes care of the inverted signal I just placed a 10k resistor between 5V+ and the data-line, which made it work! So not really an issue anymore, but maybe someone has the same problem :) I'll close it right away.

nescafe2002 commented 5 years ago

Thanks! I've been able to read a Sagemcom T210-D using this fix.

jildertviet commented 4 years ago

Back at it, exactly two years later ;) I'm now using the same code for an ESP32 (With Serial1 instead of SoftwareSerial). Anyway, placing the pull-up resistor on 3.3V+ is a better idea then 5V+ :)

ferdyh commented 4 years ago

I have a Sagemcom T210-D meter and tried using this code too. First I didn't have the 10k resistor and everything was nonsense. Now however it makes more sense, but I don't get full messages, it keeps reading partial messages. Any idea on how to fix that?

jildertviet commented 4 years ago

Hi, I think I had that same problem. Therefore I tried an ESP32 which works fine. Are you using an ESP8266 or ESP32?

ferdyh commented 4 years ago

ESP8266

jildertviet commented 3 years ago

Since I had the same problem (I think) and hadn't changed anything in my setup, except re-uploading the code, you can try to use an older ESP8266-Arduino release from 2018, like 2.4.0 via the Arduino IDE Boards manager. https://github.com/esp8266/Arduino/releases/tag/2.4.0 Or maybe something has changed here, so you can try a version from jan-2018 as well: https://github.com/jantenhove/P1-Meter-ESP8266/tree/452a57fa77d72d241914cae8ebd23b9112edf43e Just a guess, maybe it works. Good luck!

ferdyh commented 3 years ago

How did you connect the ESP32 and what changes have you made to the code? (I got an ESP-WROOM_32 aswell now to try...)

jildertviet commented 3 years ago

Hi, I've connected the TX of the meter to the RX of my choice (GPIO33) of Serial1 with: Serial1.begin(115200, SERIAL_8N1, 33, -1, true); I also connected a 10k resistor between GPIO33 and 3V. For the code to be compatible with ESP32 I changed all the WiFi stuff to the correct (ESP32)-libraries, but the reading and parsing of the Serial input will be the same, although you're not reading from 'mySerial' but from Serial1.

Here's my (quick and dirty) code, https://github.com/jivido/Arduino/tree/master/readerTCPServerESP32 Also uses EEPROM for daily comparisons.