Page 1 of 4

[DRIVING] BMW Touring + phev motor & inverter

Posted: Tue Jan 24, 2023 10:30 am
by FFMan
Now that i've got into the meat of the project thought i'd post up some progress.

Budget build was aiming for £2k but will end up being a bit more due to some optional extras and change of course.

Original plan was Prius inverter and gearbox, and i sourced those parts, but consensus on here seemed to be Prius motor alone would be under-powered. I wasn't sorry about that, as it is huge and weighs a ton. So helped along by bigpie opted for an Outlander phev rear motor.

I hooked this up to the prius inverter with V1c board on the bench and got it turning ok on 120v with some tweaking.

The car its to be installed in is a BMW e46 touring. Chosen for several reasons, my daily drive is a 325ci and i like the 3 series from that era, plus being RWD it's an easy convert. Currently aiming to keep the gearbox, if it will run in 4th for everything, i might delete it later, but figure options are good for now.

Outlander charger has been bench tested with granny charger. Have some pans to create a charge option that just uses solar excess as i can get every 1.5secs readout from solar inverter as to be power being produced. Rather not export it for nothing (G98 solar self install).

Adapter plate is made, just waiting for machine shop to make the coupler from the part supplied (splines from phev diff, and clutch centre from BMW).

Questions around engine management light, local friendly mot tester suggested removing the bulb/led from the dash as i've got 3 pages of fault codes related to the engine. I hear there are people who can flash the ecu to tell it to ignore faults, if anyone has done this, or got round the issues in other ways i'd like to hear about it.

Power steering pump (Zafira B) is rough installed and vac pump likewise. For vacuum reservoir i'm repurposing the aircon drying unit as it just has dessicant in it - pictures to follow.

Re: BMW Touring + prius + phev

Posted: Tue Jan 24, 2023 10:53 am
by Bigpie
Try looking at https://github.com/damienmaguire/Stm32- ... an_E39.cpp for the can messages, the same ones might work on the E46

Re: BMW Touring + prius + phev

Posted: Tue Jan 24, 2023 4:47 pm
by FFMan
Bigpie wrote: Tue Jan 24, 2023 10:53 am Try looking at https://github.com/damienmaguire/Stm32- ... an_E39.cpp for the can messages, the same ones might work on the E46
yeah - it's not so much the message format as how it works. I have a spare dash on the bench and via canbus i can control much of it. Problem is i need to keep the ecu for the ABS, and so long as it is there it spams the dash like every 50ms. So whilst i could turn the MIL light off, the ecu would keep turning it back on i suspect. The dash is also pretty easy to upset. It expects messages in a certain time frame (different it seems for different message ids) and if you don't confirm it reboots, it is a bit touchy but vital to operation as it forms the bridge between the canbus and the k-bus.

given all the engine codes are related to engine, i don't mind removing the bulb. it's not elegant but ensures the light stays off now and in the future.

i'd be interested to see how other conversions dealt with this, specifically on e46.

Re: BMW Touring + prius + phev

Posted: Tue Jan 24, 2023 4:50 pm
by FFMan
Couple of snaps showing power steering pump prototype and vac pump. I've been told the power steering is the noisiest part of the build, so i've mounted it as in-board as i can. There is a stout plastic cover to go round that corner.

The vac pump itself it mount under the headlight where the drying cannister used to be, and the cannister is relocated to beside the washer bottle. Just need to add a non-return valve and the wiring.

12v fuse box fits behind the PS pump on the firewall but not shown yet. Need to work out how to mount it without drilling any holes.

Re: BMW Touring + prius + phev

Posted: Tue Jan 24, 2023 6:29 pm
by Ev8
What functions does the original ecu still do that means it needs to be kept, can these also not be taken over by something else?

That is one hell of a chunk of aluminium you have there!

Re: BMW Touring + prius + phev

Posted: Wed Jan 25, 2023 9:06 am
by FFMan
Ev8 wrote: Tue Jan 24, 2023 6:29 pm What functions does the original ecu still do that means it needs to be kept, can these also not be taken over by something else?

That is one hell of a chunk of aluminium you have there!
yeah tell me - wasn't cheap but i do have a tendency to over-engineer with an aim of only doing it once

Re: BMW Touring + prius + phev

Posted: Fri Feb 17, 2023 6:11 pm
by FFMan
So the coupler has finally been done, not before i trial fitted the motor and gearbox, so think i'll take that out tomorrow, fit the coupler and run it up on the bench to check for balance etc.

The motor mount is mostly done, just need some lugs welding on and tidying up. Next stop, battery box, and the question - how much effort should i put into retaining the BMW cooling/heating pipes - might be useful later coupled to the ex-BMW pre-heater ?

Re: BMW Touring + prius + phev

Posted: Fri Feb 17, 2023 9:27 pm
by Bigpie
Getting there

Re: BMW Touring + prius + phev

Posted: Sat Feb 18, 2023 6:59 am
by Mhs
What batteries are you planning?
Following your build, I have similar setup planned (pruis gen3 inverter, Damien's v1c board and phev rear motor - all on the way) not sure yet about the batteries and charger.

Re: BMW Touring + prius + phev

Posted: Sat Feb 18, 2023 5:28 pm
by FFMan
Mhs wrote: Sat Feb 18, 2023 6:59 am What batteries are you planning?
Following your build, I have similar setup planned (pruis gen3 inverter, Damien's v1c board and phev rear motor - all on the way) not sure yet about the batteries and charger.
I'm using the phev charger and also phev cabin heater. Both documented on here and cheap enough, though the charger is limited to 3 or 4kw.

Decided today to keep the e46 throttle pedal rather than fit the prius one I had.

Batteries are currently one of 9kw BMW setup @ 360v. Will add another pack later which should boost range to 70miles which covers 90% of our journeys (kids to school, me to work etc).

Re: BMW Touring + prius + phev

Posted: Sat Feb 18, 2023 5:31 pm
by FFMan
Bigpie wrote: Fri Feb 17, 2023 9:27 pmGetting there
yep - today got the coupler installed, then test ran the motor & gearbox on the bench @ 120v, then installed it in the car.

Motor mount is just about done now, so next step battery tray. The BMW set fits neatly behind the radiator once i've made a tray.

Re: BMW Touring + prius + phev

Posted: Sat Feb 18, 2023 9:51 pm
by Bigpie
Awesome. Looking forward to more updates. Let me know if you need any help

Re: BMW Touring + prius + phev

Posted: Sun Feb 19, 2023 8:21 am
by FFMan
Bigpie wrote: Sat Feb 18, 2023 9:51 pm Awesome. Looking forward to more updates. Let me know if you need any help
thanks - working towards some test up/down the drive and round the village at Easter.

Re: BMW Touring + prius + phev

Posted: Sun Feb 19, 2023 9:16 am
by Mhs
How do you guys -while charging- switch on the auxiliary systems (for cooling the cahrger and batteries for example)? And ensuring that the inverter stays off?
Maybe someone can point me in the right direction?

Re: BMW Touring + prius + phev

Posted: Sun Feb 19, 2023 10:22 am
by Ev8
At the simplest level you can use 240v relays to switch on certain items when 240v is present, I’m sure there are more advanced solutions but I like simple

Re: BMW Touring + prius + phev

Posted: Sun Feb 19, 2023 10:34 am
by Bigpie
I use the inverter to control the contactors, if you make sure it's in neutral while charging it'll not allow drive anyway.

Re: BMW Touring + prius + phev

Posted: Fri Apr 07, 2023 6:24 am
by FFMan
Quick update here as some progress has been made.

I've got the 240v charging working and the dcdc bit sorted, and after some self induced issues have just got back to the point where i can spin the motor under pot control cleanly both ways. The charging cicruit is based on Teensy 4.1, which usefully has 3 can bus interfaces also (inverter, shunt & charger). Coupled serially to the Teensy is an ESP32 which has wifi capability and that receives a stream of data from the Teensy whilst charging which it drops into Influx (a time series database) for monitoring purposes. The ESP32 also transmit the data over LoRa to be received by a handheld unit repurposed from another project.

The Teensy has an sd card socket, so in drive mode, i'll get it to log pertinent data from the inverter to aid tuning and issue resolution.

So next few days will see the 12v & control wiring completed and hopefully some testing with wheels off the ground, and then maybe a trundle up & down the drive all being well.

Re: BMW Touring + prius + phev

Posted: Fri Apr 14, 2023 2:55 pm
by FFMan
Progress has been made - the car now moves under it's own power using f/w 5.24r. I've only driven it slowly round the back where it is parked.

It developed a nasty squeel noise during the first couple of moves. Feels like a coupler or alignment issue. It wasn't there at first but developed a few mins in. This weekend i'll investigate, suspect need to drop the gearbox, which hopefully i can still do without taking the inverter, charger and batteries out of the front. But it was designed to come apart so if needed not the end of the world. luckily i have a 2 post lift :-)

thanks as always to forum members who have helped me get this far

Re: BMW Touring + prius + phev

Posted: Sat Apr 15, 2023 12:54 pm
by FFMan
I pulled the gearbox this morning and discovered the source of the noise. The coupler was able to touch the gearbox shaft shroud (or is it shrowd) under load, and that was metal on metal, plus the shroud added a nice ring to the timbre. I've shortened the shroud as its redundant without the clutch apart from holding the oil seal in pace. Ironically if i just put up with the noise, the shroud would have worn down anyway and would have been ok, but hindsight is a wonderful thing.

took the opportunity to tune the motor some more with the gearbox off. With a syncof of 5268 i was able to turn the motor with a manualid of 60. Now i've reduced the syncof to 5000 i can get to 200amp and no movement at all . That feels like a good place to be or should i go higher ?

In run mode, spins up nicely on the gas pedal.

Re: BMW Touring + prius + phev

Posted: Mon Apr 17, 2023 8:09 pm
by FFMan
So since Saturday i got a known good parameter set for an identical setup to mine and compared to mine. Weirdly the polepairs and respolepairs on his were 4 & 4, and mine were 5 & 5, which somewhat baffled me as i thought these params were fundamental to good operation. Thanks to another forum member who explained it's the ratio between the two that is key, so i changed mine to 4 &4 at lunchtime and all still works the same. Apparently speed reporting is off if you have the wrong values.

The lunchtime run revealed a recurring issue of power steering leak, there's a lot of pressure in there and one of the solid to flexible pipe joins doesn't have a flare on it, so i need to rectify that.

My vac pump also won't stop, suggesting a leak somewhere, need to track that down, maybe try it without the reservoir as other members report there is enough capacity in the servo for 3 good brake depresses. I'll try that, though i kind of like the concept of a vacuum reservoir, the 'fuller' it is, the less it holds etc

i replaced one of the headlights, just to extinguish a few warning lights on the dash that currently looks like a xmas tree. The ABS is the most concerning, not sure what i did to break that, it reports loss of canbus to ECU/DME (in BMW terms) and lost connection to 3 wheel sensors. Need to get it back up on the lift, though that is blocked by my wife's volvo after an abortive timing belt change (don't ask).

So the next tasks are hook up the cooling loop which will look like this:-
image.png

Re: BMW Touring + prius + phev

Posted: Tue Apr 18, 2023 5:46 am
by Ev8
Looks like a sensible cooling loop mine follows this exact plan

Re: BMW Touring + prius + phev

Posted: Tue Apr 18, 2023 9:49 am
by bobby_come_lately
On the engine management light, mine sailed through MOT with that lit. Tester told me it was irrelevant. I also haven't solved the ABS/ASC light issue - if you gave a can capture of the messages being spammed to the dash, that would be very welcome.

Re: BMW Touring + prius + phev

Posted: Mon Apr 24, 2023 7:52 am
by FFMan
bobby_come_lately wrote: Tue Apr 18, 2023 9:49 am On the engine management light, mine sailed through MOT with that lit. Tester told me it was irrelevant. I also haven't solved the ABS/ASC light issue - if you gave a can capture of the messages being spammed to the dash, that would be very welcome.
did you manage to MOT it with ABS/ASC light on ?

My code reader reports it's got no contact with 3 wheel sensor and no CAN comms to DME (ECU). I think this could be tricky to solve, but I have a 325 as my daily so i cam hoping i can sense check the signals against that.

Re: BMW Touring + prius + phev

Posted: Mon Apr 24, 2023 7:57 am
by FFMan
So this weekend we largely spent removing all the batteries so i can get at the power steering pipes and isntall the cooling. Several attempts to make pipes from the rack to the electric pump have not ended well. The pressure is much high than expected, so today i'm taking my leaky made up hoses to the local hydraulics shop to get them properly made. On the plus side, power steering fluid seem to make a good rust inhibitor and its spread all over the underside :-)

But i did get to install all the cooling pipes whilst it was apart and test it for leaks - all good.

Now to reassemble it and run some road tests on a local private road. The reassembly is half done, i'm taking the opportunity to tidy some wiring, install a temp sensor on the cooling loop, install the shunt and install the BMW BMS loom the aim of getting that talking over CAN at some point.

Thank to Pete008 for more help with tuning, it now pulls away like a regular car.

Re: BMW Touring + prius + phev

Posted: Mon Apr 24, 2023 8:39 am
by Pete9008
Glad it's running better :)

Probably worth posting what you found as it might help someone else solve a similar problem in the future?