CAN usage at 99.5%

Hey all. So we got done with our first regional and had no problems with our CAN and then we started trying to use motion profiling and all of a sudden our CAN usage went all the way to 99.5% and stuff is glitching out. So we went back to our old code without the motion profiling and it is still doing it. Anyone have any idea what would cause this?

Can you post a link to your code base?

A common culprit here is spamming configuration parameters.

Some solutions include

  • Just setting configuration on init / reboot detected
  • Turning down status frame frequency on devices you aren’t using

I can try upload it. The programmer isn’t in so I’ll have to see if he can help me upload. We are on LABVIEW just an FYI cause I know not many team use it haha.

My LabVIEW experience is in Mindstorms (FLL)
I’ll try to take a look anyway (I don’t have a computer with LabVIEW right now, I’ll check later), but someone from a team that does LabVIEW will show up :stuck_out_tongue:

Did you power cycle the robot between new and old code?

Yes! Not really sure what else would cause it we are just gonna rewire all the CAN tomorrow to see if that helps any.

Does your code factory default the controllers?

Yeah that was the last thing we tried before we left the shop tonight. Still no luck.

Code uploaded here https://github.com/moexx399/3750_2020_CAN_issue
This problem is happening before we even enable the robot.

Some things we have tried
Disabling all of the spark max
Motion frame period to 7ms
Velosity frame period to 5ms
While loop in periodic tasks -> limelight to 100ms
Deleted the empty loops in periodic tasks
Modified all talons to go to factory default. (In this code version only the drive motors do it)
Anything that is not explicitly called in begin.vi is factory default for all motor controler

Does it happen without modifying any of the status frame periods?

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