cancel
Showing results for 
Search instead for 
Did you mean: 

custom STSPIN32G4- Dual motor, 2nd motor does not work

GSB
Associate II

[PN]: STSPIN32G4
[VERSION]: 6.4.0
[TOOL]: Motor Control Workbench
[DETAILS]:In this design, the second motor does not work as the interrupts that invoke the FOC_HighFrequencyTask by setting the motor ID into the array FOC_array[] are not enabled (TSK_DualDriveFIFOUpdate() is never called). Motor 1 happens to work as it's ID is 0 and the array is 0 initialised. Also the task TSK_HighFrequencyTask is only invoked at the PWM rate, not twice the PWM rate as it should be called once per motor, ie twice the PWM rate..

[EXPECTED BEHAVIOR]: The motor 2 current should be modulated but stays at 0 as the FOC_HighFrequencyTask(M2) is never called.
[HOW TO REPRODUCE]: just start motor 2 from motor pilot

 
 
1 ACCEPTED SOLUTION

Accepted Solutions
GMA
ST Employee

Hello @GSB,

Each motor must be connected to a different ADC.
You can refer to the genuine EVSPIN32G4-DUAL board, which is a dual 1Shunt topology design.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA

View solution in original post

3 REPLIES 3
GMA
ST Employee

Hello @GSB,

Thank you for your report.
Unfortunately, the dual drive, dual single-shunt, and single ADC use case is not covered in our current MCSDK release. We will add a restriction message in the release note to inform users of this limitation.
In our current implementation, two different ADCs are required for each drive.


If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA
GSB
Associate II
Do you mean each motor current sense must be connected to a separate ADC. Will my 2 motor design then work or is there any other changes i need to make to drive 2 motors?
GMA
ST Employee

Hello @GSB,

Each motor must be connected to a different ADC.
You can refer to the genuine EVSPIN32G4-DUAL board, which is a dual 1Shunt topology design.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.
Best regards.
GMA