-
Notifications
You must be signed in to change notification settings - Fork 9
Home
So you want to add CCS to your LEAF? You've come to the right place, this will be a detailed how-to for any DIYer. Please note that this project involves working on high voltage electronics, so get familiar with your local legislation so you know what safety training/certificates is needed before proceeding. It is also a smart idea to check if the vehicle will pass your country's vehicle inspection after getting this mod.
This is probably the most asked question. Building an adapter that converts a chademo station to CCS is quite simple, Tesla makes one even. But the other way around not so much. The biggest problems are these 3 points:
- Mechanical locking. For DC, you must have positive locking to prevent the connector being unplugged mid-charge. CHAdeMO has this in the plug, CCS has it in the car. Hence Tesla's adapter is easy in this respect - they already have a lock in the car, and the CHAdeMO plug provides a lock on the other side of the adapter, so the adapter doesn't need to do any locking. A CHAdeMO(car) to CCS(charger) adapter would need to provide two mechanical locks interlocked to the control protocol.
- Voltage sequencing. Things need to be organized so that when contactors close to connect the charger to the battery the voltage on both sides is the same to avoid a sudden surge of current (potentially welding the contactor and at least wearing it out) when it closes. CHAdeMO and CCS do this in a different order - IIRC, CHAdeMO makes the battery voltage appear on the connector first and the charger observes that before matching its output; CCS expects the charger to output a matching voltage before closing the vehicle contactor. Tesla's adapter has to provide a circuit to generate 400V within the adapter to get the charger to start up.
- Power for the adapter's internal electronics. CHAdeMO provides 12V power from the charger to the car with a useful amount of current - so an adapter can use that to power its internal electronics (and any solenoid locks etc.). An adapter in the other direction (CCS charger) has almost no power available on the connector until the protocol has advanced to the point that the battery voltage is available. Such an adapter would probably have to have its own internal battery (and then what do you do if it goes flat?).
So not that easy. If it were, some other company would already have made such an adatper. The adapter would basically need to house the entire BMW i3 LIM module, a portable lithium battery pack, voltage sensing circuit, extra contactors etc. Basically the adapter would be bulky, expensive and probably need to interface with the LEAF with an extra CAN cable that you pull into the OBD2 connector. It would be horrible to setup. So that is why we are going to build the CCS add-on directly to the car instead.
The entire build is based on the LIM from a BMW i3. This along with the rest of the BMW parts can be purchased from salvage yards to keep cost down. Other parts might be easiest to source new. If you spend some time finding deals, the entire project should be possible to complete under 700€. More detailed partlist found here: https://openinverter.org/wiki/BMW_I3_Fast_Charging_LIM_Module#LIM_peripherals
- BMW i3 LIM module (any year will do as long as it is LIM_AC_DCO)
- BMW i3 CCS Charge port (with lock actuator for)
- 2x BMW Fast charge contactors for CCS (TE EVC135 RELAY, SPST-NO, DM (# 2138011-1) )
- 2x Contactors to stop voltage going to chademo port (PN ?)
- Muxsan 3-port CAN-bridge (open source design, can be purchased from Muxsan, Dala, etc.)
- Xmega compatible flashing tool (Atmel AVRisp mkII OR Atmel-ICE)
- Isolated DC charge inlet voltage sense board (EVcreate https://www.evcreate.nl/shop/charging/voltage-sense-board-bmw-i3-lim/)
- RGB charge indication light (optional https://nl.aliexpress.com/item/4000437597282.html)
- We need a CAN log from Chademo V2X session. A standard charge session might work, but the V2X should be more reliable since it won't quit the charge if current demand is 0. Ideas?
- We need to fake a Chademo charge to get the contactors inside the battery to close, and also the contactors inside the power distribution module to close. After we have 400V all the way to the front of the car, we can try and get the CCS going.
- How to prevent Chademo connector from getting 400V while charging via CCS? Extra contactors most likely, NC variant?
- How to switch between CCS/Chademo mode? Automatically via CAN? Or a physical switch labelled Chademo/CCS that the user flips before charging? The latter will make it easier to wire everything up AND save power since we then don't need to power the BMW LIM module unnecessarily.
- The CAN-bridge needs to be connected to the LIM (Can #1), and also to the QC-CAN on the LEAF (CAN #2). We might also need to poll EV-CAN (CAN #3) in order to get more stats from the LEAF battery, since QC-CAN doesn't really supply much details. Luckily the 3-port CAN-bridge is perfect for this.
- The code from the open source LIM control needs to be ported to the 3-port CAN-bridge and also the LEAF specific bits added
Below are some example integration videos COMING SOON
This section contains info on how to contribute/compile the software from scratch for the 3-port CAN-bridge
The firmware is compiled with Atmel Studio 7. The older version from 2020 is recommended, since it is less bloated and works with more non-genuine flashing tools. "Atmel Studio v7.0.1931" can be downloaded from here: https://www.microchip.com/en-us/development-tools-tools-and-software/avr-and-sam-downloads-archive
Once the Atmel Studio 7 has been installed, you can clone/download the CAN-bridge software from this repository: https://github.com/dalathegreat/Nissan-LEAF-CCS/
Once on your machine, double click the "can-bridge-ccs.cproj" and it opens with Atmel Studio. Press F7 to build. This generates a .hex file in the build directory that can be flashed onto a CAN-bridge
All changes are made in the "can-bridge-ccs.c" file. Manipulations to messages happen after the **switch(frame.can_id){ ** line. Generated messages to be sent are handled in the ISR(TCC0_OVF_vect){ interrupt. Happy programming!
If you want to simply flash a pre-made .hex file, follow this video: https://youtu.be/eLcNSo2Vn6U?t=170 Please note that you don't need +12V to power the CAN-bridge, a standard 5V USB cable can also be used when flashing.
If you want to flash directly from Atmel Studio while making code changes, press CTRL+ALT+F5 to start a debugging session, that defaults to flashing the CAN-bridge