What is the use of Index Pin

Firstly, this is a great library, and I wish I found it earlier.
I recently purchased my simpleFOC shield and waiting to receive it (it’s taking a little longer, but that’s understandable). Secondly, while waiting for its arrival, I wanted to clarify a quick question about the Index pin.

I have a position control application for which I want a fixed home position every time I turn on the controller. I intend to use AMT103-V as my encoder; I found little information on the index pin online. Can someone who used the index pin in their project confirm that “home position on restart” functionality can be achieved using AMT103-V? If so, how will it retain the position information during power cycles? Does the encoder save it in some form of a non-volatile memory?

I appreciate your help! Thanks!

Hey @santosh,

The AMT103 is an incremental encoder, this means your application will start counting the pulses from the moment the system starts. This means the system will not know the actual position of your rotor and setting position to 0 degrees might be different every time you restart the system. Fortunately, we have the Index signal :slight_smile:. This signal is a pulse that is always at the same position on the encoder, this allows us to use it as a reference and transform our incremental encoder into an “absolute” encoder. SimpleFOC has a routine that searches for this index signal on the set-up so that you can have 0 degrees always at the same place.

I found this picture online to show you what the index signal is:


@David_Gonzalez Thanks for your response, that was informative. So, care should be taken in order to align the sensor with the motor so that the index pin indicates where you want the zero to be.

I received my driver shield, I can’t wait to get my hands on it. Between, your projects on hackaday are cool.


No problem :slight_smile:
Now that you have your shield try to run your motor with and without the index pin and you will definitely see the difference.