Skip to main content
TKlei.5
Associate II
April 26, 2019
Question

User Code in Motor Control Firmware

  • April 26, 2019
  • 1 reply
  • 585 views

Hello,

at the moment i use the STEVAL-SPIN3202 board and the Motor Control SDK to drive a BLDC-motor. Now i want to implement my own function to switch off the motor if it exceeds a specific speed and current.

I don't know where i can find a variable which contains the actual speed or current of the motor?

For Example:

/* Infinite loop */

 /* USER CODE BEGIN WHILE */

 while (1)

 {

   PotentiometerHandleSpeed();

if(current >= 15 && speed >= 6000)

{

HAL_Delay(3000);

MC_StopMotor1();

}

   }

 /* USER CODE END WHILE */

This topic has been closed for replies.

1 reply

Laurent Ca...
Senior III
June 15, 2021

The question has been moved from the "Motor Control Hardware" section to the "STM32 Motor Control" section (the question is about the STM32 MC SDK). 

Best regards