DC-link voltage Vdcnom and on a high voltage limit Vhigh. For example, weight coefficient V may be 1 if voltage Vdc(t) is below the nominal DC-link voltage Vdcnom, weight coefficient wV(t) may be 0 if voltage Vdc(t) is above high voltage limit Vhigh. The method may decrease the weight coefficient coV linearly from 1 to 0 as the DC-link capacitor voltage Vdc(t) changes in a prefixed range comprised between nominal DC-link voltage Vdcnom to high-voltage limit Vhigh. The active voltage limiter unit 115 is further configured to calculate a value indicative of the difference bewteen the active current ia(t) and the maximum allowable regeneration current ialstAbs(t): The active voltage limiter unit 115 may also comprise a proportional-integral regulator 115a, which receives the value , performs a proportional-integral function (PI function) on the value to calculate the torque limit Tref_lim used to regulate the torque reference Tref. = ia(t)- ialstAbs(t) The proportional-integral regulator 115a of the active voltage limiter unit 115 provides the calculated torque limit Tref_lim in input to the comparator 129. The comparator 129 is configured to: receive in input the torque target Tt preferably from the electronic control unit 110, receive in input the torque limit Tref_lim from the active voltage limiter unit 115, receive in input the motor speed , compare the torque target Tt with the torque limit Tref_lim, and set the torque reference Tref based on the satified condition among the following four conditions: More specifically: when the motor speed is positive ( >0) and the torque target Tt(t) is greater