CTRE CANcoder with Rev Spark Max

I would like to use the CRTE CANcoder as a feedback device for a REV Spark Max and Neo motor.

I would like to use the Spark Max smart motion control feature rather than doing the control on the Rio. Is it possible to use the CTRE CANcoder as a feedback device directly on the Spark max. If so how do I set up the encoder in my constructor? I am hoping to use the absolute output value.

It looks like in the docs it is possible to use different encoders than the build in hall effect, but I have not found any good direction on exactly how this is done. Specifically with a CTRE type encoder.

I have not found any good examples of this done if it is possible. If I am missing something please point me in the right direction.

Thanks in advance.

As far as I’m aware, this is not possible; the REV Spark Max can’t read the CAN messages being sent by the CTRE CANcoder. As an alternative, you can use a SRX Mag Encoder with the REV Spark (using the alternate encoder mode).

I wish someone would make a decision tree of encoder compatibility. It’s so confusing what works with what in the brushless age.

3 Likes

Thanks for the feedback. I thought this might be the case, but I was hoping that somehow they would play nicely together. I will give this a go though the WPILib trapazoidalProfile and see how that goes.

Are you using the CANCoder for absolute position with a neo/neo 550? Depending on how precise you need to be you can use the CANCoder as your absolute reference point and then use the built in encoder for neo and use the spark max smart motion.

We use this on our swerve. We continuously check that the neos position isn’t far off from the CANCoder just in case of things like breakers tripping or other issues.

2 Likes

Yes we were hoping to use the absolute ref point with a neo motor. Thanks for the idea we might try something similar.