.
Code: Select all
const int pedal_map_three[21][22] = {
// Sport
// map 3..
/*250*/ {0, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*500*/ {-10, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*625*/ {-20, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*750*/ {-30, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*1000*/ {-50, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*1250*/ {-70, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*1500*/ {-90, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*2000*/ {-110, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*2500*/ {-130, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*3000*/ {-150, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*3500*/ {-150, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*4000*/ {-150, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*4500*/ {-150, 0, 18, 20, 20, 20, 18, 18, 18, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 18, 18},
/*5000*/ {-160, 0, 15, 20, 20, 20, 20, 20, 20, 16, 16, 16, 16, 16, 15, 15, 15, 15, 16, 18, 18},
/*5500*/ {-180, 0, 15, 20, 20, 20, 20, 20, 20, 16, 16, 16, 16, 16, 15, 15, 15, 15, 16, 18, 18},
/*6000*/ {-200, 0, 15, 20, 20, 20, 20, 20, 20, 16, 16, 16, 16, 16, 15, 15, 15, 15, 16, 18, 18},
/*6500*/ {-200, 0, 15, 20, 20, 20, 20, 20, 20, 16, 16, 16, 16, 16, 15, 15, 15, 15, 15, 18, 18},
/*7000*/ {-225, 0, 15, 20, 20, 20, 20, 20, 20, 16, 16, 16, 16, 16, 15, 15, 15, 15, 15, 18, 18},
/*7500*/ {-250, 0, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 15, 15, 15, 15, 15, 18, 18},
/*8000*/ {-300, 0, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 15, 15, 15, 15, 15, 18, 18},
/*10000*/ {-300, 0, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 15, 15, 15, 15, 15, 18, 18},
};
I may try to remove the limits or simply increase it to 250Nm or similar, just to see what will happen.
Mazda V6 engine used to have 230Nm of max torque at 5300RPM...
EDIT: Whoa! Torque at start was huge with value 25! I could easily shave tires... But very soon torqueRequest = 0; reduction kicked in.
So for another attempt i reduced values to 20 and changed torque reduction to torqueRequest = 2000; So as to stop adding to torque but keep the torque already requested.
EDIT2: Yep! As i thought. With all those changes motor will just about spin tires on the spot. Acceleration is much more healthy and torqueRequest will stop at 2000 mark. Max amps will reach 220A and never exceed that limit. Even regen is behaving softly at 25A. All this in pedal map3 without any increments. I must say i really like map3 logic.
There is a dark side though, When in map1 there is a rubbery feeling of throttle effect. Also suddenly throttle would go from 100% to 0 and create a sudden jolt. I abhore map1 and its incremented torque. Seems unnatural.
EDIT3: To remedy this i remodeled map1 and still i get unnatural acceleration/decelleration with increments. But now when in overtorque torqueRequest goes to final value at least it wont jolt the car anymore...