Some of our Spark Max just don't work

Their light lights up in the color they should, we can change their settings, their firmware is updated, it does not give an error in the code about a missing spark max and they showup on the app but they just won’t work. When we try to turn them using the app or the code their led color won’t change to green or red and they won’t turn. The code is not the problem since they do turn when we connect another spark max. Any solutions?

please send an email to support@revrobotics.com

A couple things, check your CAN wiring to make sure nothing is flipped Green/Yellow. Ensure you are using the latest version of REVlib.

Sometimes it is best if you want to try them off your robot before you integrate them. I know you mentioned it isn’t a code issue, but checking each device through the hardware client before putting them on your machine is a good way to verify if it is electrical or software.

1 Like

Double check that the motors are fully connected
Double check that the spark maxes are properly set to the correct motor type

We’ve had some poorly put on connectors that caused us to experience what seemed like failed hardware when in reality it’s a user error. Also having it set to brushed and not brushless is an easy mistake to make

CANs are connected properly and I checked them in the hardware client. As I said it is definitealy not a code issue as the same code works for the other spark max we have.

Did you make sure to also set a unique CAN ID for each one?

Yes

1 Like

I had a similar issue where the controller wouldnt light up at all when it should, and it ended up being the motor controller firmware was set in Brushed mode when I was really using a Brushless motor.

I figured it wouldn’t matter since I specifed in code, but I was wrong.

Can you more clearly define what you mean by they don’t work? Is it just not working in robot code? Which SparkMaxes on your CAN bus are not working? Is it a few devices in the middle between RoboRIO and PDP/PDH? Or is it a few in a chain towards the beginning/end of the chain? How many aren’t working?

The ones that don’t work are in the middle of the chain. We can’t get them to turn. They have the correct light color for the motor mode they should be in but when we use the code to turn them their color won’t turn to green or red like other working motors do and they won’t start turning.

Can you try the following for each of the misbehaving SparkMaxes?

  1. Power off your robot and ensure no SparkMaxes ar egetting power, either through battery or USB-C.
  2. Plug the misbheaving SparkMax into a computer using a USB-C cable and scan for it using the Rev Hardware Client. The device should appear, but may require multiple reconnections with the USB-C cable and re-scans of the device using the Rev Hardware Client.
  3. (Optional) Record all SparkMax configuration settings
  4. Reset the SparkMax to its factory defaults and then use the Burn Flash option
  5. (Optional) Restore all SparkMax configuration settings that you saved from Step 5
  6. Disconnect the USB-C cable from the SparkMax.
  7. After repeating 1-7 for each SparkMax, power on your robot.

After this, are you able to control your SparkMaxes in code? As a side question, what is your CAN topology? Are you using the standard daisy chain from your RoboRIO to your PDP/PDH? Also for your SparkMaxes, are you using the SparkMax CAN Cable V2, which bridges the CAN wires at the connectors, or are you using the original V1 cables that don’t do this?

1 Like

If you disconnect a motor from a non-working SparkMax and connect it to a working on, does it turn?

It might be worth trying to reflash it from recovery mode

2 Likes

Thank you, I will try this in the morning

Yes

I hate to say this here. I really really like the Spark Max controller.

That said we’ve had a very small number of failures where they communicate but the motor doesn’t turn.

The number one failure has been in the encoder feedback cable having one or more wires broken.
Just test this by keeping a spare motor handy and plugging it in and seeing if it turns. Use the Rev Spark Max tuning software via USB to avoid confusion with programming errors.

Our number two failure has been harder to diagnose. I have noted that if I disassemble the Spark Max housing that there are two circuit boards joined by a connector. I have separated these two circuit boards and then reseated the connector and it has revived some unresponsive controllers.

Please don’t misinterpret, this is a very unusual failure mode at best. Perhaps it’s due to corrosion or vibration causing a slight separation. I’m more interested in if it’s happened to anyone else.

Did I mention I do like the Spark Max!

1 Like

We tried doing that but it still does not work. We are using the v2 of can cables with bridges. The spark maxes with the problem seem to not give an error when the sensor is not connected(they are in brushless mode).

What are these motors programmed to do? Are some of them set to follow other motors, or are you directly commanding a percentage output to the motors?

In your code in the constructors of your subsystems, try using the function call restoreFactoryDefaults() for each SparkMax before configuring the motors in code and see if that helps.

We give them a percentage output and we try them one by one using a code that turns only one motor. We tried using restorefactorydefaults in the code but it didn’t help either.

Are you configuring any of the SparkMaxes to follow another motor prior to sending them a percentage output? If so, try removing that setting.

Are you still getting the missing CAN device error message that you were reporting earlier? Using the Rev Hardware Client, when you connect to a single working SparkMax, do you see all SparkMaxes on the CAN Bus in the Rev Hardware client from the working SparkMax or are you still not seeing your unresponsive SparkMaxes?

We see all the Spark Max’s and never had any problem with the CAN bus and they always appeared on the hardware client. Spark Max’s don’t follow any other Spark Max as the code is made to only turn one Spark Max but incase it matters we did try to make them follow another Spark Max sometime before but it is not in the current code as it is just for rotating a single motor.