Battery: Volvo XC40 Polestar 2 - dalathegreat/Battery-Emulator GitHub Wiki

[!CAUTION] Working with high voltage is dangerous. Always follow local laws and regulations regarding high voltage work. If you are unsure about the rules in your country, consult a licensed electrician for more information.

Volvo XC40 / Polestar 2 battery wiki

Battery specifications / Serial numbers

The following batteries are supported:

  • 78kWh Volvo XC40 - Recharge, 2021-
  • 78kWh Polestar 2 - Long range, 2020-

bild

Wiring diagram, high voltage

Wiring diagram, low voltage

Connect HVIL2_EXT_IN and HVIL2_EXT_OUT together with a cable. (this will close the HVIL loop and make BECM a bit happier) The BECM has a built in 120ohm resistor. (BECM = Battery Energy Control Module)

Attached below are pictures of the BMS pinout. Connect the pins to the LilyGo and 12V supply like this:

  • Pin 42 to LilyGo CAN - H
  • Pin 43 to LilyGo CAN - L
  • Pin 24 & 33 to +12V
  • Pin 48 GND

bild bild

Part numbers

Incase your battery is missing some wires/disconnect switches, here are the OEM part numbers and purchase links. Do note that it might be cheaper to source from your local scrapyard!

Product Purchase Link
Service disconnect switch XXXXXX XXXXXX

How to compile the software for this battery type

Make sure that the settings in the USER_SETTINGS.h file are correct. The line:

#define VOLVO_SPA_BATTERY

Needs to be uncommented for the software to interface correctly with the battery.

Next step is then to select the inverter protocol that you intend to use. After setting this up, press compile and upload to the board!

This is early in the implement of this battery so contactor control must be performed with external relays/mosfets at the moment.

PWM controlled contactors

When using PWM control, the following parameters seem to work nicely with the Volvo contactors:

  • Frequency 40000, Hold Duty 690

image

image