How to avoid any motor movement at init time?

I’m developing a device where the motors should not move at init time once in production. The motors can only move during the calibration phase in the factory.

In another post, it is said that “You can skip the PP check by setting an electrical angle and direction”. Is there a more complete example of how to do that?

Thanks.

It’s in our docs: BLDCMotor | Arduino-FOC

But to actually solve what your post implies, a “calibration phase in the factory” requires a lot more thought - how the device is flashed, configured and calibrated in the factory, and at what stage in the assembly process, how to control the quality, etc… so there’s a whole process to consider, and tools to get it done.

Implied in the whole process is a way to store (and subsequently load) the configuration parameters determined at calibration time. For this we have some code and usage examples in our drivers repository, assuming you want to store the calibration to a non-volatile memory on the device during calibration (YMMV): Arduino-FOC-drivers/src/settings at master · simplefoc/Arduino-FOC-drivers · GitHub

This in turn implies a hardware design taking the non-volatile memory into account, there are different ways to do it. Of course another approach could be to embed the parameters in a custom built firmware for each device, then you would not need a memory.

In terms of SimpleFOC itself, the factory calibration processes are really “higher level” considerations specific to each application, and not really part of our library.

Excellent, thank you very much.