Sudden loss of comms

So we are running Java code on a pretty basic Tank Drive robot, and a weird issue keeps happening.
Every time we go ‘full throttle’ on our joysticks the robot seems to move for 0.1 sec and than goes “code error” and loses communication.
While driving with 1/2 throttle or so, everything is ok. We have checked the wiring, we have been knocking the robot pretty hard while stationary and it stays connected.
Any ideas?

It is probably an issue with your code. Can you post it?

Edit: What motor controllers are you using?

We are using Victor 888s.
Will post code soon.

Would it be possible that we are trying to send values over 1 or under -1 to the Victors, and that’s what crashes the code?

Is it possible that your battery is not fully charged (or even if it is fully charged) the bot may be browning out when you go full throttle and dropping power to the radio?

Do you get the same behavior on the bench? If so, that would tend to point to a software or Comms issue. If not, more likely due to a brownout or acceleration issue.

Can you post the full error that you receive on the Driver Station? That will determine whether it is a code issue, or perhaps hardware.

It doesnt happen on the bench, therefore we are now confident it is an acceleration issue.
What would the suggested solution here be? Would doing a trapezoidal acceleration curve help, instead of an instant jump to high values?

The ramping function built into WPIlib (and I believe also LV) should at least mitigate either issue; worth a shot!

Edit: On the flip side, if you’re still looking for the issue, do not use ramping, as it may mask the symptoms.

If it is not happening on the bench/blocks, that leads me to believe it is power related.
The first question I have is: Do Comms return if you just wait 30-45 seconds?
If so, the power to the radio is suspect.
Second question: Do Comms return after only 15 seconds?
If so, power to the RoboRio is suspect.

Make sure you are powering both according to the documentation.

Check your drive train for binding. Binding can cause the motors to draw too much current and brownout the system.

The Driver Station log has a lot of messages and data clues to what is happening.

It helps a lot if you post a photo of your wiring and a bit of your Java main teleop.

A simple mistake like powering the VRM off the user rails can cause loss of power to the radio if the roboRIO goes into self-preservation mode on low voltage. It’s impossible for us to troubleshoot without seeing the wiring.

So after some debugging, i think that it was a combination of faulty wiring to the VRM and some coding errors.
It’s all solved now, and no brownouts to be seen.