Outlander VCU - Rear inverter, Charger and BMS

Mitsubishi hybrid drive unit hacking
Post Reply
royhen99
Posts: 195
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 14 times
Been thanked: 94 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by royhen99 »

Teensy 3.2 don't seem to be available anywhere at the moment. I plan to use a 4.0.
From @Tom91 in the simpbms thread, "I am working on a Teensy 4.0 Version with two can buses. I do not know if anyone ported the code over yet beyond my own testing." There was no indication when it would be available.
User avatar
m1n1s
Posts: 3
Joined: Wed Aug 10, 2022 11:40 am

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by m1n1s »

Also looking for BMS using Teensy 4.1 or ESP32.
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

Bigpie and Rstevens81 have an ESP based bms project.

https://github.com/jamiejones85/ESP32-BMS
https://oshwlab.com/EV-Team/spaceballs

As for porting to the 4.1 I took a quick look first guess is:
All the watchdog and other hardware related functions will need re-writing.
The CAN library needs changing to flexCAN_T4
That's just to get it to compile, testing would be needed.

There could well be more.. Tom would be the best person ask.
tom91
Posts: 1272
Joined: Fri Mar 01, 2019 9:15 pm
Location: Bristol
Has thanked: 97 times
Been thanked: 201 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by tom91 »

aot93 wrote: Sat Aug 20, 2022 1:47 pm
As for porting to the 4.1 I took a quick look first guess is:
All the watchdog and other hardware related functions will need re-writing.
The CAN library needs changing to flexCAN_T4
That's just to get it to compile, testing would be needed.
The main thing to check is what if any:
  • pwm outputs
  • anlogue inputs
For the rest it ports as you say, I have done so myself going from SimpBMS based on Teensy 3.2 to Teensy 4.0 for the new products I am working on.
Founder Volt Influx https://www.voltinflux.com/
Drivelafrance
Posts: 5
Joined: Sat May 28, 2022 8:04 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by Drivelafrance »

Hi all,

Thanks for the advice. ESP 32 would be my preference I suppose given their price, availability and, if I remember correctly, I think the teensy 4.1 can be somewhat fragile?

Cheers
User avatar
elShankos
Posts: 43
Joined: Thu Jun 30, 2022 9:17 am
Location: Cape Town
Has thanked: 25 times
Been thanked: 5 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by elShankos »

royhen99 wrote: Sat Aug 20, 2022 9:54 am Teensy 3.2 don't seem to be available anywhere at the moment. I plan to use a 4.0.
From @Tom91 in the simpbms thread, "I am working on a Teensy 4.0 Version with two can buses. I do not know if anyone ported the code over yet beyond my own testing." There was no indication when it would be available.
Hi there, I have been hunting for a SimpBMS but there don't seem to be any available from the online suppliers. I managed to get a few Teensy 3.2s from eBay - does anyone know if there is anyone selling the SimpBMS base board (without the Teeny 3.2) perhaps?
Turbopete
Posts: 75
Joined: Mon Aug 30, 2021 8:42 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by Turbopete »

On the dash controller - what’s the need for connecting to the tiny 3v3 pad under the teensy? Does this just boost the strength of the 3v3 signal?
royhen99
Posts: 195
Joined: Sun Feb 20, 2022 4:23 am
Location: N. Wiltshire. UK
Has thanked: 14 times
Been thanked: 94 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by royhen99 »

From looking at the schematic and pcb layout I don't think it needs to be connected. It's an internal connection on the Teensy board and should really have a different net name, so that it does not get connected on the main pcb.
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

There should be no requirement to connect to any of the underside pins.

Unless you are looking at the VBatt which is used for the clock.
image.png
arber333
Posts: 3241
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 74 times
Been thanked: 223 times
Contact:

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by arber333 »

@aot93 Do you by any chance use any BMS trigger for battery protection in your code? I would like to use a limit torque command within lower SOC range. say from 20% to 15% SOC. Signal from BMS should take care of the first trigger for when car would go into turttle mode.
However I am not sure how to signal the second boundry when car should fully stop. Should this be time conditioned? Say you have 5min to go somewhere then no more torque, car is OFF!
Or would it be better to set hard boundries like 3.2V for turttle mode and 3.0V for empty from BMS CAN reports? That way when you reach bottom your car stays immobile unless you charge the battery.
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

So I experienced hard stop first hand the other day, I actually managed to run the battery to the lower limit, the outlander cells drop really quickly after about 3.7v

In my setup the BMS main contactor out is wired to a relay on the RSDN of the inverter, so it will shut down the drive system if any limit condition is met as per Tom's design.

On the VCU side i have a fairly crude de rating system based on the BMS rated discharge current and actual current received over CAN.
It works ok for me but I would like to look at a better / more comprehensive stratergy.

Code: Select all

    if (BMS_discurrent < currentact) // Decrese tourque if we are over current - Crude needs work..
    {
      torqueRequest -= 20;
      if (timer1000_1.check() == 1)
      {
      Serial.println("--!OVER CURRENT!--");
      }
      if (torqueRequest < 0)
      {
        torqueRequest = 0;
      }
    }
arber333
Posts: 3241
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 74 times
Been thanked: 223 times
Contact:

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by arber333 »

aot93 wrote: Sat Oct 29, 2022 9:15 am So I experienced hard stop first hand the other day, I actually managed to run the battery to the lower limit, the outlander cells drop really quickly after about 3.7v

In my setup the BMS main contactor out is wired to a relay on the RSDN of the inverter, so it will shut down the drive system if any limit condition is met as per Tom's design.

On the VCU side i have a fairly crude de rating system based on the BMS rated discharge current and actual current received over CAN.
It works ok for me but I would like to look at a better / more comprehensive stratergy.
I see what you mean. You derate regen to 0 i see.
But i will use RSDN only for those really dangerous moments as battery overheating or confirmed UV event.
DC contactor needs to stay closed for the event though. Very important as with field weakening at higher rpm you can break the inverter if your DC contactor opens!
For normal derating i would like to use a simple limit similar to what you use. Thanks.
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

Yes that's exactly how this works, BMS can only control RSDN directly not the contactors. We really don't want to open them under load!
DennisM
Posts: 10
Joined: Tue Oct 18, 2022 2:33 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by DennisM »

Hi,

Very interesting Project. I ordered the PCB's allready :)
I read trough the .cpp file but i cannot find if there is a way to limit the current or torque by a parameter/setting or is this done by the throttle maps?
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

It's all done through the throttle maps - this is the best way i've found to tune the motor response. plus you get speed relative regen.
DennisM
Posts: 10
Joined: Tue Oct 18, 2022 2:33 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by DennisM »

Ok, thanks. Can you explain me how to read the throttle map. i don't understand how to read it.
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

It works a bit like an ignition advance map on a petrol car.

It's a 2d array where a value is returned based on the throttle position (x axis) and speed of the motor (y axis)

This is used as an offset multiplier to the pedal position to give the torque request (before any ramping is applied) a higher number means more torque a negative is regen.

Here is a spreadsheet I use to build the tables, it might help.
Throttle MAp 1.xlsx
(31.16 KiB) Downloaded 72 times
Turbopete
Posts: 75
Joined: Mon Aug 30, 2021 8:42 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by Turbopete »

I’ve been playing with the dash control pcb and code to give us something more in keeping with the original Mini Speedo - @Tom91 helped with the code changes to suit his VCU but the PCB is still as @aot93 designed. I’m on my 3rd set of prototypes to mount the displays and stepper motor and it’s nearly there I think!
937A8066-5B9B-4A57-9062-2E868BB92AAF.jpeg
91B4236E-EC0A-416A-AE97-8F540673D843.jpeg
D7A043CF-82ED-4838-B571-1E984D539CF6.jpeg
39FD9FC0-872C-4A02-B7F1-1CB90301E8AC.jpeg
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

Nice, I think those little oleds look really good in the original instrument.

A tip if you get erratic needle behaviour is to edit the acceleration tables in SwitecX25.cpp the following values worked for me:

Code: Select all

static unsigned short defaultAccelTable[][2] = {
  {   20, 3500},
  {   50, 2000},
  {  100, 1500},
  {  150,  1000},
  {  300,  800}
};
DennisM
Posts: 10
Joined: Tue Oct 18, 2022 2:33 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by DennisM »

For my company I do a lot of bussines in China and also with the company Heltec. I own a ebike battery refurbish company.

They have a bms that can be used as single unit or modular from 8s to 240s and can also communicate with CANbus. If I can get the CAN communication file do you think you can implement it in the VCU? So it can control the bms, read temps, cell voltage etc.
User avatar
aot93
Posts: 198
Joined: Mon Feb 15, 2021 5:45 pm
Location: UK, West Sussex
Has thanked: 6 times
Been thanked: 43 times

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by aot93 »

With full documentation it is should be possible within the limits of either system.
DennisM
Posts: 10
Joined: Tue Oct 18, 2022 2:33 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by DennisM »

ok, i will ask tomorrow if they will send me the CAN communication datasheet, and post it so you can check if it is possible
arber333
Posts: 3241
Joined: Mon Dec 24, 2018 1:37 pm
Location: Slovenia
Has thanked: 74 times
Been thanked: 223 times
Contact:

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by arber333 »

DennisM wrote: Tue Nov 08, 2022 5:53 pm ok, i will ask tomorrow if they will send me the CAN communication datasheet, and post it so you can check if it is possible
Can you post some datasheet for that BMS as well. I am also working on VCU master with esp32 chip. Could be usefull.
DennisM
Posts: 10
Joined: Tue Oct 18, 2022 2:33 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by DennisM »

arber333 wrote: Tue Nov 08, 2022 5:56 pm Can you post some datasheet for that BMS as well. I am also working on VCU master with esp32 chip. Could be usefull.
Yes, will ask for that too
DennisM
Posts: 10
Joined: Tue Oct 18, 2022 2:33 pm

Re: Outlander VCU - Rear inverter, Charger and BMS

Post by DennisM »

Hi,

Here is BMS CanBus datasheet

https://drive.google.com/file/d/1Gm6V8W ... sp=sharing

Spec sheet:

https://drive.google.com/file/d/1GmRgQk ... sp=sharing

although i think the price is not competitive enough with a proven system like the Orion.

The price of the product is $1406, excluding the collection line, freight and tax.
A set of products is a BMS master control module,2 slave machines, 1 800mm Harness,1 BMS-DCDC-24V,1 HALL-600A,1 Pre-charging resistance,1 anti-reverse diode and 3 Relay.
Post Reply