stuartpittaway / diyBMSv4ESP32

diyBMS v4 code for the ESP32 and new controller hardware
Other
166 stars 78 forks source link

Does anyone know the CANBUS pin assignment of a Voltronic Axpert MAX or MPPSOLAR or identical/similar devices? #227

Open moscito1010 opened 11 months ago

moscito1010 commented 11 months ago

Does anyone know the CANBUS pin assignment of a Voltronic Axpert MAX or MPPSOLAR or identical/similar devices? I want to connect the DIY controller to the Axpert MAX and the information I can find is conflicting.

moscito1010 commented 11 months ago

I've been experimenting a bit because I'm building a new pack right now. I haven't finished building all the cell modules yet, but it should be enough for a test.

According to this source, 6 is CAN-H, 7 is CAN-L, 8 is GND LINK https://powerforum.co.za/uploads/monthly_2022_10/4191291F-06BF-467A-A918-7472B3E9C387.jpeg.17b6aeed1067303910e7f6ff46551fec.jpeg

On the DIY controller, J7 has 1 +5V, 2 GND, 3 CAN-H, 4 CAN-L +5v is not needed so would be RJ45 <-> DIYBMS 6<->3 7<->4 8<->3 If the source is correct, the cable should work. FYI this is a CAT5 network cable that I cut off at one end.

Here is a picture of my settings in the BMS. grafik

grafik

With the inverter, I switched on the support for PYL (Pylontech) in menu item 5 and checked it several times.

stuartpittaway commented 11 months ago

@moscito1010 did you get the inverter working over CANBUS ?

Jestergnet commented 11 months ago

I was also looking for information about working with CAN BUS, but everywhere I came across that Axpert Max and similar millets do not have support, only RS485.

I'm just saying what I found on the net, maybe someone has other information?

stuartpittaway commented 11 months ago

There is some experimental work on RS485 communication with inverters going on over here - https://github.com/stuartpittaway/diyBMSv4ESP32/pull/195 The development is by a another user of DIYBMS.

moscito1010 commented 11 months ago

I was also looking for information about working with CAN BUS, but everywhere I came across that Axpert Max and similar millets do not have support, only RS485.

I'm just saying what I found on the net, maybe someone has other information?

I have installed 3 units of the AXPERT MAX 7200W 48V 80A 2MPPT. here a pic from the control unit

grafik

sorry i found the discription in german. Anpassbare LED-Statusleiste mit RGB-Leuchten Eingebautes Wi-Fi für die mobile Überwachung (Android / iOS-Apps sind verfügbar) Unterstützt die USB On-the-Go-Funktion Kommunikationsanschluss für BMS reserviert (RS485, CAN-BUS oder RS232) Austauschbares Lüfterdesign für einfache Wartung Batterieunabhängiges Design Konfigurierbare Priorisierung und Timer der AC / PV-Ausgangsnutzung Wählbarer Hochleistungsladestrom Wählbarer Eingangsspannungsbereich für Haushaltsgeräte und PCs Kompatibel mit Netz- oder Generatoreingang Anti-Staub-Kit Optionaler Gleichstromausgang für Gleichstromlüfter, LED-Lampe, Router usw. Parallelbetrieb bis zu 6 Einheiten

moscito1010 commented 11 months ago

OK, I'm just testing the pylontech_rs485 branch.

chapulino commented 10 months ago

finally someone has been able to connect a voltronic type inverter by cambus to the DIYBMS with pylontech emulation? What were the communication pins between one and the other?

moscito1010 commented 10 months ago

No, not CAN but RS485 (Modbus). I have Axpert Max 7.2 inverter and had also tried it with CAN but actually the CANBUS does not seem to work with the inverter and it communicates with the Pylontech batteries via MODBUS. I know that the Voltronic devices are supposed to be able to use CANBUS, MODBUS and RS232, but in fact there is no communication with a pure CANBUS connection. I gave up trying to get support from Voltronic. They always answer the same mantra..."Please use the BMS cable from Pylontech" Unfortunately, I don't have a BMS cable from pylontech, but I'm almost certain that the MODBUS is also used in the cable.

However, with the RS485 branch it works fine.

Here is the pinout I used Inverter<->BMS (RS485) 5<->A 3<->B I installed this branch https://github.com/ruza87/diyBMSv4ESP32/tree/pylon_rs485

chapulino commented 10 months ago

Thanks, do you know if it will be compatible with the All in One? Could an update be made to work with Aspert but to collect the updates from the latest controller?

moscito1010 commented 10 months ago

You mean Stuart's all-in-one hardware? I don't know if the RS485 firmware is compatible with this hardware. If I understood correctly, this hardware is still experimental and therefore not relevant for me. I don't see any real advantage in the ALL-IN-ONE board compared to the individual modules, apart from better cable management. Somehow I imagined it differently, but that's another topic and doesn't belong here.

chapulino commented 10 months ago

thanks. Last question from which controller port do you connect the Controller to the inverter from RS485 or from CAMBUS? And did you have to close any JP?

moscito1010 commented 10 months ago

I am use the the Port with the battery pictogram

chapulino @.***> schrieb am Mo., 28. Aug. 2023, 20:14:

thanks. Last question from which controller port do you connect the Controller to the inverter from RS485 or from CAMBUS?

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1696132558, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASDNPK54AYFXINPMNFXOF6TXXTN2FANCNFSM6AAAAAA2334T6U . You are receiving this because you were mentioned.Message ID: @.***>

chapulino commented 10 months ago

Thanks, but the question was about the DIYBMS controller port. The one marked RS485 or the one labeled CAMBUS

image

moscito1010 commented 10 months ago

I Have the same inverter, it is the battery Port. This is the left rj45 Port. In 30min I am at home and i can send any pictures

chapulino @.***> schrieb am Di., 29. Aug. 2023, 08:24:

Thanks, but the question was about the DIBMS controller port. The one marked RS485 or the one labeled CAMBUS

[image: image] https://user-images.githubusercontent.com/14351899/263919747-3a1508cc-16de-433f-8940-0a3ee416e01f.png

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1696840943, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASDNPK4VLH2F7QSBHBEWNT3XXWDJNANCNFSM6AAAAAA2334T6U . You are receiving this because you were mentioned.Message ID: @.***>

chapulino commented 10 months ago

the doubt is not with the inverter.

The question is how the inverter is connected to the DIYBMS controller from which port: RS485 or CAMBUS of the DIYBMS controller. data is sent to the inverter

Wait rereading what you wrote I see that you use the J7 Sorry for the inconveniences

moscito1010 commented 10 months ago

axpert1 axpert2 I connect with the left RJ45 Port from the Inverter to RS485 on the BMS Controller

The Voltronic Axpert MAX series and others with this display as well as the successors with the large round display cannot use a CAN protocol, even if it says so in the description. I borrowed an original Pylontech to Voltronic cable and measured it. The Pylontech batteries can use MODBUS and CANBUS but MODBUS is used for the Voltronic devices. I really tested every possibility to connect the Axpert Max devices to the DIYBMS via CANBUS. That was an unsuccessful afternoon :-) Since I have 3 Axpert MAX from 3 OEMs, I wrote to every support (MPPsolar, Voltacon UK, SP24 Italy) Neither the OEMs nor Voltronic themselves give you a useful answer.

chapulino commented 10 months ago

Thank you, tonight we will tell you if we succeed, we are going to make a bus from the rs485 port of the controller to the inverter and to the current controller (both are connected to the port, as the Shunt has a terminating resistor, it will be the last on the bus, and We will test whether the JP4 of the controller should be open or closed and we will tell you and thank you very much for the explanations

El mar, 29 ago 2023 a las 10:49, moscito1010 @.***>) escribió:

[image: axpert1] https://user-images.githubusercontent.com/75945899/263954854-8b33e9ec-31c9-4080-a781-37d39ec6c0af.jpg [image: axpert2] https://user-images.githubusercontent.com/75945899/263954865-fd5555ac-6c13-4b1f-ba6a-acb98b001a96.jpg I connect with the left RJ45 Port from the Inverter to RS485 on the BMS Controller

The Voltronic Axpert MAX series and others with this display as well as the successors with the large round display cannot use a CAN protocol, even if it says so in the description. I borrowed an original Pylontech to Voltronic cable and measured it. The Pylontech batteries can use MODBUS and CANBUS but MODBUS is used for the Voltronic devices. I really tested every possibility to connect the Axpert Max devices to the DIYBMS via CANBUS. That was an unsuccessful afternoon :-) Since I have 3 Axpert MAX from 3 OEMs, I wrote to every support (MPPsolar, Voltacon UK, SP24 Italy) Neither the OEMs nor Voltronic themselves give you a useful answer.

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1697026728, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADNP4G53TUHZ2NXDVCQMEKLXXWUIRANCNFSM6AAAAAA2334T6U . You are receiving this because you commented.Message ID: @.***>

stuartpittaway commented 10 months ago

@chapulino you may run into issues on the RS485 if both shunt and inverter are connected - do they run at the same baud rate/parity ?

moscito1010 commented 10 months ago

Maybe IT is possible for you. I am use the little shunt addon and not the smart shunt.

Stuart Pittaway @.***> schrieb am Di., 29. Aug. 2023, 12:32:

@chapulino https://github.com/chapulino you may run into issues on the RS485 if both shunt and inverter are connected - do they run at the same baud rate/parity ?

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1697179746, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASDNPKZSPM24ZY7BN6MTFU3XXXAKVANCNFSM6AAAAAA2334T6U . You are receiving this because you were mentioned.Message ID: @.***>

chapulino commented 10 months ago

@chapulinoEs posible que tenga problemas en el RS485 si tanto la derivación como el inversor están conectados. ¿Funcionan a la misma velocidad/paridad de baudios? we do not know , this afternoon we will try all the options , with and without Current Shunt You can verify that if it controls the derivation of the all in one, although logically without the balancing functions by deviation of mean value and the activation of the heatsink fan, the all in one must be previously programmed on a controller with the latest firmware version so that this fan activation parameter is saved. As plan B we would have to add an add on current controller to the controller

moscito1010 commented 10 months ago

Sorry...what a Fan? A Fan for cooling the Shunt ?

Has the MODBUS communication between the controller and the BMS ever worked correctly? I built 2 Smartshunts and was able to connect to the shunt (19200baud) but no readings came from the shunt. It took me a few days to realize that all the INA228 I ordered were fake chips and I will not get any data. Since Stuart developed the shunt addon board it's been working great.

chapulino commented 10 months ago

Sorry...what a Fan? A Fan for cooling the Shunt ?

no, I mean the fan of the heatsink of the All in One resistors, but for now we focus on the RS485 communication

moscito1010 commented 10 months ago

I found some information in the pylontech documentation that might be helpful. grafik https://portal.segensolar.de/reseller/docs/Pylontech%20Compatible%20List%20V2.15%20ESS.pdf

chapulino commented 10 months ago

Thank you for your interest, the truth is that we have tried all the possible options but if it has been successful so far, at one point we even burned the ICs that provide RS485 service, it has already been replaced,

We have several questions that may help us.

Do you currently have the inverter in service with the DIYBMS? Do you have the DIYBMS Curren controller connected? Is it the internal or external model? If it is external, is the DIYBMS connection to the inverter through an RS485 BUS? We have seen that the DIYBMS Current Contoler can have its BaudRate modified so that it has the same as the 9600 inverter. Do you have a 120ohm resistor between A and B on the inverter side? Do you have to activate RS485 communication or is it activated in your firmware by default? In the tests carried out, it seems that if the Current controller via Modbus is not activated, RS485 communication is not enabled.

I'm sorry, we are very lost and we can't get the firm to work.

El mié, 30 ago 2023 a las 22:17, moscito1010 @.***>) escribió:

I found some information in the pylontech documentation that might be helpful. [image: grafik] https://user-images.githubusercontent.com/75945899/264462794-38c9f88e-613c-48be-8424-d5fac886bff2.png

https://portal.segensolar.de/reseller/docs/Pylontech%20Compatible%20List%20V2.15%20ESS.pdf

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1699779691, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADNP4G4GNQPLOYQDNZUBHZDXX6NUPANCNFSM6AAAAAA2334T6U . You are receiving this because you were mentioned.Message ID: @.***>

moscito1010 commented 10 months ago

I use 3 Axpert MAX 7.2KW inverters with a DIYBMS and the RS485 firmware I installed this branch https://github.com/ruza87/diyBMSv4ESP32/tree/pylon_rs485 I use the Current ADDON not the external shunt. I use RS485 to connect to the AXPERT MAX. I set the solder bridge for RS485 (solder on the two contacts, no extra resistance) Only A + B must be connected to the RS485 port, voltage and ground have no place there. The PLY protocol must be activated on the inverter. grafik grafik controller inverter

Jestergnet commented 10 months ago

Hello, what is the pattern of RJ45 on the inverter side?

moscito1010 commented 10 months ago

Colleague, do you also read what we write? :-) https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1695173258

Jestergnet commented 10 months ago

Colleague, do you also read what we write? :-)

I'm sorry. I saw above the message, but did not attach importance.

moscito1010 commented 10 months ago

Sorry...what a Fan? A Fan for cooling the Shunt ?

no, I mean the fan of the heatsink of the All in One resistors, but for now we focus on the RS485 communication

sorry i don´t no what you mean.

Jestergnet commented 10 months ago

Sorry...what a Fan? A Fan for cooling the Shunt ?

no, I mean the fan of the heatsink of the All in One resistors, but for now we focus on the RS485 communication

sorry i don´t no what you mean.

I read the message above about the pinout, but did not betray the importance.

moscito1010 commented 10 months ago

Colleague, do you also read what we write? :-)

I'm sorry. I saw above the message, but did not attach importance. rj45

chapulino commented 10 months ago

Thank you very much for the explanation, the truth is that in the end my friend, after many tests, was able to establish communication between the DIYBMS BMS and his Axpert inverter (Voltronic variant) It has a 15-module 18650 LITHIUM battery, so the voltages are a little higher than those of Pylontech, and the inverter does not allow these parameters to be adjusted. If a Pylontech is chosen as the battery, the voltage parameters, etc. remain the same. fixed...

He is going to modify the battery to 14 cells to continue testing. We will report the progress here, I reiterate, thank you very much.

Fernank2 commented 10 months ago

Hello, I have a 15 Series 21700 cell powerwall with an Axpert IV MKS inverter and the DiyBms with internal current sensor.

I have installed the DiyBms version of Ruza87 with support for Pylontech RS485 batteries.

When I connect the battery and communication is established between DiyBms --> inverter (approximately 10 seconds) the inverter shows me error 60.

The axpert manual says the following about this error 60:

"If battery status is not allowed to charge and discharge after the communication between the inverter and battery is successful, it will show code 60 to stop charging and discharging battery."

What state is this?

On the other hand, some of the values ​​in the DiyBMS charge and discharge menu configuration are written to the inverter. parameter

max. chargin current param. 2 bulk chargin voltage param. 26 floating chargin voltage param. 27 Low DC cut-off voltage param. 29

Should it write DiyBMS in the inverter? Can you help me with this error 60?

moscito1010 commented 9 months ago

yes, it should write to the charge controller. 60 means no connection to the BMS. the RS495 cable is 2 wires. You don't need GND or voltage, just the two data lines.

Fernank2 commented 9 months ago

yes, it should write to the charge controller. 60 means no connection to the BMS. the RS495 cable is 2 wires. You don't need GND or voltage, just the two data lines.

The communication failure with the BMS is error 61. I have error 60. The BMS communicates with the inverter because the BMS writes the parameters to the inverter.

moscito1010 commented 9 months ago

And you changed the barrery Mode to pyl?

Fernank2 @.***> schrieb am Mi., 13. Sept. 2023, 23:16:

yes, it should write to the charge controller. 60 means no connection to the BMS. the RS495 cable is 2 wires. You don't need GND or voltage, just the two data lines.

The communication failure with the BMS is error 61. I have error 60. The BMS communicates with the inverter because the BMS writes the parameters to the inverter.

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1718327977, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASDNPKZUGDHBLXKF6GGY5X3X2IPB7ANCNFSM6AAAAAA2334T6U . You are receiving this because you were mentioned.Message ID: @.***>

Fernank2 commented 9 months ago

And you changed the barrery Mode to pyl? Fernank2 @.> schrieb am Mi., 13. Sept. 2023, 23:16: yes, it should write to the charge controller. 60 means no connection to the BMS. the RS495 cable is 2 wires. You don't need GND or voltage, just the two data lines. The communication failure with the BMS is error 61. I have error 60. The BMS communicates with the inverter because the BMS writes the parameters to the inverter. — Reply to this email directly, view it on GitHub <#227 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASDNPKZUGDHBLXKF6GGY5X3X2IPB7ANCNFSM6AAAAAA2334T6U . You are receiving this because you were mentioned.Message ID: @.>

Yes

moscito1010 commented 9 months ago

@Fernank2 https://voltaconsolar.com/blog/knowledge-base/how-to-resolve-error-61-with-pylontech-lithium-batteries-and-voltacon-solar-inverters/ "Error 61 means that the batteries are not communicating with the inverter, and the BMS is not installed successfully. There are a few reasons why"

This is an example cable for an RS232 if I understand correctly. You have to build an rs485 cable with the wiring I specified. If the inverter can RS485

grafik

Fernank2 commented 9 months ago

@Fernank2 https://voltaconsolar.com/blog/knowledge-base/how-to-resolve-error-61-with-pylontech-lithium-batteries-and-voltacon-solar-inverters/ "Error 61 means that the batteries are not communicating with the inverter, and the BMS is not installed successfully. There are a few reasons why"

This is an example cable for an RS232 if I understand correctly. You have to build an rs485 cable with the wiring I specified. If the inverter can RS485

grafik

I insist, my error is error 60, I don't have error 61, okay? 60 YES—61 NO.

Fernank2 commented 9 months ago

on the other hand @moscito1010 , you say it works for you… can you send a screenshot of your configuration of all the diybm sections? It also sends a capture of the current parameters of your inverter. parameter 3, 26, 27 and 29. please

moscito1010 commented 9 months ago

https://powerforum.co.za/topic/8914-axpert-mks-5k4kw-error-60/

Fernank2 @.***> schrieb am Fr., 15. Sept. 2023, 15:47:

@Fernank2 https://github.com/Fernank2 https://voltaconsolar.com/blog/knowledge-base/how-to-resolve-error-61-with-pylontech-lithium-batteries-and-voltacon-solar-inverters/ "Error 61 means that the batteries are not communicating with the inverter, and the BMS is not installed successfully. There are a few reasons why"

This is an example cable for an RS232 if I understand correctly. You have to build an rs485 cable with the wiring I specified. If the inverter can RS485

[image: grafik] https://user-images.githubusercontent.com/75945899/267994762-89afd6fc-6495-4760-85ae-be8eb2678f58.png

I insist, my error is error 60, I don't have error 61, okay? 60 YES—61 NO.

— Reply to this email directly, view it on GitHub https://github.com/stuartpittaway/diyBMSv4ESP32/issues/227#issuecomment-1721312707, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASDNPK3GSI3OQSP5KKQBIILX2RL65ANCNFSM6AAAAAA2334T6U . You are receiving this because you commented.Message ID: @.***>

Fernank2 commented 9 months ago

https://powerforum.co.za/topic/8914-axpert-mks-5k4kw-error-60/ Fernank2 @.***> schrieb am Fr., 15. Sept. 2023, 15:47:

I have already done all that. that is not my case because I am emulating phylontech and my error 60 only happens with phylontech485 and I only have 1 investor. Does it really work for you? @moscito1010 , you say it works for you… can you send a screenshot of your configuration of all the diybm sections? It also sends a capture of the current parameters of your inverter. parameter 3, 26, 27 and 29. please

moscito1010 commented 9 months ago

That won't help you. I think I have a better solution for you.

picś comes

Fernank2 commented 9 months ago

The images of a system that you say works for you will help me, compare them with mine, which does not work. I think it doesn't work for you either. thanks for your answers. Let's see if Ruza responds. I'll ask Stuart too.

moscito1010 commented 9 months ago

Here are a few pictures of my settings. I would like to point out that I also use an active equalizer that starts working at 3.45v and stops working at 3.4v. The settings are from my test system which is connected to my Axpert Max 7.2 with RS485 Pylontech.

Modules: grafik

Rules: grafik

Settings: grafik

Charge/Discharge grafik

Voltage and Amperemeter: grafik

moscito1010 commented 9 months ago

Here is the possible solution: You can use a “men in the middle”. The SA (Solar Assistant) software helps you use devices that cannot communicate directly. The BMS and the Voltronic inverter are connected to the SA Rasperry pi using suitable adapters. In this case a USB-CANBUS adapter and a USB-RS232 (FTDI) adapter. On the inverter you then set the battery type to USE because SA takes over the control with its emulated BMS. The DIYBMS tells SA what it wants and SA controls the inverter.

I just want to switch to this solution myself and have therefore asked SA support. SA offers a USB-CANBUS cable with the appropriate programming for various inveter on its website. The cable is not expensive. The software is not expensive and it is a lifetime license at no additional cost. The disadvantage is that SA uses a Raspberry completely, you can't install anything else. But since I have a few more Raspberries, it's not that dramatic and the Raspi's are available and affordable again.

But I think we should explore this in a different way. That no longer has anything to do with diybsm support. pvbeere@tutanota.de or even better Telegram: https://t.me/DIYBMSv4

The advantage of the whole thing is that we can use the diybms with unpatched firmware. I just don't know if the RS485 fork is well maintained and of course Stuart can't ensure that the fork stays up to date. That's why I decided to use the original and hope that Stuart will provide RS485 support himself at some point. Until then, I'd rather stick with the original.