Page 1 of 1
Potmode CANDual
Posted: Wed Mar 24, 2021 8:33 am
by bexander
I have changed SW from 4.94 to 5.00 and was just out driving. Noticed that I no longer have regen when releasing the throttle pedal, potnom goes to zero where it used to do regen before.
"pot" value changes as soon as I press the pedal but "potnom" stays at zero below throttle point.
Looked into the prameters and found a new Potmode option, CANDual.
I couldn't find any information about this on the forum or the wiki.
Johu, or anyone else, can you please explain what has changed regarding Potmode and possibly also how to set it up for one pedal driving, as I had before over CAN.
Re: Potmode CANDual
Posted: Wed Mar 24, 2021 8:56 am
by johu
Not sure what the deal is, post a parameter dump. I have normal regen with v5.0
CANDual means the redundant throttle checks are applied to the CAN received pot values, i.e. pot and pot2 are taken into account. In that mode regen throttling is not active, regen always happens with brkmax/brknompedal - of course still scaled by how much you come off the pedal.
Re: Potmode CANDual
Posted: Wed Mar 24, 2021 9:29 am
by bexander
Here are my parameters:
So there should not be any changes to the throttle/regen from 4.94 to 5.00? I must have messed something up then.
Aha, CANDual is the same as DualChannel with the difference beeing CAN input instead of Analog input. Thats great!
Re: Potmode CANDual
Posted: Fri Mar 26, 2021 8:32 pm
by bexander
I suspect that my tweaking of the dc-bus1 measurement in the Prius inverter might have upset the Toyota engineers to deny me regeneration.
Is there any way to check if the firmware is trying to regen but gets nothing back from HW? Would I still get potnom equal to 0 when trying to regen if this is the case?
Re: Potmode CANDual
Posted: Fri Mar 26, 2021 8:50 pm
by mjc506
potnom will be negative for regen. You should be able to plot it on the wifi interface

Re: Potmode CANDual
Posted: Sat Mar 27, 2021 5:49 am
by bexander
I never get potnom to be negative and I wounder if the SW never sets regen or of the SW tries to set regen but the HW stops it and I never get potnom negative anyway?
It was working before, but it dosen't anymore so I must have done something that stops regen, just trying to figure out what.
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 9:24 am
by mjc506
I don't believe the inverter has any say in setting potnom (maybe the new vcu Damien's working on, but not the 'standard' openinverter software.
I can't see anything obvious in your parameters, although I'm no expert.
Have you confirmed you get the correct values being sent over CAN? (And received?) Your DC bus never exceeds udcmax?
The only relevent changes in the firmware I can see is CAN scaling handling for gains >32, I don't think that'll affect you.
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 12:51 pm
by bexander
My DC bus is just under 400V so should not be the problem.
I relized I have test driven with the 5.00 SW an had regen the first time so a SW malfunction can be excluded.
Since then I have charged the battery pack from 375V to 398V and I have tampered with the dc-bus1 measurement in the inverter to get the 328p able to read up to 450V. My concern is that this have made somehing in the inverter to trip and not allow regen in HW.
It is also possible or even likely I have messed something up when I disassembled and reassembled the inverter.
What I would like is to find a way I can exclude the possibility of a parameter setting error, thats why I'm asking if or how I can see if the SW is not letting me do regen?
I get "pot" values from 1 to 775 so pedal signals (over CAN) received looks ok.
"potnom" on the other hand does not go negative, it starts to go positive at about 30% pedal, at 235 on "pot".
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 2:33 pm
by johu
Something is derating regen. So udc < udcmax I suppose. What is the value of "pot2"? I wonder what happens if it actually sits at 4095 digits.
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 3:03 pm
by bexander
"Udc" just below 400V and "udcmax" is 520.
I don't use "pot2" but I send "pot2" = 0 over CAN. And settings are "pot2min": 4095 and "pot2max": 4095.
So, might be a good idea to start using the CANDual mode and send the same info for "pot2" as for "pot" and also set it up accordingly.
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 3:37 pm
by bexander
And now it is working again!! Thank you johu and mjc506!
Must have been something conflicting in my parameter setting.
This is what I have now.
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 4:29 pm
by johu
So, the diff:
Code: Select all
param old new
potmin 1 0
pot2min 4095 0
pot2max 4095 775
potmode 2 3
So now you use CANDual, setup pot2 like pot and changed potmin from 1 to 0. Which step was the key?
Re: Potmode CANDual
Posted: Sat Mar 27, 2021 5:24 pm
by mjc506
Glad you got it working

Re: Potmode CANDual
Posted: Sat Mar 27, 2021 8:23 pm
by bexander
johu wrote: ↑Sat Mar 27, 2021 4:29 pm
So, the diff:
Code: Select all
param old new
potmin 1 0
pot2min 4095 0
pot2max 4095 775
potmode 2 3
So now you use CANDual, setup pot2 like pot and changed potmin from 1 to 0. Which step was the key?
I did all the changes at once...
But I have now done more tests to find out what was the key. Only tested stationary.
CAN vs CANDual is the key, but observed some more things I thought is a bit odd.
With "new" parameter settings I get potnom -21,6% when selecting forward, pedal at top position. This is what I also got with the 4.94SW using "old" parameters. (I do not know why it is set to -21,6%? I would expect -30% but it works and I think I get -30% when doing regen with forward speed.)
Changes when pressing the pedal.
Setting potmode back to "CAN" and when selecting forward I get potnom approx. -2%. Stays at approx. -2% when pressing pedal right up until I get close to "0"-pedal where it follows pedal and then gets positive when passing "0"-pedal.
Setting pot2min and pot2max to 4095 results in potnom -0,3% with pedal at top position which gets to 0% as soon as I touch the pedal and stays at 0% up until "0"-pedal position.