maxzerker / pzem-017-v1 Goto Github PK
View Code? Open in Web Editor NEWArduino communication library for Peacefair PZEM-017 v1.0 Energy monitor
Arduino communication library for Peacefair PZEM-017 v1.0 Energy monitor
I am getting the following error when compiling for arduino nano:
....\Arduino\libraries\PZEM-017-v1-master\PZEM017v1.cpp: In constructor 'PZEM017v1::PZEM017v1(uint8_t, uint8_t, uint8_t)': ....\Arduino\libraries\PZEM-017-v1-master\PZEM017v1.cpp:90:32: error: 'SWSERIAL_8N2' was not declared in this scope port->begin(PZEM_BAUD_RATE,SWSERIAL_8N2); ^~~~~~~~~~~~ ....\Arduino\libraries\PZEM-017-v1-master\PZEM017v1.cpp:90:32: note: suggested alternative: 'SERIAL_8N2' port->begin(PZEM_BAUD_RATE,SWSERIAL_8N2); ^~~~~~~~~~~~ SERIAL_8N2 exit status 1
How can I make it compile?
Thanks
Thank you for the code, but it is not working for me. I have used pzem-004tv3 module and related code with arduino Uno and it works great.
I'm trying to talk to Arduino Uno, and need (I believe) TTL to rs485 translation. Would you describe how this code is intended to work with pzem-017 module (and arduino Uno)? For example, Modbus library is apparently not used; is the code performing some of those tasks? Also, is a TTL to rs485 module needed? If so, which type is presumed, 2-pin (A,B) or 4-pin (DI,DE,RE,RO)? Thanks.
Sorry for bad english... :-)
SoftwareSerial example not work , but if remove " SWSERIAL_8N2" in the line 90 it's ok!
Line 90 in a08063a
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.