Canbus and PID for the IPace

All Jaguar I-Pace related discussions
User avatar
ANBO
Posts: 146
Joined: Fri Mar 27, 2020 7:50 pm
Location: Switzerland

Re: Canbus and PID for the IPace

Post by ANBO » Sun Feb 21, 2021 6:10 pm

kermit68 wrote:
Sun Feb 21, 2021 4:49 pm
ANBO wrote:
Sat Feb 20, 2021 11:54 am
Question or consideration: With the Battery Voltages PIDs the divisor changed from an earlier assumption of 100 to the current assumption of 108. I suppose because it is not measured as a percentage (100) but as a factor of the number of cells (108)?
I may have missed some posts but I can't recall that we should use 108 as divisor to calculate the voltage .... To my memory the only 108 related voltage calculation is to get cell voltage average from battery pack voltage (0x490f).
Are you sure about that ?
No not sure at all. Was just wondering about the multiplication with 108 as proposed, when the value of 4912 was first divided by 100...
🇨🇭 EV400 HSE (MY2020; MAR 2020); 18" ❄
⚙️ H264 ⚙️ ICM: S20C ⚙️ VCS: 19.2
⚙️ BECS: BP-AAE-BC-AC-BE ⚙️ Maps: 06.2020

Maxwell_400
Posts: 395
Joined: Mon Oct 14, 2019 10:09 am
Location: Norway

Re: Canbus and PID for the IPace

Post by Maxwell_400 » Sun Feb 21, 2021 10:53 pm

kermit68 wrote:
Thu Feb 18, 2021 12:11 pm
Maxwell_400 wrote:
Thu Feb 18, 2021 9:43 am

We are getting closer, I was happy with 36 as charge efficiency should be in the range 95%-98% and 1/36 = 1s/1hr x 100.

But 36 to 38 then and 38 is closer to 40 as I have used as a good value from energy loss measurements.
Just to add some noise .... Using 40 and calculating istant power as current times voltage I got a peak power of 300kw (during an overtake) which is in excess of the declared 295kw. Using 36 or 38 as divisor to calculate current would lead to even higher power values so I'm almost conviced we can't go lower than 40.
I drove the car to up to my mountain cabin, charged it to 100% and checked the regenerated power against the 'max charge' level when I went home. This way I could find the divisor for the current as the regen power never will exceed max charge level.

Figure_1.png

And guess what, a divisor of 40 fits perfectly.
I-Pace SE++, MY20, 18" summer & winter, no panoroof, towbar, spare wheel, 20C, TCU 19.2, BECS: BP-AAE-BC-AC-BE

kermit68
Posts: 536
Joined: Sat Sep 15, 2018 1:06 pm
Location: Rome / Italy

Re: Canbus and PID for the IPace

Post by kermit68 » Mon Feb 22, 2021 9:31 am

Maxwell_400 wrote:
Sun Feb 21, 2021 10:53 pm

I drove the car to up to my mountain cabin, charged it to 100% and checked the regenerated power against the 'max charge' level when I went home. This way I could find the divisor for the current as the regen power never will exceed max charge level.

And guess what, a divisor of 40 fits perfectly.
Very good ;)
MY20 Yulong White SE, 20", air suspension, privacy glass, black pack and other fine stuffs

Maxwell_400
Posts: 395
Joined: Mon Oct 14, 2019 10:09 am
Location: Norway

Re: Canbus and PID for the IPace

Post by Maxwell_400 » Mon Feb 22, 2021 11:48 am

kermit68 wrote:
Mon Feb 22, 2021 9:31 am
Maxwell_400 wrote:
Sun Feb 21, 2021 10:53 pm

I drove the car to up to my mountain cabin, charged it to 100% and checked the regenerated power against the 'max charge' level when I went home. This way I could find the divisor for the current as the regen power never will exceed max charge level.

And guess what, a divisor of 40 fits perfectly.
Very good ;)
Yes and when I integrate (current x voltage) I get 20kWh/100km which is exactly the same as reported by the triplog in the display. SOC delta was 23%, this gives a battery capacity of 86kWh which is very close to 90 x SOH = 85.5kWh. (By a coincidence the distance driven is 100km).

Then we have it, we can calculate a lot of interesting parameters, like battery capacity, internal resistance, range, charge loss, energy regenerated, etc.

Some options for calculating the energy used:

Integration (current x voltage) over time = 20.1 kWh/100km = Excact the same as triplog in the car
Integration current over time x average voltage = 20.6 kWh/100km
Integration current over time x nominal voltage (108x3.6) = 18.7kWh/100km
Average current x average voltage x time used = 20.6 kWh/100km
Average current x nominal voltage (108x3.6) x time used = 18.7kWh/100km

Battery pack is at 129mOhms which is very high at +10 degrees but I guess it is due to the high SOC.
I-Pace SE++, MY20, 18" summer & winter, no panoroof, towbar, spare wheel, 20C, TCU 19.2, BECS: BP-AAE-BC-AC-BE

kermit68
Posts: 536
Joined: Sat Sep 15, 2018 1:06 pm
Location: Rome / Italy

Re: Canbus and PID for the IPace

Post by kermit68 » Mon Feb 22, 2021 11:56 am

Maxwell_400 wrote:
Mon Feb 22, 2021 11:48 am

Yes and when I integrate (current x voltage) I get 20kWh/100km which is exactly the same as reported by the triplog in the display. SOC delta was 23%, this gives a battery capacity of 86kWh which is very close to 90 x SOH = 85.5kWh. (By a coincidence the distance driven is 100km).

Then we have it, we can calculate a lot of interesting parameters, like battery capacity, internal resistance, range, charge loss, energy regenerated, etc.

Some options for calculating the energy used:

Integration (current x voltage) over time = 20.1 kWh/100km = Excact the same as triplog in the car
Integration current over time x average voltage = 20.6 kWh/100km
Integration current over time x nominal voltage (108x3.6) = 18.7kWh/100km
Average current x average voltage x time used = 20.6 kWh/100km
Average current x nominal voltage (108x3.6) x time used = 18.7kWh/100km

Battery pack is at 129mOhms which is very high at +10 degrees but I guess it is due to the high SOC.
I'm studying Python so I hope to be able in a shortwhile to be able to do the same calculations ;)

Which SOH are you using as reference ? min/max/avg ? I'm using for my energy calculation the min but I don't know if I'm too conservative.
MY20 Yulong White SE, 20", air suspension, privacy glass, black pack and other fine stuffs

dernotte
Posts: 313
Joined: Tue Dec 24, 2019 2:34 pm
Location: Montreal, QC, Canada

Re: Canbus and PID for the IPace

Post by dernotte » Tue Feb 23, 2021 1:34 am

Does anyone already looked at PID FD0A on BCCM. In my data in different context, the value is always "0FA0", but when plugged on a DC fast charger, the value seems to be close to the charger voltage*10. Do you have any data on your side for FD0A while you charge ?

Same question for FD50. It also changed right after the fast charge. The first 4 bytes of FD50 seems to be equal to DD00, which is the relative time for the car since built time, so this value is the timestamp of the last fast charge ? This value also changed when I unpluged the car with the timestamp of the unplug event.
Last edited by dernotte on Tue Feb 23, 2021 2:00 am, edited 3 times in total.

dernotte
Posts: 313
Joined: Tue Dec 24, 2019 2:34 pm
Location: Montreal, QC, Canada

Re: Canbus and PID for the IPace

Post by dernotte » Tue Feb 23, 2021 1:42 am

On BCCM, PID FD20 is a 5 byte numbers, but the first number changed when I did a DC fats charger. Could it be the number of fast charge since day 1 ?
After this fast charge session, FD20 is copied in FD21, FD21 -> FD22, FD22->FD23, FD23->FD24. It seems historical data to keep in the car (last 5) but the other byte are not very meaningful.

PID FD1A is a 4 byte number, strictly moving up, only change when when I fill the battery to 100% or stop charging. Cumulative Watt send to the battery since day 1 ?

User avatar
ANBO
Posts: 146
Joined: Fri Mar 27, 2020 7:50 pm
Location: Switzerland

Re: Canbus and PID for the IPace

Post by ANBO » Tue Feb 23, 2021 6:10 am

dernotte wrote:
Tue Feb 23, 2021 1:42 am
On BCCM, PID FD20 is a 5 byte numbers, but the first number changed when I did a DC fats charger. Could it be the number of fast charge since day 1 ?
After this fast charge session, FD20 is copied in FD21, FD21 -> FD22, FD22->FD23, FD23->FD24. It seems historical data to keep in the car (last 5) but the other byte are not very meaningful.

PID FD1A is a 4 byte number, strictly moving up, only change when when I fill the battery to 100% or stop charging. Cumulative Watt send to the battery since day 1 ?
🇨🇭 EV400 HSE (MY2020; MAR 2020); 18" ❄
⚙️ H264 ⚙️ ICM: S20C ⚙️ VCS: 19.2
⚙️ BECS: BP-AAE-BC-AC-BE ⚙️ Maps: 06.2020

User avatar
ANBO
Posts: 146
Joined: Fri Mar 27, 2020 7:50 pm
Location: Switzerland

Re: Canbus and PID for the IPace

Post by ANBO » Tue Feb 23, 2021 6:13 am

dernotte wrote:
Tue Feb 23, 2021 1:42 am
On BCCM, PID FD20 is a 5 byte numbers, but the first number changed when I did a DC fats charger. Could it be the number of fast charge since day 1 ?
After this fast charge session, FD20 is copied in FD21, FD21 -> FD22, FD22->FD23, FD23->FD24. It seems historical data to keep in the car (last 5) but the other byte are not very meaningful.

PID FD1A is a 4 byte number, strictly moving up, only change when when I fill the battery to 100% or stop charging. Cumulative Watt send to the battery since day 1 ?
Interesting. Could the copied values be to the trip log registers?
🇨🇭 EV400 HSE (MY2020; MAR 2020); 18" ❄
⚙️ H264 ⚙️ ICM: S20C ⚙️ VCS: 19.2
⚙️ BECS: BP-AAE-BC-AC-BE ⚙️ Maps: 06.2020

Maxwell_400
Posts: 395
Joined: Mon Oct 14, 2019 10:09 am
Location: Norway

Re: Canbus and PID for the IPace

Post by Maxwell_400 » Tue Feb 23, 2021 7:30 am

kermit68 wrote:
Mon Feb 22, 2021 11:56 am
Maxwell_400 wrote:
Mon Feb 22, 2021 11:48 am

Yes and when I integrate (current x voltage) I get 20kWh/100km which is exactly the same as reported by the triplog in the display. SOC delta was 23%, this gives a battery capacity of 86kWh which is very close to 90 x SOH = 85.5kWh. (By a coincidence the distance driven is 100km).

Then we have it, we can calculate a lot of interesting parameters, like battery capacity, internal resistance, range, charge loss, energy regenerated, etc.

Some options for calculating the energy used:

Integration (current x voltage) over time = 20.1 kWh/100km = Excact the same as triplog in the car
Integration current over time x average voltage = 20.6 kWh/100km
Integration current over time x nominal voltage (108x3.6) = 18.7kWh/100km
Average current x average voltage x time used = 20.6 kWh/100km
Average current x nominal voltage (108x3.6) x time used = 18.7kWh/100km

Battery pack is at 129mOhms which is very high at +10 degrees but I guess it is due to the high SOC.
I'm studying Python so I hope to be able in a shortwhile to be able to do the same calculations ;)

Which SOH are you using as reference ? min/max/avg ? I'm using for my energy calculation the min but I don't know if I'm too conservative.
I use SOH and SOC average.

I was not happy with the calculations of the internal resistance of the battery and found a more robust way to calculate it.

dU : derivate of voltage
dI : derivate of current
dt : derivate of time
R : internal resistance of battery pack

The internal reistance is found by R = -dU/dI but this is very noisy and not robust
An alternative is to look at the rms voltages where R = AC voltage/AC current but that was not accurate

So instead I did linear regression on R = -dU/dI = -(dU/dt) / (dI/dt)

Battery resistance at 10degC.png

The internal resistance is the slope and R = 63mOhms, a single cell is then on average 2.3 mOhms at 10 degrees

While I am at it, I can look at the recuperated energy:

Regenerated energy.png

This may be fun for those who live in mountainous regions. Total energy used was 20kWh, If I drive in the opposite direction I would not recuperate energy and the predicted energy usage would be 20 + 2 x 2.5 = 25kWh which is pretty accurate.
I-Pace SE++, MY20, 18" summer & winter, no panoroof, towbar, spare wheel, 20C, TCU 19.2, BECS: BP-AAE-BC-AC-BE

Post Reply