Skip to content

Code to read the VE.Direct-Protocol from serial into a value array. Uses a non-blocking read loop and does checksum verification before adding the data.

License

Notifications You must be signed in to change notification settings

physee/Victron.Arduino-ESP8266

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Victron.Arduino-ESP8266

Code to read the VE.Direct-Protocol from serial into a value array. Uses a non-blocking read loop and does checksum verification before adding the data. Extra care has been taken to not used readByteUntil() or any other blocking serial command that can mess with background services, especially on the ESP8266.

Extend this code with MQTT or any other protocol or service to send and/or extract the data.

Config

At the moment the MPPT 75/10 and the 100/20 are configured in the config.h.

Usage

Make sure the RX and TX of the VE.Direct-Protocol are connected to the corresponding pins in the setup, victronSerial. On the NodeMCU, pins D7/D8 are used.

Every second the MPPT sends out data, this is put into the value array. As per code the PrintValues() function loops of the array and prints the values and keys.

The values can also be used with the macros defined, eg. value[VPV] or value[ERR].

Note that the values are stored as chars, so convert to suitable types with functions like: atof() or atoi() etc.

About

Code to read the VE.Direct-Protocol from serial into a value array. Uses a non-blocking read loop and does checksum verification before adding the data.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published