CM4SL Regenerative braking

My FS team is attempting to create a control system for the regenerative braking in CM4SL. This system will function much like for the Gas system with the torque demand being controlled by a traction controller etc. but with negative torque instead. What signal would I need to manipulate to send regenerative braking torque demand to the motors? We have modified the FS Torque vectoring simulink exanmple file so our system architectuture looks similair. Any help is appriciated.


you can reuse the PTcontrol.mdl example in CarMaker for Simulink (example folder) and make sure you overwrite those quantities, selecting EV powertrain too.