Page 35 of 37

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 02, 2022 8:51 pm
by Isaac96
hugow93 wrote: Wed Mar 02, 2022 7:42 pm I wasn't getting any change in voltage between GND and either channel.
The voltage was just 3.57v across 5V and GND, so I reckoned that was a bit low.
That's mildly concerning. 5V should really measure 5V.

These encoders are open-collector type, meaning they connect to ground when the channel is 'active' and leave it floating otherwise; this is why you need those pullup resistors. So the encoder itself never applies power to anything, only ground.

So you can feed it 12v (from board power supply?) as long as the grounds are connected.

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 02, 2022 9:54 pm
by hugow93
Isaac96 wrote: Wed Mar 02, 2022 8:51 pm
hugow93 wrote: Wed Mar 02, 2022 7:42 pm I wasn't getting any change in voltage between GND and either channel.
The voltage was just 3.57v across 5V and GND, so I reckoned that was a bit low.
That's mildly concerning. 5V should really measure 5V.

These encoders are open-collector type, meaning they connect to ground when the channel is 'active' and leave it floating otherwise; this is why you need those pullup resistors. So the encoder itself never applies power to anything, only ground.

So you can feed it 12v (from board power supply?) as long as the grounds are connected.
Thanks Isaac!

So it's safe to connect the line going in to Pin 20 (12v high) to the power up pin for the encoder, and still use Pin 2 as encoder GND? So effectively just swap from the 5v to the 12v for the inverter power?

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 02, 2022 11:54 pm
by Isaac96
In my experience with the Siemens 1PV5135, a 12v supply to the encoder was safe for the OpenInverter board. (With a couple small filter capacitors just for extra smoothing).

Yup, same ground.

Re: Prius Gen2 adapter board development thread

Posted: Sat Mar 05, 2022 11:10 pm
by hugow93
Isaac96 wrote: Wed Mar 02, 2022 11:54 pm In my experience with the Siemens 1PV5135, a 12v supply to the encoder was safe for the OpenInverter board. (With a couple small filter capacitors just for extra smoothing).

Yup, same ground.
Thanks Isaac. Unfortunately still stumped. By using the +5v and the primary ground on the board (same as 12v gnd), I get 5.4v on the encoder. This is the same voltage value it shows when I test across channel A or B and GND, but NO CHANGE in voltage is then observed when I rotate the shaft of the motor by hand. I resoldered the jumpers and rewired the connecror to be sure, and I'm starting to wonder if i have a problem with the encoder on the motor, and if I should open that to test.

Sorry for spamming this channel, folks. Not sure if this is a control board issue after all, but if there is anybody who has successfully used an encoder with this prius board I'd be grateful if you had a moment!

Re: Prius Gen2 adapter board development thread

Posted: Sat Mar 05, 2022 11:31 pm
by arber333
hugow93 wrote: Sat Mar 05, 2022 11:10 pm
Thanks Isaac. Unfortunately still stumped.
Hm... The way you presented schematic in post 39 you are connecting to GND by pin5 of the encoder. Could you just connect pin5 directly to the same GND that supplies the mainboard and 12V to pin4? Keep A and B signals free. Then get a scope and observe what happens with signal A when you turn the shaft. If you would get some voltage signal your outputs are push pull, but if you would get almost no change your outputs are open collector type. You should attach a LED (and 1k resistor) to 12V and channel A and rotate the shaft. Blinking LED or square signal on scope would confirm the channel is good. Otherwise i suggest surgery...

Re: Prius Gen2 adapter board development thread

Posted: Mon Mar 07, 2022 3:04 pm
by hugow93
arber333 wrote: Sat Mar 05, 2022 11:31 pm
Thanks Arber, another great flashing light test!

It's an open collector output, and when I connected the resistor and LED across 12v and channel A it worked just as you described.
LED blinks as shaft rotated.

Repeating the same test for channel B yielded no result, however. So I think there is something wrong with the encoder B channel.
What I did try was swapping the encoder mode on the VCU interface to SINGLE instead of AB.
This finally allowed me to graph an output as I rotated the shaft.
The square wave was a bit noisy, but I think it should be possible to test motor on bench with it.

Next I'll try to find any possible circuit faults that are causing B channel not to work, and I'll see if it could be possible just to use encoder as single channel if no easy fix available.

Thanks again Arber and Isaac for the help!

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 16, 2022 4:12 pm
by Richerson
Hi all, Just going through initial set up of gen 2 board. i'm going through tutorial video, My knowledge is basic so please bear with me.-

I have connected 12v and have led's lit one flashing
I am logged on to wi-fi interface
I have connected about 100v to DC input- light flashes once, as it should showing caps charged.
i'm now trying to spin motor for the first time and does nothing (using fslipnt and ampnom), i have a list of error messages:

(18515): STOP - DESAT
(8): WARN - HICUROFS2
(8): DERATE- TMPHMAX In spot values 103.28oC
(500): STOP- PRECHARGE

Lasterr PRECHARGE

status UdcBelowUdcSw ins spot values udc is 2.59v There is 97v on the DC Bus.

udc min is set to 50v

Any help much appreciated.

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 16, 2022 6:04 pm
by johu
As always: 12V power supply of power stage not connected. It's the extra 2-pole connector next to the logic connector

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 16, 2022 6:31 pm
by Richerson
thx for the reply, it is connected ,just to make sure i removed the original connector and changed it for a few bullets. Same results.
The only thing that's slightly different from the video, is the 12v bulb in line with the battery does not light up when inverter is powered on, there is some slight inverter noise though.

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 16, 2022 7:06 pm
by johu
ok, then it's either blown or not powered sufficiently (takes about 1A). It is not reporting anything, thus udc, temp, current, and desat errors

Re: Prius Gen2 adapter board development thread

Posted: Wed Mar 16, 2022 8:15 pm
by Richerson
ok its powered from a well charged Battery, so probably blown..
Thx for the help.

Re: Prius Gen2 adapter board development thread

Posted: Thu Mar 17, 2022 1:19 pm
by Richerson
Just checked it pulls 1.2amps on the main inverter power connector. I have ordered another inverter anyway just to see if results are different.

Re: Prius Gen2 adapter board development thread

Posted: Tue Mar 29, 2022 8:40 am
by Richerson
Just tried a second inverter, same results..

Before i dismantle all my wiring and start again, does the lead coming from the interlock terminal need to be connected to anything?

Cheers

Rich

Re: Prius Gen2 adapter board development thread

Posted: Tue Mar 29, 2022 4:35 pm
by johu
Ok, that makes an inverter issue unlikely. You don't need to use that interlock terminal, it is basically just a switched GND.
Have you connected the ground pins, i.e. pin 16 and 32 of the 32-pin connector?

Re: Prius Gen2 adapter board development thread

Posted: Tue Mar 29, 2022 7:07 pm
by Richerson
thx for the reply, yes all the grounds connected. Both inverters draw about 1.1 amps. I think next step is to check inverter 32pin block, I found it difficult to insert some of the pins.

Re: Prius Gen2 adapter board development thread

Posted: Mon May 23, 2022 8:34 pm
by RetroZero
I have pulled my latest parameters from my board hopefully to help get people up and running (however it does mean jumping some steps which I found I needed to understand), so please use with caution.
I have stock standard Gen2 setup with its original wires connected.
I have (had) a smooth running setup(before I undid half my wiring to get the charger side sorted), with I think 20Kw power, as I am not bypassing the HV converter at this stage. But it runs smooth in forward and reverse..

Re: Prius Gen2 adapter board development thread

Posted: Sat Jun 11, 2022 9:28 am
by MattsAwesomeStuff
Just FYI for everyone following along on this project too...

I shredded and rebuilt the Prius Gen 2 wiki page over the last couple days. I deprecated the former main page that you might've been linking to, and split it into 3 pages. One about the inverter, one about Damien's old throughhole board, and one about the project being developed in this thread here.

https://openinverter.org/wiki/Toyota_Prius_Gen2_Board -- Old page, probably don't link this anymore.

https://openinverter.org/wiki/Toyota_Pr ... 2_Inverter -- New page specifically about inverter and its pinouts, complete with 7 new pictures I added showing detailed pinouts and cable bundles (anyone buying Johannes' cheaper kit without the enclosure and connectors, who's reusing their wiring harness, should save some time). It links to both projects.

https://openinverter.org/wiki/Toyota_Pr ... Controller -- The page for the project in this thread here. It could use a lot of fleshing out and tidying up, but I don't have one, so, that'll be up to the community here to contribute. Especially all the problems/solutions/clarifications you guys do, so they're usefully archived.

https://openinverter.org/wiki/Toyota_Pr ... hole_Board -- And Damien's old Blue Pill board that no one other than me is attempting to get working, so people stop getting it confused with Johannes' project. It describes the history and why it's a deprecated project.

Feel free to browse any of it and make corrections if I'm wrong. I didn't modify content much, mostly just hacked at it with a machete and stapled the pieces to a barn door.

Re: Prius Gen2 adapter board development thread

Posted: Sat Jun 11, 2022 11:05 am
by mjc506
Good work!

Re: Prius Gen2 adapter board development thread

Posted: Sat Jun 11, 2022 4:10 pm
by johu
Long due work, thanks Matt :)

Re: Prius Gen2 adapter board development thread

Posted: Sat Jun 11, 2022 5:41 pm
by ZooKeeper
NICE WORK Matt!

Re: Prius Gen2 adapter board development thread

Posted: Mon Jun 20, 2022 6:11 pm
by Ev8
So as there is no auxiliary pwm provision on the gen2 board without soldering directly to a stm pin… not something I fancy trying, how simple would it be to make the software able to change the assigned use of pin 31 on the board, might it be an option to add the ability to add a drop down to give the choice of using this vcu pin for auxiliary pwm instead of charging functions? I’d do it myself if I could but arduino ide is the limit of my coding/complieing skills.

Basically as I’m running 2 gen2 vcu’s (twin motor) I would love to make use of auxiliary pwm to be able switch a relay on and off so my auxiliary oil pump only runs when the motor is, obviously I could do this in other ways just nice to use a feature that’s all ready in the software

Re: Prius Gen2 adapter board development thread

Posted: Tue Jun 21, 2022 10:14 am
by RetroZero
Sounds like a good plan. So if I understand, you could run a water pump whilst charging from additional pwm signal?

Thanks Matt for the wiki updates. I will get in there to help add more info, but it's looking much better with it being split into 2 board types. 👌

Re: Prius Gen2 adapter board development thread

Posted: Tue Jun 21, 2022 1:20 pm
by Ev8
I was thinking more along the lines of being able to switch what pwm pin31 is linked to so it could be used for charging or for auxiliary pwm, you wouldn’t be able to use both, by switching output pin assignments on the stm I presume, I only have experience with arduino and teensys and cannot compile for stm

Re: Prius Gen2 adapter board development thread

Posted: Wed Jun 29, 2022 11:21 am
by mfox
I have this motor and I would like to run it with gen 2 inverter. It is induction motor with 4 wires (red black blue white )for hall sensor and 2 white wires , i think for temp sensor .
I watched whole video how to set it up with MG2 (gen2-3), and those have 6 wires for hall..
I didn't want to open new thread to ask this question, I hope it is proper question to put into this thread to get answer for comunity as well .
And what do you think about this motor ?? I think is not bad at all...
It will be difficoult to run it with gen2 inverter?


Image

Image

Image

Image

Re: Prius Gen2 adapter board development thread

Posted: Thu Jul 07, 2022 7:22 am
by RetroZero
@mfox, Damiens and Johu's video for FOC tuning runs through the different ways of finding resolver options.