Troubleshooting Hardware

cancel
Showing results for 
Search instead for 
Did you mean: 

RoboRIO version 2 not connecting to Driver Station, Phoenix Tuner v1 or v2

Solved!
Go to solution

Hello and Happy New Year,

 

I have a RoboRIO version 2 that has an SD card flashed with the latest version of FRC 2023 image downloaded couple of days ago from here (NI website). This RoboRIO is brand new device - was never installed on a robot, never been in a competition. It does boot correctly, I am able to deploy (any) robot code to it, Phoenix Tuner v1 (1.9.x) and Phoenix Tuner X (v2) can deploy the diagnostic tools and then it sees the devices on the CANbus just fine, uploads firmware and can manage them just fine. I can SSH/FTP into the device, either via the USB ethernet 172.22.11.2 or Ethernet 10.0.20.2 (fixed IP). I can ping the RoboRIO by either IP address 172.22.11.2 or 10.0.20.2 as well.

 

However, when launching the Driver Station it reports no connectivity, no robot code. The team number (20) is setup correctly in the driver station, it reports correctly the IP addresses it sees on the status page (10.0.20.2). Students reported this behaviour in the past months and I tested it myself as well. Sometimes it works, sometimes it doesn't very erratic behaviour. We tested many different SD cards, SanDisk 8GB Industrial is what we purchased as recommended for RoboRIO v2.  Attached is the code I am deploying to the RoboRIO as a test. 

The same code works fine on a RoboRIO version 1, has no issues connecting to Driver Station.


Any help will be greatly appreciated.

All the best,
-- Mr. Catalin Ghercoias
Team 20 Electrical Mentor
Shenendehowa High School
Clifton Park, NY

 

 

0 Kudos
Message 1 of 18
(3,492 Views)

Hello Mr. G,

 

Thanks for posting on the forums. I'm Matthew with NI.

 

If you boot the roboRIO 2 into safe mode (https://docs.wpilib.org/en/stable/docs/software/roborio-info/recovering-a-roborio-using-safe-mode.ht...), the code won't run, but does the Driver Station report that it's able to communicate then?

0 Kudos
Message 2 of 18
(3,473 Views)

Hello Matthew,

 

Is there a limit on the posts? I posted, twice, a really long post showing what I have done so far, but none of it appeared in the forum

0 Kudos
Message 3 of 18
(3,440 Views)

Hello Matthew and thank you for your fast reply.

 

I followed the procedure outlined in the link you sent, although it says "These steps are not applicable to the roboRIO 2. Reimaging the SD card following roboRIO 2.0 microSD card imaging process will fully reformat the device" . The roboRIO status light started blinking continuously.

The Driver Station did not connect to it.

 

One thing I noticed was, when I SSH'd into the Rio was that the CLI had this -- admin@roboRIO-0000-FRC:~# (which is very odd); I know it should be admin@roboRIO-20-FRC:~#  or similar -- our team number must be in the hostname.

 

I tried several times to deploy the code with the team 20 configured in the code, made sure it is in the code. The code deployed successfully every time, but the driver station would not connect. 

 

 

I followed this link https://docs.wpilib.org/en/stable/docs/zero-to-robot/step-3/roborio2-imaging.html  and all the way to the bottom of the page, were the instructions on how to configure the team number.  I cannot format the target from the "FRC roboRIO imaging tool", but I can edit Startup Settings.

 

I think this message -- The image writing process above does not set a team number. --  should be posted as an !Important! message on that webpage.

 


 
Updating Media

 

 

0 Kudos
Message 4 of 18
(3,436 Views)

Continued....

 

Now the Driver Station connects to the roboRIO, however, as it can be seen from the screenshot below it reports - No Robot Code. Even though, there are messages scrolling up in the console that it cannot find the TalonFX, CANcoders, etc.

MrGTeam20_0-1673557462024.png

 

The following roboRIO lights are lit - Power(orange), COMM (red), RSL(orange).

 

I did re-image the SD card and lost the team number, the CLI was showing admin@roboRIO-0000-FRC:~#

MrGTeam20_1-1673557462070.png

 

 

 

This is not trivial, students do not know this (I didn't know this), typically they  - image the SD card, push the code from VScode and the robot will work - like it was with roboRIO version 1. This situation is especially dangerous in a competition if for any reason they decide to re-image an SD card or swap them with another.

 

After I set the team number again, pushed the code, and different code (again), the same results - but now at least it connects to Driver Station,  that's a success.

MrGTeam20_2-1673557462296.png

 

 

0 Kudos
Message 5 of 18
(3,434 Views)

Ok, so to recap where we're at so far -> you're able to image the SD card and then use the utility to set the team number.

 

At this point, Driver Station reports that it can communicate, but it is not detecting code is running even after deploying code again?

 

You mentioned VSCode, I'm guessing you're not using LabVIEW, what language are you using?

0 Kudos
Message 6 of 18
(3,422 Views)

Yes, we are using VScode, programming in Java. 

The code is running on the roboRIO as it can be seen in the console, but the driver station reports 'no robot code' which is odd. The same exact code runs fine on a roboRIO version 1. 

0 Kudos
Message 7 of 18
(3,419 Views)

Since the roboRIO is reporting to dashboard, I suspect it is operating correctly.

To confirm, it is no longer in safe mode? (only the essential processes are executed in safe mode)

 

Can you try generating a fresh project from Robot Builder with no extras and see if that reports it is running?

0 Kudos
Message 8 of 18
(3,410 Views)

The roboRIO is not in safe mode anymore. I did put in safe mode as you asked earlier, nothing happened, could not connect the driver station to it. It just sat there with the status led blinking orange continuously. I did load another sample code (Tank Drive with CAN - attached) from REV Robotics (https://github.com/REVrobotics/SPARK-MAX-Examples) that we use to test motors. Its been working flawlessly on roboRIO version 1. The same behavior, 'communications' indicator is green in driver station, red on the roborio.

'No robot code' indicator is red on driver station and 'joysticks' is green. 

 

Do you have a piece of code you want me to test?

I can attach an FTDI to the RS232 port and try to run some commands while in safe mode, if the serial console is brought up during safe mode. 

0 Kudos
Message 9 of 18
(3,407 Views)

Matt, 

 

I re-formatted/re-imaged the SD card. Went through the process of setting the Team 20 number using the FRC roboRIO Image tool, erased everything in VSCode, all caches, all files. Deployed again the Tank Drive code to the roboRIO and now all lights/LEDs are green.

 

And it does work, it can control the motors. I can query and deploy firmware to CTR devices using both Phoenix Tuner v1 (old) and Phoenix Tuner X (new).

In other words it works as expected. However, this is the behaviour was exhibiting in the past, according to the students. Sometimes, after they were deploying the code it will stop working.

 

We do have another roboRIO version 2 which was used on the 2022 robot at competitions, and that one never had these issues.

 

Is there a way, a procedure, process that we can do to thoroughly test this specific roboRIO, or do we have to send/RMA it to you? 

In all honesty, I cannot ask the students to install this roboRIO in a competition robot, when its behaviour is not consistent every single time as it should be.

 

Thank you - Mr. G.

0 Kudos
Message 10 of 18
(3,389 Views)