I believe this is exactly what happened when I (watched Damien's videos with blown capacitors) set a 130 deadtime. Inverter started to behave strange and become sluggish.
Prius Gen2 adapter board development thread
- konstantin8818
- Posts: 290
- Joined: Sun Jan 19, 2020 2:33 pm
- Location: Minsk, Belarus
- Has thanked: 2 times
- Been thanked: 8 times
Re: Prius Gen2 adapter board development thread
- SciroccoEV
- Posts: 370
- Joined: Thu Oct 10, 2019 1:50 pm
- Location: Luton UK
- Been thanked: 15 times
Re: Prius Gen2 adapter board development thread
To try and make this clear for the hard of thinking.
Three PWM lines control ALL SIX transistors.
The transistors are driven as complimentary pairs, so the dead time control can only be done internally in the intelligent power module.
Three PWM lines control ALL SIX transistors.
The transistors are driven as complimentary pairs, so the dead time control can only be done internally in the intelligent power module.
-
- Posts: 3554
- Joined: Mon Dec 24, 2018 1:37 pm
- Location: Slovenia
- Has thanked: 131 times
- Been thanked: 330 times
- Contact:
Re: Prius Gen2 adapter board development thread
Ah so it is IPM with internal drivers. Our 1 2 3 pwm channels only provide signal 1 or 0 to each pair for MG1. Then 4 5 6 are floating? Couldnt we use them to drive MG2 in parallel? Back to mad scientist with me...SciroccoEV wrote: ↑Thu Jul 16, 2020 8:43 pm To try and make this clear for the hard of thinking.
Three PWM lines control ALL SIX transistors.
The transistors are driven as complimentary pairs, so the dead time control can only be done internally in the intelligent power module.
Re: Prius Gen2 adapter board development thread
greetings everyone,
Ive a question about resolver connections.
I believe these are the colors and signals for the gen2 prius MG1 resolver( and if anybody has MG2 connections I can easily find the colors by the attached photo)
black GRF = exc a
white grfg=gnd
red GSN=ENC A
green GSNG= SIN a
Yellow GCs= ENC B
Brown Gcsg= cos a
and I believe the pin mapping JOHU provided shows
pin1 is ENC_B would be yellow
Pin2 is S1S4 would be ??
pin3 is ENC_A would be red
Pin4 is R1 ( exit a?) would be black
Pin 5 is Resolver 2 would be ??
so 6 wires and 5 connection points
my question is this , where does cos A belong and where does Sin A belong?
Ive a question about resolver connections.
I believe these are the colors and signals for the gen2 prius MG1 resolver( and if anybody has MG2 connections I can easily find the colors by the attached photo)
black GRF = exc a
white grfg=gnd
red GSN=ENC A
green GSNG= SIN a
Yellow GCs= ENC B
Brown Gcsg= cos a
and I believe the pin mapping JOHU provided shows
pin1 is ENC_B would be yellow
Pin2 is S1S4 would be ??
pin3 is ENC_A would be red
Pin4 is R1 ( exit a?) would be black
Pin 5 is Resolver 2 would be ??
so 6 wires and 5 connection points
my question is this , where does cos A belong and where does Sin A belong?
the priustoric boatcar guy
-
- Posts: 861
- Joined: Tue Oct 29, 2019 2:48 pm
- Location: France
- Has thanked: 514 times
- Been thanked: 49 times
- Contact:
Re: Prius Gen2 adapter board development thread
I found some info whilst trolling threads. Will start documenting this stuff soon.
AFIK, looking at the back of the connector to both MG1 and Mg2,
PIN 1 - MRF = PIN 6 - EXITATION (adapter board)
PIN 2 - MSN = PIN 3 - ENC A
PIN 3 - MCS = PIN 1 - ENC B
PIN 4 - MRFG = PIN 2 - S1/S4 GROUND
PIN 5 - MSNG = PIN 4 - R1
PIN 6 - MCSG = PIN 5 - R2
Hope that helps, and hope I got it right.
Edit, looking at your diagram, this is for MG1 only
Edit, looking closer at where I found this info, it's from an RX400H....
AFIK, looking at the back of the connector to both MG1 and Mg2,
PIN 1 - MRF = PIN 6 - EXITATION (adapter board)
PIN 2 - MSN = PIN 3 - ENC A
PIN 3 - MCS = PIN 1 - ENC B
PIN 4 - MRFG = PIN 2 - S1/S4 GROUND
PIN 5 - MSNG = PIN 4 - R1
PIN 6 - MCSG = PIN 5 - R2
Hope that helps, and hope I got it right.
Edit, looking at your diagram, this is for MG1 only
Edit, looking closer at where I found this info, it's from an RX400H....
-
- Posts: 861
- Joined: Tue Oct 29, 2019 2:48 pm
- Location: France
- Has thanked: 514 times
- Been thanked: 49 times
- Contact:
Re: Prius Gen2 adapter board development thread
Throttle pedal from gen 2 prius:
Pin 1 - VCP2 = PIN 6 - 5V
PIN 2 - EP2 = PIN19 - GRND
PIN 3 - VPA2 = PIN 8 THROTTLE 2
PIN 4 - VCPA = PIN 6 - 5V
PIN 5 - EPA = PIN PIN 19 - GRND
PIN 6 - VPA = PIN 7 - THROTTLE 1
Again, good if someone with experience with this could validate.
Edit : once info is verified by a few people working on similar builds, I'm happy to post to the wiki. Is it possible to create one on the new formated welcome page, or a spin off from Damiens original?
Pin 1 - VCP2 = PIN 6 - 5V
PIN 2 - EP2 = PIN19 - GRND
PIN 3 - VPA2 = PIN 8 THROTTLE 2
PIN 4 - VCPA = PIN 6 - 5V
PIN 5 - EPA = PIN PIN 19 - GRND
PIN 6 - VPA = PIN 7 - THROTTLE 1
Again, good if someone with experience with this could validate.
Edit : once info is verified by a few people working on similar builds, I'm happy to post to the wiki. Is it possible to create one on the new formated welcome page, or a spin off from Damiens original?
- johu
- Site Admin
- Posts: 6619
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 343 times
- Been thanked: 1485 times
- Contact:
Re: Prius Gen2 adapter board development thread
GRF -> R1 (Pin 4)imwoody36 wrote: ↑Thu Jul 16, 2020 10:13 pm black GRF = exc a
white grfg=gnd
red GSN=ENC A
green GSNG= SIN a
Yellow GCs= ENC B
Brown Gcsg= cos a
and I believe the pin mapping JOHU provided shows
pin1 is ENC_B would be yellow
Pin2 is S1S4 would be ??
pin3 is ENC_A would be red
Pin4 is R1 ( exit a?) would be black
Pin 5 is Resolver 2 would be ??
so 6 wires and 5 connection points
my question is this , where does cos A belong and where does Sin A belong?
GRFG -> R2 (Pin 5)
GSNG and GCSG -> S1S4 (Pin 2)
GSN -> S2 (Pin 3)
GCS -> S3 (Pin 1)
Maybe I'm mistaken about the last two but thats what the pinswap parameter is for (if not moving, set to 2)
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
-
- Posts: 861
- Joined: Tue Oct 29, 2019 2:48 pm
- Location: France
- Has thanked: 514 times
- Been thanked: 49 times
- Contact:
Re: Prius Gen2 adapter board development thread
Thanks Johu. 2 out of 6 for me. I'll go hide in a corner now.
I wonder how screwed up my throttle is now
I wonder how screwed up my throttle is now
-
- Posts: 3554
- Joined: Mon Dec 24, 2018 1:37 pm
- Location: Slovenia
- Has thanked: 131 times
- Been thanked: 330 times
- Contact:
Re: Prius Gen2 adapter board development thread
See here the pin positions: viewtopic.php?f=9&t=335#p3772RetroZero wrote: ↑Fri Jul 17, 2020 5:47 am Throttle pedal from gen 2 prius:
Pin 1 - VCP2 = PIN 6 - 5V
PIN 2 - EP2 = PIN19 - GRND
PIN 3 - VPA2 = PIN 8 THROTTLE 2
PIN 4 - VCPA = PIN 6 - 5V
PIN 5 - EPA = PIN PIN 19 - GRND
PIN 6 - VPA = PIN 7 - THROTTLE 1
Again, good if someone with experience with this could validate.
You probably have the 2gen pedal with wider pins. I used one in mazda https://mazdamx3ev.wordpress.com/2016/02/12/pedal/
Pin 1 is the lowest pin on connector when pedal is installed.
Re: Prius Gen2 adapter board development thread
Update...
I was having troubles maintaining a WiFi connection to the HICU, found three things: 1) Low supply voltage (<11.5vdc) seems to cause lost signal, 2) with multiple WiFi signals, the computer kept switching between them (I "forgot" all the others, which helped) and 3) Having a dedicated device WiFi (iPad in my case) made life much simpler.
Also used the 5v ref for the Gen2 Prius pedal, but to keep POTMAX <5000, I had to use a 200 ohm resistor on the 5v supply. Obviously that is not the best option because additional 5V loads will change the circuit voltage. When I get the MGR spinning smoothly and am ready to really validate every circuit, I will move the resistor to the signal side.
I used the "AUTO" + Refresh option to watch "POT" in the Spot_Values area and found idle = 777 & WOT = 4011 with very good consistency. So I set POTMIN = 780 and POTMAX = 3975. This should ensure the dead pedal = idle and fully depressed is 100% throttle.
I was having troubles maintaining a WiFi connection to the HICU, found three things: 1) Low supply voltage (<11.5vdc) seems to cause lost signal, 2) with multiple WiFi signals, the computer kept switching between them (I "forgot" all the others, which helped) and 3) Having a dedicated device WiFi (iPad in my case) made life much simpler.
Also used the 5v ref for the Gen2 Prius pedal, but to keep POTMAX <5000, I had to use a 200 ohm resistor on the 5v supply. Obviously that is not the best option because additional 5V loads will change the circuit voltage. When I get the MGR spinning smoothly and am ready to really validate every circuit, I will move the resistor to the signal side.
I used the "AUTO" + Refresh option to watch "POT" in the Spot_Values area and found idle = 777 & WOT = 4011 with very good consistency. So I set POTMIN = 780 and POTMAX = 3975. This should ensure the dead pedal = idle and fully depressed is 100% throttle.
- TheSilverBuick
- Posts: 187
- Joined: Mon Jun 08, 2020 5:01 pm
- Location: Nevada, United States
- Has thanked: 3 times
- Been thanked: 2 times
Re: Prius Gen2 adapter board development thread
What is the resistance range of the pedal? I will likely be using a simple potentiometer with a lever on my ATV, but need to pick one with an appropriate Ohm range (0-5k, 0-10k, etc). I tried googling it, but just get the voltage range, but do not know the amps to calculate the ohms.
Need to learn. Starting from the basics.
Re: Prius Gen2 adapter board development thread
Most "modern" Throttle Pedals are of the Hall Effect type, no resistance measurement, they are Vin >> Vout based on position.TheSilverBuick wrote: ↑Fri Jul 17, 2020 5:36 pm What is the resistance range of the pedal? I will likely be using a simple potentiometer with a lever on my ATV, but need to pick one with an appropriate Ohm range (0-5k, 0-10k, etc). I tried googling it, but just get the voltage range, but do not know the amps to calculate the ohms.
- TheSilverBuick
- Posts: 187
- Joined: Mon Jun 08, 2020 5:01 pm
- Location: Nevada, United States
- Has thanked: 3 times
- Been thanked: 2 times
Re: Prius Gen2 adapter board development thread
Hmm, that would explain the troubleshooting specs being read in voltage and not resistance. I was hoping to use a shaft potentiometer with a lever, but if I have to rig up a system to use an automotive TPS, I'll figure something out. Thanks!
Need to learn. Starting from the basics.
Re: Prius Gen2 adapter board development thread
Any resistor will cause a voltage change, but how much depends on both the specific pot resistance and the input impedance of the controller combined (V = IR).
Re: Prius Gen2 adapter board development thread
okay thanks for the support, but I dont think pin6 is to be used for the resolver as it is labled 5v output.
instead I think
pin 1 = yellow ( enc b)
pin 2= green and brown ( sin a and cos a)
pin 3= red ( enc a)
pin 4 = black r1
pin 5 = white r2
does anybody disagree?
my assumption is that the image I found matches the toyota resolver
instead I think
pin 1 = yellow ( enc b)
pin 2= green and brown ( sin a and cos a)
pin 3= red ( enc a)
pin 4 = black r1
pin 5 = white r2
does anybody disagree?
my assumption is that the image I found matches the toyota resolver
the priustoric boatcar guy
Re: Prius Gen2 adapter board development thread
Since that is the only 5V on the VCU, it will have to serve as the "VRef" for all the attached sensors except motor temp.
Re: Prius Gen2 adapter board development thread
Ran into a few snags to be worked out.
1) I double, triple and quadruple checked my MGR / Q211 resolver connections and I see no signal at all from it in the interface. Next step is to perform voltage measurements on the lines. Polepair settings were tried from 1 thru 8, but I will do some more testing.
2) Motor (MGR/Q211) will not spin smoothly, just jiggles. I tried many of the parameters published, no solution yet, but today this is project # only
3) It appears that when I change "snsm" it affects "snshs" and vice-versa, the closest I can get to rational number is if both are set to "Leaf". Even then, they are off by 50*C or more. Is there something in the coding I can alter to add an offset value, remembering that I am NOT a programmer ???
The Throttle is all set though, although I am unable to get more than 3325 counts of resolution, it seems to be smooth and linear
1) I double, triple and quadruple checked my MGR / Q211 resolver connections and I see no signal at all from it in the interface. Next step is to perform voltage measurements on the lines. Polepair settings were tried from 1 thru 8, but I will do some more testing.
2) Motor (MGR/Q211) will not spin smoothly, just jiggles. I tried many of the parameters published, no solution yet, but today this is project # only

3) It appears that when I change "snsm" it affects "snshs" and vice-versa, the closest I can get to rational number is if both are set to "Leaf". Even then, they are off by 50*C or more. Is there something in the coding I can alter to add an offset value, remembering that I am NOT a programmer ???
The Throttle is all set though, although I am unable to get more than 3325 counts of resolution, it seems to be smooth and linear

Re: Prius Gen2 adapter board development thread
I removed this post as it does not really belong in this thread.
Re: Prius Gen2 adapter board development thread
zookeeper, it looks like your setting for encoder mode is not set to resolver.
( you are ahead of me .. at least you have lights)
is your motor a toyota and is the resolver factory?
( you are ahead of me .. at least you have lights)
is your motor a toyota and is the resolver factory?
the priustoric boatcar guy
-
- Posts: 561
- Joined: Thu Jul 04, 2019 6:35 pm
- Location: Somerset, UK
- Has thanked: 75 times
- Been thanked: 212 times
Re: Prius Gen2 adapter board development thread
Looks like you pushed a few too many Amps through those small wires.
I have hooked up my old 3 phase lathe motor but can't seem to get it running. Using the same settings as I was for the delta light test.
When running fslipspnt at 8Hz or higher there is nothing noticeable happening and the motor will spin freely by hand. However at very low settings like 0.3 and 1 there is a noticeable resistance to turning the motor by hand in time with the pulses and the pulses will stop the motor from turning.
I've tried switch phases wires around and the outcome is always the same.
I have hooked up my old 3 phase lathe motor but can't seem to get it running. Using the same settings as I was for the delta light test.
When running fslipspnt at 8Hz or higher there is nothing noticeable happening and the motor will spin freely by hand. However at very low settings like 0.3 and 1 there is a noticeable resistance to turning the motor by hand in time with the pulses and the pulses will stop the motor from turning.
I've tried switch phases wires around and the outcome is always the same.
Re: Prius Gen2 adapter board development thread
Complete stock and set to resolver.
I ran into another issue after working to install the DC and precherge relays.... The pre-charge would drop out after a few seconds, turned out that the small "197" bulb I was using to confirm bus voltage was pulling more amps than the PC resistor could supply. Remove indicator = fixed, both PC and DC relays behave as expected.
Re: Prius Gen2 adapter board development thread
Now with FOC and having followed the "Using FOC Software" instructions, I get zero output on any of the three phases and I don't hear any PWM being applied (although I have mild tinnitus...). Any ideas?
The GREAT news is that now the Resolver works perfectly w/FOC 4.87.R and I can even count revolutions and seems to match published gearing almost exactly
The GREAT news is that now the Resolver works perfectly w/FOC 4.87.R and I can even count revolutions and seems to match published gearing almost exactly

- johu
- Site Admin
- Posts: 6619
- Joined: Thu Nov 08, 2018 10:52 pm
- Location: Kassel/Germany
- Has thanked: 343 times
- Been thanked: 1485 times
- Contact:
Re: Prius Gen2 adapter board development thread
Great the resolver works.ZooKeeper wrote: ↑Sun Jul 19, 2020 12:07 am Now with FOC and having followed the "Using FOC Software" instructions, I get zero output on any of the three phases and I don't hear any PWM being applied (although I have mild tinnitus...). Any ideas?
The GREAT news is that now the Resolver works perfectly w/FOC 4.87.R and I can even count revolutions and seems to match published gearing almost exactly![]()
Run mode or Manual mode? Is dir=forward? Either by setting dirmode=AlwaysForward or applying 12V to forward pin. All derating parameters set up in a way so they don't derate? (Shouldn't matter in manual mode however)
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
Re: Prius Gen2 adapter board development thread
Yes, same as I had with Sine, but no movement.
I did notice something odd after loading the current SIN.bin file for testing, every time I try and enter 8 for fslipspnt & 75% for ampnom, it reverts to 1 and 10%, almost like it is dividing by 10 and rounding??? Every time I refresh, they do the same. I found 4.85.R is normal for these params.
Wondering if the inverter is ok after the minor short yesterday. Although I cannot see how that would be possible to damage it A 40V with 20ga wires and a power supply limited to <100A.
I did notice something odd after loading the current SIN.bin file for testing, every time I try and enter 8 for fslipspnt & 75% for ampnom, it reverts to 1 and 10%, almost like it is dividing by 10 and rounding??? Every time I refresh, they do the same. I found 4.85.R is normal for these params.
Wondering if the inverter is ok after the minor short yesterday. Although I cannot see how that would be possible to damage it A 40V with 20ga wires and a power supply limited to <100A.