Talon SRXs Extremes

We have done testing with our robot and we have figured out that the left motors can only go at 0 or 100%. The right motors, however, have no problem, and we are initializing both motors the same in our code. Also, our robot worked fine before we updated to the new 2022 WPILib. Thus, we believe that this may be a hardware issue or an update problem. Has anyone else had problems similar to this?

2 Likes

Please make your code available for review (preferably on github)
Probably not the cause, but what version firmwares are all your TalonSRXs running?

Have you tried adding a ConfigFactoryDefault call to your initialization routine? There could be some residual settings from older code.

3 Likes

What values are you feeding into the motor controller’s set() method? If you’re using the (double) overload or PercentOutput, the range of values is [-1, 1] – if you’re accidentally using values in the range of [-100, 100] then it makes a lot of sense that any non-zero input will cause it to use full power.

If you manually factory default the talon in Phoenix Tuner, and then run your robot code is the problem the same?

The documented way from CTRE to configure the Talons is to instantiate an empty config object, then set all the values that are not the defaults in your robot code. That would also fix it if it’s an issue of stale configuration limits (like PeakNominalReverseLimit, or whatever that config setting is).

We do call ConfigFactoryDefault in our initialization routine and we do it for both sides of the robot.

Here is our code on GitHub

We are using velocity mode, and we convert from percentage to velocity using one of our functions. Also, we recently tested the motors using phoenix tuner in velocity mode and encountered the same problems, so we believe this is not the issue.

Did you verify with Phoenix Tuner that you can factory default the motor controllers and they behave the same?

The Phoenix Tuner will let you know whether you have a software problem, an electrical (wiring) problem, or a firmware problem.

Doesn’t seem like a wiring problem, so for my money it’s likely a software issue, less likely but could be a firmware issue. A simple test would be to create an empty template project in VS Code, deploy that to the robot. Then in Phoenix Tuner, factory default the motor controller, set your PID constants and try to recreate the behavior.

Thank you for all of your inputs; we appreciate it. We have discovered this issue had to do with faulty encoders that was hooked up to our motors.

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