cancel
Showing results for 
Search instead for 
Did you mean: 

Motor Control Help - EVLDRIVE101-HPD

mitch1
Associate II

Hi,

I can't manage to get my motor to work with the EVLDRIVE101-HPD board. I have generated the FOC firmware and uploaded it to the board through STM32CubeIDE. See attached for main.c

Is there something else I need to do? I have followed everything in the user manual for the board, but it is quite minimal in it's instructions.

I have done all of these steps.

"To start your project with the board:
1. Connect the brushless motor phases to J1, J2, and J3
2. Supply the board through J5 (positive) and J6 (ground)
3. Download the compiled code through the SWD interface connecting the STLINK programmer to J7
(STDC14 connector)"

After these steps, the board is powered up but there is no PWM signal on the phases. It is a constant 0V. 

Any help will be appreciated, 

Thanks!

 

10 REPLIES 10
Gael A
ST Employee

Hello mitch1,

Could you please tell me which version of the MCSDK you are using ?
Have you connected the MotorPilot to the board (refer to User Manual documentation available through "Workbench tool">About>Documentations>Documentation>"Getting Started with ST Motor Control SDK", "Motor pilot" chapter)? Is it returning any error, is the VBUS correctly asserted for example ?

In any case, there is no default start in the Main.c init procedure. You can also use APIs available in mc_api.c to start your motor.

 

If you agree with my answer, please consider accepting it by clicking on 'Accept as solution'.

Hope this will help,
Gaël A.

Hi Gael,

I have not connected the MotorPilot to the board as it can't detect it, which I assume it is because it is not compatible with the STM32G0 IC on the EVLDRIVE101 board, stated in the MotorPilot document; 

"It is not possible to generate a motor profiler binary with the STM32F0, STM32G0, STM32C0 families"

Is it possible to run the board without the MotorPilot step?

I am using MCSDK 6.3.0

Update to this:

I added MC_StartMotor1(); in the code, in the while(1) loop:

And on power up, it starts the motor for a split second with the correct PWM output I have set.

So I guess everything is running ok? Just need to figure out how to code it correctly for the motor to run continuously?

Any ideas on how to do this?

 

 

 

Hello mitch1,

The documentation line you are referring to is true for MotorProfiler, but not for MotorPilot, so an impossibility to connect seems weird to me. Could you send me your .stwb6 file as well as tell me which version of the MCSDK you are using please ?

I am glad that you managed to make your motor run (even briefly) using the api. While its true that ultimately the application will only need those to get things working, the MotorPilot is still a great tool for debugging, so I recommend to use it during the development phase. It will allow you for example to find the correct start-up parameters more easily. Don't hesitate to have a look at the MCSDK User Manual (Via WorkBench, you can find it by clicking on About -> Documentations -> Documentation -> in the newly open browser window, click on User Manual) and at our STM32 MC Wiki for more information on those points.

If you agree with my answer, please consider accepting it by clicking on 'Accept as solution'.

Hope this will help,
Gaël A.

Thanks for helping Gael,

I am using MCSDK 6.3.0. 

Still unable to connect to MotorPilot, see attached screenshot for log info. It says "COM4 is not a STLINK VCP", which is where the board is connected with STLINK-V3MINIE. Odd that it can't connect to the MotorPilot but the IDE can connect to it, as uploading code to it works. 

I have attached the .stwb6 file in the link: 

https://drive.google.com/file/d/1h5LDbO9vDSlr_7XjVDyiE1joOTJHNc9e/view?usp=sharing 

In the meantime, i am trying to startup with STOPLL/Cordic algorithm. 

thanks,

Mitch

Update: I managed to connect to the MotorPilot. But the issue still remains. Where the motor does not turn, it tries to on start up, but all it does it a little jerk. Giving the following result:

mitch1_0-1721705649708.png

"Driver protection fault", i couldnt find any info about this on the user manual, what could i do to troubleshoot this fault? On the phases outputs, the PWM signal appears to be in sync on start up, then turns off when in "fault_over" status.

After seeing this, i turn driver protection off to see what happens. And the motor does a similar thing, but remains in start status mode a bit longer. it produces the following profiles on the three phases profiles to the motor (see photo). This makes the motor jerk but not turn at all. 

mitch1_1-1721706322935.png

Any advice on what to do? Thanks,

 

 

 

GMA
ST Employee

Hello @mitch1,

"Driver protection" is the error generated by STDRIVE101 Driver, please refer to UM3257 documentation, 4.2 Current sensing chapter and check if your application current level e.g. corresponds to "default threshold".

You can also have a look to User Manual documentation available through "Workbench tool">About>Documentations>Documentation>"User manual", "Firmware errors" link, "2. Over Current" chapter.

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

Hello @mitch1 

did you try to reduce the current target to a value below 15A during the open loop period to see whether the motor can be accelerated without incurring in a protection fault?

You can do it  both in the motor pilot (rev-up secrtion) or in the workbench (Sensorless start-up parameters)

Alessio

Hi Alessio,

I reduced the current to 5A and it is giving me the same fault. See screenshot below.

mitch1_1-1721783155969.png

It also produces no PWM signal during this unlike the previous tests. 

However, it looks like the driver protection fault is caused by the over voltage in VBUS. i turned that off and the fault changed but the motor remains still. 

mitch1_3-1721783980801.png