The ZombieVerter VCU Project

jon volk
Posts: 572
Joined: Wed Apr 10, 2019 7:47 pm
Location: Connecticut
Been thanked: 2 times

Re: The ZombieVerter VCU Project

Post by jon volk »

If I run a make get-deps it gets real mad about a missing nvic.h file. I just copied a libopencm3 folder from one of Johannes' projects Ive been messing with and all is well. Im not sure if others have this issue.
Formerly 92 E30 BMW Cabrio with Tesla power
User avatar
johu
Site Admin
Posts: 5791
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 157 times
Been thanked: 1025 times
Contact:

Re: The ZombieVerter VCU Project

Post by johu »

It doesn't quite have the structure of the inverter project yet, i.e. libopeninv and libopencm3 are not tied in as submodules
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
johu
Site Admin
Posts: 5791
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 157 times
Been thanked: 1025 times
Contact:

Re: The ZombieVerter VCU Project

Post by johu »

Took the liberty to recreate the project. If you want carry on with it.
https://github.com/jsphuebner/stm32-vcu
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Thanks Johannes. I have added a VAG module as a way of saying thanks:)
Attachments
2021-01-02 12.36.30.jpg
I'm going to need a hacksaw
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

OK, i can select GS450H now and i'm seeing HTM / REQ & CLK being generated. All 3 signals look good.

I'm not getting anything back from my inverter on the bench on the MTH line, so i'll need to investigate that a bit more. I have flipped REQ and CLK in the harness, so that should be ok. I'm going to scope the inverter connections and see if i can spot anything.

I'm thinking it would be a good idea to have a parameter for the status of the selected inverter, it would be an easy way to see if the inverter is "online" so to speak.
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Good idea! I'll do that asap.
I'm going to need a hacksaw
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Inverter status (InvStat) now on web interface. Only works on gs450h for now. Latest on the 'hub.
I'm going to need a hacksaw
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Any luck Dilbert?
I'm going to need a hacksaw
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

I spend hours figuring out that i'd flip'd the wrong pair(s) in the CAT5 cable, as the colors at each end of the cable didn't match due to the fact I had a coupler in the middle.

I'm now getting data in/out of the ECU from the inverter, which is good news. Now that i have comms, I can test tomorrow with the motor on the bench.

I won't be using the pre-charge, i'll just have a 24V PSU connecting to the inverter, is there any way to disable this? do i just set a low value for the pre-charge voltage?

I've calibrated my BMW pedal, but i'm not seeing the "potnom" parameter move, even when i give it a direction input. So i need to look at that, I think i haven't given the ECU the "start" input.
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Ok great. Just set udcsw to 0 to bypass precharge. It won't command torque unless in "run" mode. Easy way to enter run is just select bmw e46 vehicle and give a 12v pulse to the In1 pin then set direction to default forward and torque should increase linearly with throttle. All going well I'll test in the E65 tomorrow also.
I'm going to need a hacksaw
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

OK that's a good tip.

So in E46 mode, IN1 will bring it into run mode. Which pins are mapped for the direction inputs on the E46?
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Well the current hardware only has 2 12v digital inputs so I've mapped in1 to start and reverse and in2 to forward. so if you just hit in1 it will enter start mode then put direction mode into default forward and your good to go. to test reverse pull in2 to 12v and select direction switch and then switch reversed for the other direction. Bit of a kludge but will work for testing. Assuming it works out I'd like to have a look back at the gen 3 prius data with you to see if we can make that work.
I'm going to need a hacksaw
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

OK that brings the "din_start" to 1 and "dir" to 1.

I don't seem to be getting anything on "potnom" when i push the accelerator, have i the name of that parameter correct?
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

is opmode showing run?
I'm going to need a hacksaw
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

Jack Bauer wrote: Sun Jan 03, 2021 4:11 pm is opmode showing run?
seems to be stuck at 0
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

UDCSW had somehow got set back to 330. I'm now showing OPMODE of 1
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Ok should say "run" under opmode but 1=run. Should show potnom and torque now.
I'm going to need a hacksaw
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

Jack Bauer wrote: Sun Jan 03, 2021 5:06 pm Ok should say "run" under opmode but 1=run. Should show potnom and torque now.
See attached the guages and param export.
Attachments
params.json
(583 Bytes) Downloaded 88 times
gauges_3_1.PNG
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Ah yes you need to set udcmin to 0 also. Sorry forgot that one. Also you only need to pulse in1 high start is a momentary signal.
I'm going to need a hacksaw
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Well I donned the snowsuit and commenced E65 testing today. Removed a pile of Damien generated bugs and the car side can is now happy and convinced there is a 3.5l v8 and a 6 speed autobox in there idling away happy at 750rpm. Despite using a "start/stop" agm battery and a 15amp charger it didn't take long for the SuperYacht's thirst for 12v power to drop the voltage to a point that all kind of weird faults started turning up. So I jumped it to the Panzer and left the car "idling" so the Tesla dcdc was supplying power. Then brought up the GS450H systems. To my delight I got a InvStat ON message from the inverter but then weird things started when I fired up the gearbox oil pump and the jumpleads started smoking despite the cooling 0C airflow and rain hitting them. Finally time to connect the hv, set udscw, put my faith in Johannes and press the appropriately named "engine start" switch. Precharge kicked in, hit the threshold and main contactor closed, dcdc came up and all those little computers in the E65 got a steady 14.4v and all were happy.

Ok then lets see if the car moves. Calibrated the throttle, set a 20% max throttle, shifted into drive, pressed the pedal and....we get a rumbling from the gearbox and the car shakes back and forth a little but no movement. BUT that is waaayyyy more then I expected so generally happy. Now we just need to refine the serial comms to the inverter and we should be driving.

While I was there tested the oil pump speed setting : works. tested the high/low shift and feedbacks : works. We don't seem to get any feedback from the inverter like temps or rpms so need to get into the serial comms.

I think we're on the way here folks............. Dilbert, any luck with your bench tests?
I'm going to need a hacksaw
User avatar
mdrobnak
Posts: 692
Joined: Thu Mar 05, 2020 5:08 pm
Location: Colorado, United States
Has thanked: 1 time
Been thanked: 5 times

Re: The ZombieVerter VCU Project

Post by mdrobnak »

Nice work!

I'm coming back to my 330 engine/transmission control stuff while taking a short break from the charge port stuff. I'll try and get cppcheck setup so you can do something like `make lintcheck` or something hopefully this weekend. After that, maybe we can even get Travis-CI integrated with github to have that run any time someone posts a Pull Request.
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Uhh....Yeah! that's what I was thinking Matt:) (No idea what any of that means but must not look stupid in public).

dilbert is there a reason we are running at 500k baud? looks like the arduino version ran at 250k.
I'm going to need a hacksaw
User avatar
mdrobnak
Posts: 692
Joined: Thu Mar 05, 2020 5:08 pm
Location: Colorado, United States
Has thanked: 1 time
Been thanked: 5 times

Re: The ZombieVerter VCU Project

Post by mdrobnak »

Jack Bauer wrote: Tue Jan 05, 2021 4:15 pm Uhh....Yeah! that's what I was thinking Matt:) (No idea what any of that means but must not look stupid in public).

dilbert is there a reason we are running at 500k baud? looks like the arduino version ran at 250k.
:D

Basically... have something look over the code we write and ensure it doesn't do stupid things unintentionally, using static analysis. If we're gonna make this 'the thing' we should try and strive for high quality code. :)

Travis, or Travis-CI is for "Continuous Integration" - basically, on every Pull Request (someone wants to make a change), humans review the code change, and you can have automated checks run on every commit (hence the continuous piece)...so automatic runs of code analysis. There is Travis-CI integration for github that's completely free for open source projects. So that fits well here.

-Matt
Dilbert
Posts: 410
Joined: Mon Aug 12, 2019 7:21 pm
Location: Dublin, Ireland
Been thanked: 4 times

Re: The ZombieVerter VCU Project

Post by Dilbert »

Jack Bauer wrote: Tue Jan 05, 2021 4:15 pm Uhh....Yeah! that's what I was thinking Matt:) (No idea what any of that means but must not look stupid in public).

dilbert is there a reason we are running at 500k baud? looks like the arduino version ran at 250k.
On the atmel processors 250k baud, gives a 500khz clock.

Will review the code in the morning to see what I can spot. I'd imagine if the data isn't getting clocked out correctly, the inverter would detect a checksum error and ignore the packet. So it's strange you got inverter whine
User avatar
Jack Bauer
Posts: 3563
Joined: Wed Dec 12, 2018 5:24 pm
Location: Ireland
Has thanked: 1 time
Been thanked: 87 times
Contact:

Re: The ZombieVerter VCU Project

Post by Jack Bauer »

Not only that but it responded to a torque command from the throttle.
I'm going to need a hacksaw
Locked