Log in

View Full Version : UncleanStatusException: -1


AllenGregoryIV
05-02-2011, 13:39
My team just started playing with CAN in Java and now we are getting this error after we hooked everything up.

edu.wpi.first.wpilibj.util.UncleanStatusException: Fatal status code detected: -1

I have searched but I haven't been able to find other people getting the -1 error.

We have addressed all the Jaguars with BDC-COMM and are able to see all 4 Jaguars when they are on the bus with BDC-COMM. We have doubled checked that they all have updated firmware.

I have been able to find that is this error
/// DMA to the FPGA target is not supported by the controller associated with the FPGA (e.g. cRIO-9002/4).
public static final int kRioStatusDmaOutputNotSupported = kRioStatusOffset - 1;
But I have no idea how to go about fixing it.

We have tried reimaging the cRIO and reset it multiple times.

We also went and used the sample code from here in case our code wasn't running properly but we are still getting the same error.
http://norwellrobotics.com/papers/canbus.html

Thank you for any help you can provide,
Allen Gregory
Team 2587

alexhenning
05-02-2011, 20:16
I haven't seen this error.. If all of the jaguars work with BDC-COMM, then it's probably safe to assume that the jaguars and cables are right. The problem is likely the CRIO or something with the software.

1. Are you running the latest version of WPIlib? (aka is the Eclipse or Netbeans plugin up to date?)
2. Is the CRIO imaged to version 27? (as opposed to version 25)
3. Is the Console pin on the CRIO on? It should be off.

See if that helps, I'll see if I can find anything else that might be helpful. Good luck.

AllenGregoryIV
05-02-2011, 23:38
Thanks for the advice.

1. Yes we updated the Netbeans plugins

2. Yes we updated the cRIO to the release that just happened this week.

3. yes the console out pin is set to off

So we have tried everything I can think of, has anyone else had this problem with the latest Java updates? I would really love to get this working so we don't have to run our own velocity controllers on the cRIO, I would rather only do the tuning once and not have to redo it once we get CAN working.

alexhenning
07-02-2011, 22:03
Sorry, I haven't had a chance look at all today, but two more ideas. Do you have a second CRIO or a nearby team willing to let you borrow a spare CRIO? We had networking issues with one CRIO last year, but everything worked fine on another.

Along the same lines can you flash it with a non-CAN image and and print to the serial port and read that in? Does it give you what you print or gibberish? If it gives you gibberish, then it's probably an issue with the CRIO's serial port.

Hopefully someone else can provide more help.

jhersh
08-02-2011, 03:05
I'm afraid that -1 is not really referring to the DMA error that you referenced since the error you reference is "kRioStatusOffset - 1" where kRioStatusOffset != 0. It is probably an error code that was never created. Are you using the 2CAN or the Black Jag Bridge?

-Joe

AllenGregoryIV
08-02-2011, 09:55
Thanks Joe,

We are using the Black Jag Bridge. And I'm relived that it is the wrong error code because I was really unsure of how to fix that problem.

Here is the full error
[cRIO] Default IterativeRobot.disabledContinuous() method... Overload me!
[cRIO] edu.wpi.first.wpilibj.util.UncleanStatusException: Fatal status code detected: -1
[cRIO] at edu.wpi.first.wpilibj.can.CANExceptionFactory.chec kStatus(CANExceptionFactory.java:46)
[cRIO] at edu.wpi.first.wpilibj.can.JaguarCANDriver.sendMess age(JaguarCANDriver.java:29)
[cRIO] at edu.wpi.first.wpilibj.CANJaguar.sendMessage(CANJag uar.java:567)
[cRIO] at edu.wpi.first.wpilibj.CANJaguar.updateSyncGroup(CA NJaguar.java:1342)
[cRIO] at edu.wpi.first.wpilibj.RobotDrive.setLeftRightMotor Outputs(RobotDrive.java:527)
[cRIO] at edu.wpi.first.wpilibj.RobotDrive.arcadeDrive(Robot Drive.java:372)
[cRIO] at edu.wpi.first.wpilibj.RobotDrive.arcadeDrive(Robot Drive.java:382)
[cRIO] at Breakaway.Main.teleopPeriodic(Main.java:117)
[cRIO] at edu.wpi.first.wpilibj.IterativeRobot.startCompetit ion(IterativeRobot.java:141)
[cRIO] at edu.wpi.first.wpilibj.RobotBase.startApp(RobotBase .java:154)
[cRIO] in virtual method #10 of javax.microedition.midlet.MIDlet(bci=17)
[cRIO] at javax.microedition.midlet.MIDletTunnelImpl.callSta rtApp(64)
[cRIO] at com.sun.squawk.imp.MIDletMainWrapper.main(110)
[cRIO] in virtual method #95 of com.sun.squawk.Klass(bci=25)
[cRIO] at com.sun.squawk.Isolate.run(1506)
[cRIO] at java.lang.Thread.run(231)
[cRIO] in virtual method #47 of com.sun.squawk.VMThread(bci=42)
[cRIO] in static method #3 of com.sun.squawk.VM(bci=6)
[cRIO] WARNING: Robots don't quit!
[cRIO] ---> The startCompetition() method (or methods called by it) should have handled the exception above.

I hope this is something simple that we have just missed.

AllenGregoryIV
11-02-2011, 11:25
Has anyone else had this problem?

I haven't been able to get access to another cRIO to test it?

jhersh
11-02-2011, 17:37
Thanks Joe,

We are using the Black Jag Bridge. And I'm relived that it is the wrong error code because I was really unsure of how to fix that problem.

Here is the full error


I hope this is something simple that we have just missed.

Please enable the NetConsole and post a log of what you see there. Selecting the text will add it to the clipboard. Triple clicking will select all the text.

-Joe

devodl
25-02-2012, 19:43
We encountered this problem and resolved it by changing the cRIO II virtual DIP switches to off. Specifically the CONSOLE OUT switch had to be off.

This is changed by using the cRIO Imaging Tool