Peugeot E-208/Corsa E CATL BMS CAN decoding
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
case 0x125:
battery_voltage = (rx_frame.data.u8[3] << 8) | rx_frame.data.u8[4];
battery_current = (rx_frame.data.u8[5] - 0x58) << 8 | rx_frame.data.u8[2];
break;
datalayer.battery.status.voltage_dV = ((float)battery_voltage / 128) * 10;
datalayer.battery.status.current_dA = ((float)battery_current / 256) * 10;
This is a code snippit from the battery emulator software that I added to.
This is just my guess but it seems to work ok, still very granular readings not much precision i wonder if the BMS needs to be activated via canbus to work in a normal mode.
battery_voltage = (rx_frame.data.u8[3] << 8) | rx_frame.data.u8[4];
battery_current = (rx_frame.data.u8[5] - 0x58) << 8 | rx_frame.data.u8[2];
break;
datalayer.battery.status.voltage_dV = ((float)battery_voltage / 128) * 10;
datalayer.battery.status.current_dA = ((float)battery_current / 256) * 10;
This is a code snippit from the battery emulator software that I added to.
This is just my guess but it seems to work ok, still very granular readings not much precision i wonder if the BMS needs to be activated via canbus to work in a normal mode.
-
- Posts: 567
- Joined: Thu Jul 04, 2019 6:35 pm
- Location: Somerset, UK
- Has thanked: 75 times
- Been thanked: 217 times
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
Thanks for that. I've made some updates to my zombie module to show battery voltage as well. I had to make some slight changes to the calculations to get the battery voltage showing correctly.Yevhen wrote: ↑Thu Dec 12, 2024 9:38 am case 0x125:
battery_voltage = (rx_frame.data.u8[3] << 8) | rx_frame.data.u8[4];
battery_current = (rx_frame.data.u8[5] - 0x58) << 8 | rx_frame.data.u8[2];
break;
datalayer.battery.status.voltage_dV = ((float)battery_voltage / 128) * 10;
datalayer.battery.status.current_dA = ((float)battery_current / 256) * 10;
This is a code snippit from the battery emulator software that I added to.
This is just my guess but it seems to work ok, still very granular readings not much precision i wonder if the BMS needs to be activated via canbus to work in a normal mode.
I still need to play with current a little bit. Not quite there yet, I'm testing this by playing back logs to my Zombieverter and checking spot values.
Code: Select all
case 0x125:
SoCValue = data[0] * 0.4;
Param::SetFloat(Param::SOC,SoCValue);
batteryvoltage = (data[3] << 8) | data[4];
udcvoltage = (batteryvoltage / 128);
current = (data[5] << 8) | data[2];
batterycurrent = (current/256) / 10;
if (Param::GetInt(Param::ShuntType) == 0)//Only populate if no shunt is used
{
Param::SetFloat(Param::idc,batterycurrent);
Param::SetFloat(Param::udc2, udcvoltage);
}
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
I also find that SOC can be read out in reg 0x358 0 byte.
case 0x358:
battery_soc = rx_frame.data.u8[0];
0-100 in decimals. No need for scaling.
But I found out that SOC is "frozen" will not move even if the battery is cycled up and down, which confirms my suspicion that some kind of activation of the BMS is needed via CAN bus.
case 0x358:
battery_soc = rx_frame.data.u8[0];
0-100 in decimals. No need for scaling.
But I found out that SOC is "frozen" will not move even if the battery is cycled up and down, which confirms my suspicion that some kind of activation of the BMS is needed via CAN bus.
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
Is this battery from heavily crashed car? Sometimes BMS is locked if few airbags are deployed during accidentYevhen wrote: ↑Fri Dec 13, 2024 3:36 pm I also find that SOC can be read out in reg 0x358 0 byte.
case 0x358:
battery_soc = rx_frame.data.u8[0];
0-100 in decimals. No need for scaling.
But I found out that SOC is "frozen" will not move even if the battery is cycled up and down, which confirms my suspicion that some kind of activation of the BMS is needed via CAN bus.

-
- Posts: 4
- Joined: Mon Nov 04, 2024 8:58 pm
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
anyone worked out how to instruct the bms to balance ?
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
Anyone has news about decoding the current?
with:
What should be 3.8A is showing as 1A
with:
Code: Select all
case 0x125:
battery_current = ((((rx_frame.data.u8[5] - 0x58) << 8) | rx_frame.data.u8[2]) / 256) * -10;
-
- Posts: 19
- Joined: Sun Aug 20, 2023 8:30 pm
- Location: South Cumbria, UK
- Has thanked: 6 times
- Been thanked: 5 times
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
Hi Folks, apologies for hijacking this thread.
I have a MG 40Kwh pack, which uses CATL modules, so it is probable that the modules use the same sort of BMS. I cannot find much in the way of info on the battery pack controller, it has LOTS of pins, and a big SOC on board, so I am shying away from trying to use that controller.
My plan is to connect direct to the string of pairs of modules using an ESP32 via a MAX17841B.
My question is this - is there any info on the protocol used on this interface, I figure that I need to send a READ message to the first of the string of modules, and this causes a domino effect where each passes it's data to the next in the string and eventually at the other end of the string, out pops a series of datasets, one for each module.
As far as I can see by looking at the module PCBs, balancing is done on a per module pair basis, and differences in the pairs of modules is reported but not fixed during normal operation.
I read somewhere on a MG owner thread that cell balancing only occurs at full battery charge, so, does the battery pack controller kick this off, or does it automatically start balancing at a certain module pair voltage.
Any help on understanding how this works on the peugeot modules appreciated.
Pete
I have a MG 40Kwh pack, which uses CATL modules, so it is probable that the modules use the same sort of BMS. I cannot find much in the way of info on the battery pack controller, it has LOTS of pins, and a big SOC on board, so I am shying away from trying to use that controller.
My plan is to connect direct to the string of pairs of modules using an ESP32 via a MAX17841B.
My question is this - is there any info on the protocol used on this interface, I figure that I need to send a READ message to the first of the string of modules, and this causes a domino effect where each passes it's data to the next in the string and eventually at the other end of the string, out pops a series of datasets, one for each module.
As far as I can see by looking at the module PCBs, balancing is done on a per module pair basis, and differences in the pairs of modules is reported but not fixed during normal operation.
I read somewhere on a MG owner thread that cell balancing only occurs at full battery charge, so, does the battery pack controller kick this off, or does it automatically start balancing at a certain module pair voltage.
Any help on understanding how this works on the peugeot modules appreciated.
Pete
Pete
- tom91
- Posts: 2360
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 204 times
- Been thanked: 556 times
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
Yes, this is frowned upon and completely off topic. why are you posting here, this is CAN so external of the pack.
search.php?keywords=MAX17823B
viewtopic.php?t=2181&hilit=MAX17823B
viewtopic.php?p=20335#p20335
-
- Posts: 19
- Joined: Sun Aug 20, 2023 8:30 pm
- Location: South Cumbria, UK
- Has thanked: 6 times
- Been thanked: 5 times
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
I was rather hoping that someone would be able to point me in the correct direction - so thanks
Pete
Pete
Pete
- tom91
- Posts: 2360
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 204 times
- Been thanked: 556 times
Re: Peugeot E-208/Corsa E CATL BMS CAN decoding
Please use the search function, you had the key words in your post.peterdiffey wrote: ↑Thu May 22, 2025 12:30 pm I was rather hoping that someone would be able to point me in the correct direction