Spark Max - D Gain seems to have no effect

We are trying to do velocity control on the Spark Max and tune the PID. We have oscillation that we are trying to damp out but D gain seems to have no effect on tuning behavior. We have varied it from 10,000 to 0.00001 and behavior is identical for all D gains. Is there a bug? Any ideas what we could be doing wrong?

We are using example code and we are using labview.

P gain is 0.0005 and F gain is 0.00018. We have no I gain and I zone is 0.

The spark max and NEO was from last year.

We just switched to a brand new spark max and NEO from this year and damping now seems to have some effect.

Any idea why the difference might be?

1 Like

We have also had several issues with using the Spark Max motor controllers with LabView. Since it’s working correctly with your new motor controllers, maybe it could be that the firmware on the old ones is outdated? Rev Robotics mentions this (very) briefly on their software resources page.

1 Like

Both are flashed to 1.5.1.

One other thing we noticed. The old one feels like its in braking mode or has a ramp rate set.

Picture shows the velocity of the motor. It jumps up quickly and then slowly accelerates. Applied out is constant.

We check and old motor does not have any ramp rate set and is on coast.

Unless you’re using an alternate encoder, that firmware version should be fine.

When you say you’re using a LabView code example, do you mean one of the ones they offer for download here? If that’s the case, that could be your problem because we weren’t able to get those to work properly either.

If you’re using one of the examples available from within Rev’s LabView API, could you post a picture of it?

It is the example code from REV. But its not the code that has issues. We switch spark max controllers and it works.

Try a complete factory reset by going the the arrow next to “Restore Factory Defaults” and click “Reset All”.

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.