cancel
Showing results for 
Search instead for 
Did you mean: 

How to get a B-G431B-ESC1 to work with an encoder in torque control mode with a pwm input

JFeis.1
Associate

Ill admit that im very fresh when it comes to ST products and software which is probably why Im having trouble.

Im trying to set up a B-G431B-ESC1 essentially like closed loop servo driver.

So far Ive managed to run the motor profiler and started a new project in the motor control workbench but Im getting the following error. When I set the speed sensor to an encoder some of the IO pins seem to be clashing. What I dont get is how to choose which one to use since I cant find a schematic or any reference to which ones should be used. Ive found where to set the controller in torque mode but I cant see where to set the input type.

Assuming I can get past this issue what is the next step to go to to program the controller? The shear amount of programs required is proving hard to get my head around

Thanks

2 REPLIES 2
uomo motore
Associate III

As per the board schematic, you need to select TIM4 (not TIM2) for Encoder Interface in the Digital I/O section. CH1 (Enc A+) needs to be set to B6 and CH2 (Enc B+) needs to be set to B7. Default values are correct for Hall sensor. Need to use same values for Encoder as well.

Going through the board user manual and MCSDK getting started document could be helpful for compiling the code and programming the controller.

Regards...

Laurent Ca...
Lead II

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

Best regards