2021-06-15 01:05 PM
hi I was using STM32CubeExpansion_SPN7_V1.1.0 with f401re and IHM071M1 the motor with the potentiometer runs well without problems, but what I wanted to do and control the motor direction of rotation, speed and finally stop motor, I wanted to do it via software in order to control each cycle in the while (1), starting with small speeds
thank you
2021-06-16 01:38 AM
Hi @SDall,
you can find all details in the user manual UM1946
In the Projects directory of X-CUBE-SPN7 package you can find an example application using the X-NUCLEO-IHM07M1 expansion board with NUCLEO-F401RE boards. Ready to build projects are available for multiple IDEs.
In this application, a low voltage 3ph motor is driven by the L6230 device. The firmware implements a 6-Step MC algorithm. The current measured in single shunt mode is compared with a reference generated by a digital speed loop for current control.
Inside the Documentation folder you can find a compiled HTML file generated from the source code and documents the software component and API details.
The L6230.c file implements all the API functions to manage the motor driver; in particular, it is possible to start/stop PWM signals, enable/disable each inverter leg, etc. At the user level, MC_SixStep_param.h contains all the motor driving parameters like the number of pole pairs, target speed, PI parameters for speed regulation, etc.
An alternative option to program the X-NUCLEO-IHM07M1 with the NUCLEO-F401RE is use the last release of STM32 Motor Control SDK (X-CUBE-MCSDK-Y).
Here you can find some examples for reference.
Let me know if this info is useful to you, if yes please "Select as Best" button to close the topic.
2021-06-20 05:13 AM
2021-06-22 03:27 AM
Please someone answer me!
2021-06-24 12:46 AM
Hi @SDall,
for your purpose I suggest to use the high level functions listed in the 6Step_Lib.c :
In any case remember to set the motor parameters in the MC_SixStep_param.h
2021-07-07 04:02 AM
Hi @SDall ,
any updates about your progress?
Have a nice day.