Problem Controlling E-BIke

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem Controlling E-BIke

4,211 Views
PedroCastro
Contributor III

Hi,

I have a e-bike project that I am using kv31f and kms as the motor controller. Since I need a torque control, I have to use the current control mode of kms. As far as I understood, the torque control must first go through a speed control and after a threshold the torque control takes place. The problem is that in e-bikes the pedal is mechanically coupled with the motor, so when the user pedals the motors also spins. In this situation it seems to me that if the motor is already spinning or even above the rpm threshold, the controller is unable to enter the current control. The faults the system gives is kind of random to me, for example: peak current on phase (A/B/C) which is strange cause I am trying to use current control. Motor overspeed in low rpm and even under voltage using a DC power supply.

So, my question is: How can I use a current control for an e-bike with a motor mechanically coupled with the pedal?

Thanks in advance

Labels (1)
0 Kudos
28 Replies

689 Views
PedroCastro
Contributor III

Hi Adam,

another workaroud I thought about was to set a higher speed limit when in startup and never reach the FOCLowSpeed. Is it possible to modify this limit?

0 Kudos

689 Views
linestream-adam
Senior Contributor I

Pedro,

I'm not exactly sure how this would help.  Isn't this what you are doing where the motor isn't producing as much torque as you expected?

0 Kudos

689 Views
PedroCastro
Contributor III

I would like to do more tests and I cannot get higher speeds in startup mode

0 Kudos

689 Views
linestream-adam
Senior Contributor I

When running in speed mode you can raise the FOCLowSpeed.  You can use the same variable you were working with before.

0 Kudos

690 Views
linestream-adam
Senior Contributor I

Pedro,

There are no plans to add a flying start algorithm into KMS.  This is something that you as the product engineering team can add in to differentiate your product from the typical usage of KMS.  

0 Kudos

690 Views
linestream-adam
Senior Contributor I

Pedro,

In order to support a speed-regulated torque mode there are a couple of things you need to do.  

  1. On "Protection & Hardware", set the "Stall Speed Error" to be twice the rated speed of the motor.
  2. Click the "Update Motor Drive Configuration" button
  3. Open the watch window, and add the variable: "user.command.IqRefMax",. this will be the torque reference
  4. Go to the "Speed Control" page and enter a target speed of the maximum speed you want the motor to run
  5. Click Start

Now the motor will follow the trajectory and will not exceed that set maximum speed, and it will use up to the amount of torque specified in "user.command.IqRefMax" in order to reach that speed.  The goal here is to operate the speed controller in saturation so you adjust how much torque you would like the system to be applying by modifying the user.command.IqRefMax, and you can set an upper boundry on the speed by adjusting the target speed.

0 Kudos

690 Views
PedroCastro
Contributor III

I am always running above FOCLowSpeed and it mantains a torque with no problem but with limited speed. So am I always in TRAP mode, right? What if I could run until rated speed in this mode?

0 Kudos

690 Views
PedroCastro
Contributor III

Adam,

it really worked! It now fits our needs. I appreciate your help

Just one more advice I would like to have from you... In order to do regenerative braking, you suggest to use brake and regen as braking type or use current mode but with negative current demand?

0 Kudos