We are having a very annoying problem with running the robot. This problem happens spontaneously (in our perspective) and we couldn’t figure out for several days what’s the cause of it.
First we connected the router, and it says on the DS:
Warning <Code> 44002 occurred at Ping Results: link-bad, DS radio(.4)-bad, robot radio(.1)-GOOD, cRIO(.2)-GOOD, FMS-bad Driver Station
we tried to switch it to 5GHz instead of 2.4 in the radio but we couldn’t do that (the computer didn’t find the 5GHz rauter).
When we connect it with Ethernet cable locally it said on the DS:
link-GOOD, DS radio(.4)-bad, robot radio(.1)-bad, cRIO(.2)-GOOD, FMS-bad Driver Station
When we ran the simple robot template it almost always run, but when we add complex stuff such as gyro, PID turning, and SmartDashboard values the following error appears in the DS Diagnostics messages:
ERROR: A timeout has been exceeded: RobotDrive... Output not updated often enough. ...in Check() in C:/WindRiver/workspace/WPILib/MotorSafetyHelper.cpp at line 117
We tried to eliminate some of the complex code and sometimes it worked sometimes not. When we rebooted the cRio / the whole robot it more likely didn’t appear again for the next severals debugs but then when we added new code for example, it happened again.
We think that it happens before the constructor of the RobotDemo when in the constructor the RobotDrive [we added there 4 talons, in the constructor we wrote: myRobot(talon1, talon2, talon3, talon4) – where each talon constructed by: talon1(1).] - this is because when we added SetSafteyEnabled to false in the constructor and in the operator control, the problem still appeared, and we couldn’t reach to the main code in the while loop.
We raised some stuff that could make this problem like not very good communication (but it also happened when we connected it locally with Ethernet), smartdashboard slowing the code, or maybe wrong