Here's what you want. Note that "chopped" is Accel_Min, not Pedal_Lo. Pedal_Lo and Pedal_Hi must not be reachable in normal operation. Pedal_Lo should be about halfway between chopped and zero volts. Pedal_Hi should be about halfway between WOT and 5 V. Also note the much wider regen zone, drawn approximately to scale, unlike yours.
jonescg wrote:To test this (without a wheel attached) I changed the resolver Gamma adjust from -7.4 degrees to +173.6 degrees and as expected it spins the opposite direction, however as soon as it hits base speed it goes into a runaway state all the way up to 5200 rpm or more, and throws an error.
I wouldn't worry about that unless it still happens after you get regen sorted.
The regen thing is a tough one. Obviously it needs to have some dead spot in order to work, but Danny wants no such deadspot. The alternative is to have a clutch lever which gives the sensation of a rear brake, and is hooked up to the regen potentiometer. This requires more thought and more getting used to, and might not be ideal. Perhaps the dead spot need only be 5% of WOT (wide open throttle) in order to engage coasting regen.
You seem to be misunderstanding how this works. "Coasting" and "regen" are two very different things. There is no need to have any coasting region of the throttle -- no need for a deadspot between motoring and regen. It can just pass smoothly from motoring to regen and back again. Sure there will be a zero torque point
somewhere between motoring and regen, but if it's set up as I describe below, you won't feel it. The requirements for this are:
(a) that Coast_Lo and Coast_Hi are set to the same value, and
(b) this value is at a specific point between Accel_Min and Accel_Max that depends on the ratio of Regen_Torque_Limit to Motor_Torque_Limit as follows:
Coast_Lo&Hi = Accel_Min + (Accel_Max - Accel_Min) * (Regen_Torque_Limit / (Regen_Torque_Limit + Motor_Torque_Limit ))
For example, if Accel_Min = 20 and Accel_Max = 480, Motor_Torque_Limit = 5430 and Regen_Torque_Limit = 1086 (20% of Motor_Torque_Limit) then Coast_Lo and Coast_Hi should be set to 20 + (480 - 20) * 1086 / (1086 + 5430) = 97.
I tried to explain this, but without giving a formula, at the end of my first post on the topic, way back here
viewtopic.php?title=voltronevo-jonescgs ... 553#p51421
and in my post that followed it.
There will be no dead spot or dead zone once the bike is moving, but sure, when starting off, nothing will happen until you move the throttle past the regen zone, but Danny should be able to gently wind that on in advance while waiting for the start signal.
If you instead put Coast_Hi and Coast_Lo within a few counts of Accel_Min then when you back off the throttle for a corner, maximum regen will cut in very suddenly. You won't have smooth control over regen.
One of the fathers of MeXy the electric MX-5, along with Coulomb and Newton (Jeff Owen).