ZEVA 24S BMS application

Topics concerning OEM and open source BMSes
Post Reply
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

ZEVA 24S BMS application

Post by arber333 »

I got several 24S ZEVA BMS modules here and i decided to make modular battery 96S out of 4x 24S boxes. This ZEVA BMS will lend itself nicely to such use. https://www.zeva.com.au/index.php?product=143
I will document assembly and integration in this thread.
img BMS.jpeg
01515_8An76SFYWGp_0t20CI_1200x900.jpg
Not to be confused those modules are primarily used for data gathering. Their mode of operation is for master VCU to send data request on the line and each module would respond with several packets where cell data will be stored. Temperature as well...
zeva bms 12 cell diagram.png
Balancing mode and cell level is commanded by master request in 2 byte telegram.
CAN bus instructions are in this manual which is made for 12S version BMS
BMS12v3_CAN_Protocol.pdf
(491.78 KiB) Downloaded 85 times
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

First i connected the cell connector for 12S, that is 13 positiuons to the battery... This battery was assembeled from 2x section of 12S Volt gen1 cells connected in parallel. I even connected each cell in parallel using 0.75mm2 cables. I will have to separate those paralleled cells.
Later on this will let me test full 24S BMS capability later.
20241219_195541.jpg
I then connected the 13s connector to my ZEVA BMS
20241219_195554.jpg
Check this manual before connecting...
BMS24_Manual.pdf
(551.41 KiB) Downloaded 105 times
When i also connected the CAN and 12V power supply connector from the left side as on the upper photo system would not respond to IDx300 which it needs to get response from BMS modules. The error was two part.

First of course i needed to change the CAN input connector from master side to the right side
20241219_200948.jpg
Secondly IDx300 is not valid command. At least not in hex. 300 is the sum of ID number in hex, so IDx12C then...
I send IDx12C "extended" address with data in 2 bytes which should mean command for cell balancing value. For now i only send 00 00.
And CAN bus came to life!
BMS CAN reply.jpg
I used 250kbps signal with "extended" ID repeating at 100ms interval.
BMS CAN reply1.jpg
Later on i tested the CAN lines from left to right connection to my CAN reader from CH1 and CH2.
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

I have now separated two 12S cell packs and made 24S connections for BMS.
I connected them in series for 24S.
20241229_190038.jpg
BMS connected for 24S cells. Communicating with CAN bus.
20241229_190025.jpg
Each halfh of 12S of BMS module has a different address that is set by the selector on the top left on the module.
For position 0 the both adresses are 0x12c for the first 12S (rightmost) and 0x136 for the second 12S (leftmost).
When requesting cell report the 2byte content of the telegram refers to module balancing threshold in mV.

Commands to extract report from 24S module and impose 4.10V threshold for balancing are therefore:
0x12C 10 04
Reports returned:
0x12d x0 x0 x0 x0 x0 x0 x0 x0
0x12e x0 x0 x0 x0 x0 x0 x0 x0
0x12f x0 x0 x0 x0 x0 x0 x0 x0
0x130 x0 x0 x0 x0 x0 x0 x0 x0

0x136 10 04
Reports returned:
0x137 x0 x0 x0 x0 x0 x0 x0 x0
0x138 x0 x0 x0 x0 x0 x0 x0 x0
0x139 x0 x0 x0 x0 x0 x0 x0 x0
0x13a x0 x0 x0 x0 x0 x0 x0 x0

telegrams 0x130 and 0x13a contain thermistor values for each side of the module. If connected to 100K NTC they give cell temperature, see example at 0x130 byte0 value is 39. That is 39hex = 57dec and according to design temp info is xx - 40 = 17deg C.
Screenshot 2025-01-08 210017.jpg
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

Next i connected the control board which is called EVMS V3.1
This controler is innitiating CAN transmission and provides 12V power for BMS 24S modules.
Later on when i will wire this EVMS into the car i will try to make more detailed post
20250108_205355.jpg
Next was the LCD. This LCD is touchscreen that can be obtained on Aliexpress
https://www.aliexpress.com/item/3288298 ... 1802JTpgQ3
Surprisingly when i connected CAN bus and power to LCD it immediately started and got the first module cells.
20250108_205731.jpg
20250108_205745.jpg
Since 24S module is made from two 12S parts i needed to enable number of modules and cells inside LCD. When i corrected settings i got good account of all cells.
20250108_205558.jpg
20250108_205535.jpg
EDIT: I am really surprised how easy it was to connect everything together on CAN bus and LCD and it worked the first time!
I have to hand it to Ian he really made a good system. Next i will try to connect sevaral 24S modules together.
broker360
Posts: 3
Joined: Wed Oct 02, 2024 1:26 pm

Re: ZEVA 24S BMS application

Post by broker360 »

Did you build these yourself or buy them built and flashed?
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

broker360 wrote: Wed Jan 29, 2025 10:58 am Did you build these yourself or buy them built and flashed?
I bought some of them already built and flashed for 250kbps. Those i tested here.
I am now working on building one more 24S BMS with one EVMS control board and at least one current sensor board. All of them have chips i will need to flash.
I expect next post to be instruction on how to flash hex firmware or reflash complete system with different kbps.
Stay tuned...
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

From JLPCB i got ZEVA Current sensor boards I ordered.
IMG20250315181318.jpg
IMG20250315181300.jpg
I soldered main chip ATMega16M and support components. For sensor i used LEM HTFS400 sensor.
When i got it together i used my AT programmer.
For this i use just a simple AVR USBasp programmer with custom built cable.
https://hobbycomponents.com/usb-interfa ... er-adaptor

Program of choice is avrdude
https://github.com/mariusgreuel/avrdude ... me-ov-file

Because i struggle with using command line i found this GUI interface AVRdudess, it makes my life so much easier
https://blog.zakkemble.net/avrdudess-a-gui-for-avrdude/

Boards must be connected to 12V supply, just because wiring is done that way. If not programmer will not detect the chip.
I connected the board by hand and kept pins pressed together. Then i set the speed of communication to 8bit and tried to autodetect the chip.
I selected my hex file and set the fuses for programming.
IMG20250315190612.jpg
IMG20250315190642.jpg
When i finished the LED lit up!
As hall sensor has trouble with centering i pressed the button and when LED stopped blinking sensor is centered.

I made 3d printed casing for this sensor so circuit is protected.
IMG20250315190721.jpg
Stil have to connect this sensor to CAN lines, but i think it will not be a problem as it is a through connector.
Will report back with some photos...
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

Ya...

I connected current sensor module and put one side of the DC rail through it to sense current.
Idea is to put sensor on the line between BMS modules and keep communication in one line.
Posnetek zaslona 2025-03-18 081018.png
I used LCD to enter setup and prepared some parameters like max current and cell levels.

It seems i programmed that chip with 300A parameters code! That is starting sensor value.
My sensor is actually 400A. There is a multiplier parameter which takes care of larger sensors for the same code.

Code: Select all

// Code for ATmega16M1 (also suitable for ATmega32M1, ATmega64m1)
// Fuses: 8Mhz+ external crystal, CKDIV8 off, brownout 4.2V

#define SHUNT_VERSION	1 // 1 or 0, same code works for hall sensor or shunt interface types
#define HALL_MULTIPLIER	2L	// Compared with 300A sensor, so 600A is 2, 1200A is 4
#define DEADBAND        80L // Tolerance for noise/offset around zero, 80L equates to about +/-0.2A with 300a sensor
#define CAN_BAUD_RATE		250 // Code knows how to do 125, 250, 500, 1000kbps
#define USE_29BIT_IDS		1
#define CAN_ID		40
When i first connected current sensor LCD changed first page to show SOC%.
The reading error is shown in sensor reporting less current. You can see the difference in sensor from my EVdisplay.
IMG20250318072818.jpg
IMG20250318072808.jpg
It seems sensor reads like 1/2 times so i think i will need to use multiplier 2L....

Also voltage reading is confused. While it reads battery values and makes the addition it also requires direct HV connection to main board. Later on i will make a secure fused connection for HV sensing.
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

#define SHUNT_VERSION 0 // for hall sensor
#define HALL_MULTIPLIER 1L // for 300A
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

Yes i have sensor for 600A so i need sensitivity 2L then.
But compiling the code correctly is a pain...

Also i use sensor LEM sensor for 400A and yet Ian set it up as 600A sensor probably because of range...
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

if you dont want to modify firmware or do a new compile You can modify hardware. See the lines 32 and 224 in the code:

#define SELECTOR1 (!(PIND & (1<<PD3)))
#define SELECTOR2 (!(PIND & (1<<PD2)))
#define SELECTOR3 (!(PIND & (1<<PD4)))
...
// Selector 2 and 1 used for current size.. 00 means 100A, 01 means 200A, 10 means 500A ? 11 means 50A?

if (!SELECTOR1 && !SELECTOR2) // 100A shunt
result *= 2L;
else if (SELECTOR1 && !SELECTOR2) // 200A shunt
result *= 4L;
else if (!SELECTOR1 && SELECTOR2) // 500A shunt
result *= 10L;

if (SELECTOR3) // 50mV shunt instead of 75mV, current will be 1.5x higher
result = result*3L/2L;

return result*102L/190L; // was result*10L/19L but needed to be 2% higher
}
______________
so to get 2L , you need apply SELECTOR1 and SELECTOR2 , so put PD3 and PD2 to earth in hardware ---> go to the scheme and see that PD3 and PD2 are pin2 and 3 of PROG block of 5 pins
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

imagen.png
imagen.png (26.28 KiB) Viewed 2525 times
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

Hm... I Will go over my schematic but i use Hall sensor and it seems it doesnt have as much hardware odds and ends as shunt version. Will report back...

EDIT: Ian posted .hex file on AEVA Forum! I simply repost it for others. I will get to explaining programming later on when i resolve my issues.

EDIT2: Shoot! Didnt work! When i try to upload your 600A code process is completed but in the end i dont get LED lit. Chip just sits there and gives no CAN traffic either.... I use fuses FF DF and FA.

Also I managed to compile code and i setup for hall sensor

Code: Select all

#define SHUNT_VERSION	0 // 1 or 0, same code works for hall sensor or shunt interface types

#define HALL_MULTIPLIER	2L	// Compared with 300A sensor, so 600A is 2, 1200A is 4
#define DEADBAND        80L // Tolerance for noise/offset around zero, 80L equates to about +/-0.2A with 300a sensor

#define CAN_BAUD_RATE		250 // Code knows how to do 125, 250, 500, 1000kbps
#define USE_29BIT_IDS		1
But there is no change when i finish programming... Its like the original code stays in... what did i do wrong?

EDIT3: Ian compiled the 600A code for ATmega64 chips thats why it wouldnt work on my ATmega16M1. Now he changed to ATMega16M1, Success!
Attachments
EVMS3_Current_Sensor_600A.hex
(6.11 KiB) Downloaded 21 times
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

@chentron.... I see another problem....
My 8x 12S modules are communicating and 384V voltage is correctly displayed.
BUT there is an intermadiate voltage of 123V being displayed at about 1s interval. Display alternates between "running" and "idle" state with "idle" being the state when 123V is displayed. How can i make this go away?
I tried to connect HV on the EVMS3 pins and that didnt change anything. I do have only opto circuit connected. Nothing of the 4W resistors or precharge command. I use my own precharge circuit with drive VCU.
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

running state is when 12v are applied to "key in" in EVMS3. (Just for info: Balancing cells is only done when evms3 is in running state.)
no 12v on "key in" automatically changes to Idle.
Alternating running/idle is strange. Can you inspect this before to revise why 123v are displayed.
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

This is the vide of me starting the car which provides 12V signal to RUN state.
My battery is 384Vdc 96S
BMS EVMS3 alternates between 123V and 384V and RUN and IDLE state!
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

chentron wrote: Sat Mar 22, 2025 2:32 pm running state is when 12v are applied to "key in" in EVMS3. (Just for info: Balancing cells is only done when evms3 is in running state.)
no 12v on "key in" automatically changes to Idle.
Alternating running/idle is strange. Can you inspect this before to revise why 123v are displayed.
Balancing is actually going on with both "Running" and "Charging" modes, its just needs to see high enough cell voltages to start balancing.
I find it quite good and effective process.
But all the time that 123V is interfeering into comms. Sometimes it will stay at 123V for 1s but other times it will flick at 4Hz. Why is this significant? Well CAN communication runs at 4Hz. This means something is probably out of sync...
I dont know from where it originates but i will try to read the code and see if i can change that...
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

the total voltage shown in the screen is the summatory of all the cells calculated individually.
So, what I would try is to isolate which bms slave is provoking this flicking voltage reading. Mounting each cell block and testing when appear the flicking.
If I had to bet, I would say that it is logical that it fails between cells 30s/31s or 66s/67s.
Once identified the failed one, probably you could find in the electronic a not reliable component or soldering. But You probably know much more than me about this.

going to idle state, is probably that 123v is less than the minimum voltage required in the setup so it can not be in running mode.
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

chentron wrote: Fri Apr 18, 2025 3:53 pm the total voltage shown in the screen is the summatory of all the cells calculated individually.
So, what I would try is to isolate which bms slave is provoking this flicking voltage reading. Mounting each cell block and testing when appear the flicking.
If I had to bet, I would say that it is logical that it fails between cells 30s/31s or 66s/67s.
Once identified the failed one, probably you could find in the electronic a not reliable component or soldering. But You probably know much more than me about this.

going to idle state, is probably that 123v is less than the minimum voltage required in the setup so it can not be in running mode.
Hm... so this would mean system is loosing comms in the time it takes to show the next message?
I will try to unplug all modules and test one by one like you said.

However i see the same thing if i only use one 12S module on my workbench. This first led me to belive it is something software related...
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

I am just follow the logic.
As you say if that happen in your bench with only one BMS12 , but also with other different BMS12 alone, look that the problem can be with the EVMS brain or the display.
I dont think software is the cause, because i have the same software working correctly.
arber333
Posts: 3549
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 130 times
Been thanked: 328 times
Contact:

Re: ZEVA 24S BMS application

Post by arber333 »

chentron wrote: Fri Apr 18, 2025 10:26 pm I am just follow the logic.
As you say if that happen in your bench with only one BMS12 , but also with other different BMS12 alone, look that the problem can be with the EVMS brain or the display.
I dont think software is the cause, because i have the same software working correctly.
How do you make your cables?
I make a pair of twisted cables out of two 0,5mm2 blue and white ordinary soft wires twisted in a right hand way using my battery drill.
Then i make 12v power supply pair out of red and black 0.5mm2 and twist them in the same way (to help with any EMI). I dont use any shield wire.
Do you use shield wire? If so, how do you implement this? I mean do you just use one wire along with the rest or do you use anything special?
chentron
Posts: 117
Joined: Mon Feb 22, 2021 3:25 pm
Location: Spain
Has thanked: 42 times
Been thanked: 10 times

Re: ZEVA 24S BMS application

Post by chentron »

in the stationary battery i am using cabling recycled from ethernet cable unshielded. my battery is about 342v (85s actually) , maximum of 15A but normally with very low amps so no problem with EMI.
in the car, still in construction and never run more than 200m around my home, have shielded ethernet cable comunicating the battery boxes(one pair for data other pair for 12v), but inside the batteries unshield ethernet cable for the cells. the slave BMS24 are inside the battery boxes
Post Reply