Start the drive, but without the motor moving

goodnight. would it be possible to start the drive, but without the motor moving? the motor is on a CNC machine and is coupled to a ball screw. moving it can cause damage if it moves when energi

I would not do any testing with a motor coupled to a ball screw drive with a machine.

It may be safer to disassemble the motor or remove the coupler that usually joins the ballscrew to the motor to avoid any unexpected movement that could cause a collision in your CNC.

Good afternoon @JorgeMaker
,
yes, I did the tests with the moto disconnected, but every time I start the simplefoc, the motor rotates a little to each side. I would like the motor to remain stopped during startup.

The motor is doing this movement for calibration…

You can record the calibration values and supply them to the motor.initFOC() method, then the motor will skip the calibration step.

Additionally, you can use the motor.sensor_offset setting to move the “zero point” is needed.

Finally, set the initial target value to be the current position (if using angle mode), or to 0 velocity, to prevent initial movements.