Open luq-sparrow opened 4 years ago
hi there , for the R3 i have not used a modem ( as I do not have one of those) only a HC-12 connected to a usb serial device. I used the modem for the R2 for the R3 you would use this one https://github.com/krywenko/WVC-Inverter-R2-R3-HC-12--and--Modem
well i guess you wish to push to a database ? if so influxdb would be my choice couple ways to do that.. you can use my default program, setup collecd ( with mqtt installed and then setup collectd to send data to influxdb or other databases) and then rendered that how ever you want. or where you see mqtt publish in my script change it to a influxdb curl send directly mosquitto_pub -h $host -t "incoming/$3/DC-Energy/power-$D_id" -m "N:$DC"
if you want other option others have posed cc+, python and nodered verison here,, https://community.openenergymonitor.org/t/wvc-inverter-mqtt-data-logging-for-all-versions-of-inverters/12352
I've done a test today. The modem sends some hex data to server via TCP protocol. All connection parameters are available in modem settings. It looks like having one of those I'll be able to recive complete data package wherever on local network or internet. The only thing that bothers me is the data format. It will be great if we can have a call or sth.
I have no inverters connected, The data I got form the modem: e6XXXXXXXXffff0000ffffffff26 I figured out that e6 is some question or sth. then is the modem id as the Xs
Any ideas?
need to have at least one inverter connected as no data is collected or sent e6XXXXXXXXffff0000ffffffff26 is a network heart beat
WIFI Modem Heartbeat Package: E6 FF FF FF FF FF FF FF FF FF FF FF FF 26 (service number) (collector ID) (placeholder) (operation word) Description: The heartbeat packet is a packet that the WIFI Modem automatically sends to the server every 40s when it is idle.
what you are looking for are: E0 63 03 02 5D C4 78 8F 60---A Phase voltage E1 63 03 02 5D C4 78 8F 61---B Phase voltage E2 63 03 02 5D C4 78 8F 62---C Phase voltage E3 63 03 02 5D C4 78 8F 63---A Phase current E4 63 03 02 5D C4 78 8F 64---B Phase current E5 63 03 02 5D C4 78 8F 65---C Phase current E6 63 03 02 5D C4 78 8F 66---Frequency wirelessly sent to the WIFI collector E7 63 03 02 5D C4 78 8F 67---Total power factor E8 63 03 02 5D C4 78 8F 68---Total active KWh E9 63 03 02 5D C4 78 8F 69---Total reactive power KWh EA 63 03 02 5D C4 78 8F 6A---Total active power EB 63 03 02 5D C4 78 8F 6B---Total reactive power
Examples of calculation methods for data: A,B,C,Phase voltage:5E 87 Convert to decimal number as:24199 /100=241.99V (Unsigned) A,B,C,Phase current:00 F2 Convert to decimal number as:242 /1000*10=2.42A(Unsigned) Frequency:13 85 Convert to decimal number as:4997 /100=49.97Hz (Unsigned) Total power factor:FC 53 The inverse of the conversion to a binary number is:0000001110101100 Then convert to decimal minus 1:939 / 1000 = -0.939(Signed) Total active KWh:01 57 Convert to decimal number as:343 /10=34.3KWh (Unsigned) Total reactive KWh:00 30 Convert to decimal number as:48 /10= 4.8KWh (Unsigned) Total active power:E0 F0 The inverse of the conversion to a binary number is:0001111100001111 Then convert to decimal minus 1 to:7950 / 100 = -79.50W(Signed) Total reactive power:F9 4E The inverse of the conversion to a binary number is:0000011010110001 Then convert to decimal minus 1 to:1712 / 100 = -17.12W(Signed) Wireless transmission format:
NICE WORK... Wow .. Im impressed. So basically for total reactive power it will be EB 63 03 02 5D C4 78 8F 6B XX XX ? Where XX XX is the value, right?
Do you know anything about commands that can be send to inverters or modem (boot, startup, shutdown, register inverter, etc)? I see a lot of about them on the board (openenergymonitor) but mostly for R2.
Btw Isn't your comment cut? It ends weirdly with "Wireless transmission format:"?
usually it ends at the control word but I do not have a modem for ,r3 to verify eb XX XX XX XX XX FF FF 6b I would suspect the xx is the inverter id and the ff is the data packet. but it also might be the way you say you have to sniff a packets sent from the modem to see what the end format actually is ..
yes but only sent through hc-12 to the r3 inverter if you have com port on the modem you can probably send it to it that way but I never worked with them. but you would have to adapt my above R2 modem send format to that of a R3 modem format
the controls are posted on OEM Inverter command summary: Inverter power is cleared--F0 FF FF FF FF FF FF 00 00 80 01 FF FF 00 The same return value Power adjustment-----F1 FF FF FF FF FF FF 00 00 03 00 FF FF 01---64The same return value Data collection------F2 FF FF FF FF FF FF 00 00 03 00 FF FF 65 According to the above example Boot control-----------F3 FF FF FF FF FF FF 00 00 03 00 FF FF 66 The same return value Shutdown control-------F4 FF FF FF FF FF FF 00 00 03 00 FF FF 67 The same return value Chart data-----------F5 FF FF FF FF FF FF 00 00 03 00 FF FF 68 Same as F2 Inverter code writing-----F6 FF FF FF FF FF FF 00 00 03 00 FF FF 69 The same return value Inverter code reading-----F7 FF FF FF FF FF FF 00 00 03 00 FF FF 6A The same return value Inverter value adjustment-----F8 FF FF FF FF FF FF 00 00 03 00 FF FF 01---255The same return value
you might be able to send it by wifi but I have no info on that
Good news I got a data sheet form the manufacturer to clarify that. Will share some details as soon as I translate that. Hope they will tell me how to operate with the modem. Its pure TCP client server communication form the modem to kdm page so probably hex commands are ok. Inside of the modem there is just a wifi adapter instead of a com port. so basically all the other things should stay the same.
So form what you said the data does not come in a single line like on the image here (from the forum)?
It's now separated in single messages starting form E0, E1, E2 hex code according to your first comment?
Anyhow I'll keep you updated with any news that I got.
usually data to cloud are push.. I would just use wireshark and connect your modem and inverter to cloud base and see what it pushes. and what format is sends .. as the information I posted was provided to me by the company so it should be actuate
Ok, I recived a document form them also. As soon as I manage to translate that to english I can share the data with you
@luq-sparrow any update on your attempts to build a fully local system using WVC R3 inverters and WVC-Modem(R3)?
I bought a big batch of WVC's R3 with new modems (433 to wifi) that sends data to remote manufacturer server. Anyhow their app doesn't work as desired so I tought of coding my own server. Fronted is pretty much done in Angular, backend will be probably in Java with Spring. The modem allows me to specify the ip (or domain) address to send the data.
The question is if you can provide any ideas how to use the data? I see that you pretty much figured out what data the modem is sending trough rs232, am I right? Could you provide me some tips on doing this? Speaking with manufacturers is a nightmare so you are my last resort.
Thanks in advance.. Would be nice if you can help.
I will also provide a version of the system to public repo.