Magnetic Encoder: ABZ vs SPI mode

Although I’ve read some existing discussions on this topic, I’m still wondering about the practical use case for ABZ (incremental) encoders when there is the option of using absolute interfaces like on the MT6701 (SPI).

My main point of confusion is around startup. Does an interface like SPI on the MT6701 that gives the absolute angle prevent the need to ‘home’ the motor (i.e., move it to find the index pulse) every time the system starts up? If absolute encoders offer this advantage, why do many users and designs still prefer and implement the ABZ interface?

It seems like a hassle to have to spin the motor in open loop to find the index and establish the motor’s starting position every time, especially when you want to run the motors quickly after a boot.

Being absolute is indeed an advantage of the magnetic encoders with on-axis magnets and SPI interfaces. The ABZ based interface requires an index search before it is absolute.

But ABZ encoders have far lower latencies, and are supported natively in hardware in many MCU types, so you can use them with no overheads.

It is also possible to measure the velocity more precisely in many situations by precise timing of the encoder transitions.

Compatibility will be another key reason to choose an ABZ interface, as many COTS parts will support such inputs.

Interesting insight! Do you know if the lower latencies and more accurate velocity measurements would result in smoother motion at low RPMs in closed loop? I’m currently using a hall-sensor based BLDC (inner rotor, slotless) and I was hoping magnetic encoders would allow smoother motion below 100 RPM

Switching from SPI to AB on an ESP32-S3 gave me an immediate 4x boost in motor-loop speed. I think that should translate into smoother motion at low RPM.

Actually you have to be careful with that:

  • lower latencies and faster loop times will improve your control
  • But on many sensors ABZ output is lower resolution than SPI, eg 12 bit vs 14 bit
  • Of course if the extra bits are just noise then there is no benefit but at lower speeds a good sensor should be more stable in the lower bits than at higher speeds (bandwidth limitations)
  • At really slow speeds the timer based velocity measurement doesn’t work well either because both position and velocity become more discretized in time

So it’s something to try empirically I think :slight_smile:

Thank you both for your insights. For anyone reading this topic in the future; in my testing there was no noticeable difference between SSI and ABZ for low-speed (1 rad/s) or medium-speed (up to 500 rad/s). But I do recommend testing each, because @Runger gave some solid reasons to choose one over the other. I’m choosing SSI since this gives the absolute angle, thus allowing me to skip the start-up calibration.