|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools |
Rating:
|
Display Modes |
|
|
|
#1
|
|||
|
|||
|
New Robot programmers. Trouble deploying
I'll get straight to the point because short posts are good.
We got a new programming labtop that wasn't cluttered with four years of FIRST Software. We imaged the cRIO with the 2014 zip and have been trying to deploy the Iterative Robot code I wrote for the robot. However, we are having an issue with the deployment. After the cRIO is rebooted and everything thing is done, I get this error ... [cRIO] Welcome to LabVIEW Real-Time 13.0 [cRIO] task 0x187b4f0 (sysapi-rpc) deleted: errno=0 (0) status=0 (0) [cRIO] [cRIO] [Squawk VM] Version: 2011 FRC, Nov 5 2011, 14:34:13 [cRIO] FPGA Hardware GUID: 0x1394f6dc1feb42ec6910e5767ed1d22c [cRIO] FPGA Software GUID: 0xa14c11bde4bb64aef6a86fc52a294cd9 [cRIO] java.lang.IllegalArgumentException: no ':' in URI ... [cRIO] WARNING: Robots don't quit! [cRIO] ---> The startCompetition() method (or methods called by it) should have handled the exception above. Here's the full stack of text in the console output for your perusal Code:
ant -f C:\\Users\\Robotics\\Documents\\NetBeansProjects\\PreliminaryBot deploy run
clean:
Deleting directory C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build
Created dir: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build
Created dir: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\classes
[crio-compile] ./src, C:/Users/Robotics/sunspotfrcsdk\lib\wpilibj.jar;C:/Users/Robotics/sunspotfrcsdk\lib\networktables-crio.jar, C:/Users/Robotics/sunspotfrcsdk\lib\squawk.jar -> ./build/classes
Compiling 10 source files to C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\classes
compile:
preverify:
Created dir: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\preverify
Created dir: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\preverify.raw.util
[crio-preverify] ./build/classes, , C:/Users/Robotics/sunspotfrcsdk\lib\wpilibj.jar;C:/Users/Robotics/sunspotfrcsdk\lib\networktables-crio.jar, C:/Users/Robotics/sunspotfrcsdk\lib\squawk.jar -> ./build/preverify
Expanding: C:\Users\Robotics\sunspotfrcsdk\lib\wpilibj.jar into C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\preverify
Expanding: C:\Users\Robotics\sunspotfrcsdk\lib\networktables-crio.jar into C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\preverify
jar:
[crio-jar] ./build/preverify, ./resources -> ./build/app.jar
Building jar: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\app.jar
suite:
Created dir: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\suite
[crio-suite] ./build/app.jar -> ./build/suite/image
CompilerOracle: exclude com/sun/squawk/Method.getParameterTypes
CompilerOracle: exclude com/sun/squawk/SymbolParser.getSignatureTypeAt
CompilerOracle: exclude com/sun/squawk/SymbolParser.stripMethods
[translating suite image [closed: false, parent: squawk] ...]
### Excluding compile: com.sun.squawk.Method::getParameterTypes
### Excluding compile: com.sun.squawk.SymbolParser::getSignatureTypeAt
[Including resource: META-INF/MANIFEST.MF]
[Including resource: META-INF/maven/edu.wpi.first.wpilib.networktables.java/NetworkTablesAzalea/pom.properties]
[Including resource: META-INF/maven/edu.wpi.first.wpilib.networktables.java/NetworkTablesAzalea/pom.xml]
Romizer processed 397 classes and generated 4 files.
Expanding: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\app.jar into C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\suite
Moving 1 file to C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\suite
Moving 1 file to C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\suite
Moving 1 file to C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\build\suite
Deleting: C:\Users\Robotics\Documents\NetBeansProjects\PreliminaryBot\image.suite.api
deploy:
[crio-configure] Configuration files not included in this version of the sdk
[crio-configure] Checking that crio is configured for Java
Host OS: Windows 7 6.1, 6.1
Host JVM: Java HotSpot(TM) 64-Bit Server VM 24.51-b03
Target IP: 10.27.85.2
Network interfaces on host:
Intel(R) 82577LM Gigabit Network Connection: address: 10.27.85.5 netmask: 255.0.0.0 <--- on robot's subnet
Connecting FTP @10.27.85.2
[crio-deploy] ./build/suite/image.suite -> 10.27.85.2
Sending local file image.suite
run:
[cRIO] [OTA Server] ********* REBOOTING cRIO *********
[cRIO]
Waiting for cRIO to reboot (1s)
Waiting for cRIO to reboot (2s)
Waiting for cRIO to reboot (3s)
Waiting for cRIO to reboot (4s)
Waiting for cRIO to reboot (5s)
Waiting for cRIO to reboot (6s)
Waiting for cRIO to reboot (7s)
Waiting for cRIO to reboot (8s)
Waiting for cRIO to reboot (9s)
Waiting for cRIO to reboot (10s)
Waiting for cRIO to reboot (11s)
[cRIO]
[cRIO] -> * Loading debug.o: debug
[cRIO] Debugging is up, target server mounted at /tsfs
[cRIO]
[cRIO]
[cRIO] VxWorks
[cRIO]
[cRIO] Copyright 1984-2006 Wind River Systems, Inc.
[cRIO]
[cRIO] CPU: cRIO-FRC II
[cRIO] Runtime Name: VxWorks
[cRIO] Runtime Version: 6.3
[cRIO] BSP version: 1.0/0
[cRIO] Created: May 23 2013, 16:00:09
[cRIO] ED&R Policy Mode: Deployed
[cRIO] WDB Comm Type: WDB_COMM_END
[cRIO] WDB: Ready.
[cRIO]
[cRIO] * Loading nisysrpc.out: nisysrpc
[cRIO] * Loading NiRioRpc.out: NiRioRpc
[cRIO] task 0x18a30c8 (VISA Jungo Init Thread) deleted: errno=196709 (0x30065) status=-1073807360 (0xbfff0000)
[cRIO] * Loading nivissvc.out: nivissvc
[cRIO] * Loading nivision.out: nivision
[cRIO] task 0x1a15c18 (Service Locator Thread 5) deleted: errno=0 (0) status=0 (0)
[cRIO] NI-RIO Server 13.0 started successfully.
[cRIO] task 0x1760a90 (NiRioRpc) deleted: errno=0 (0) status=0 (0)
[cRIO] task 0x1a1ef40 (Service Locator Thread 6) deleted: errno=0 (0) status=0 (0)
[cRIO] task 0x1a1ef40 (Service Locator Thread 7) deleted: errno=0 (0) status=0 (0)
[cRIO] task 0x1a1ef40 (Service Locator Thread 8) deleted: errno=0 (0) status=0 (0)
[cRIO] task 0x165c448 (nisysapi-mDns) deleted: errno=0 (0) status=0 (0)
[cRIO] * Loading visa32.out: visa32
[cRIO] * Loading niserial.out: niserial
[cRIO] * Loading NiFpgaLv.out: NiFpgaLv
[cRIO] * Loading FRC_FPGA_ChipObject.out: FRC_FPGA_ChipObject
[cRIO] * Loading FRC_NetworkCommunication.out: FRC_NetworkCommunication
[cRIO] FRC_NetworkCommunication version: p4-1.4.0a18
[cRIO] FPGA Hardware GUID: 0x1394F6DC1FEB42EC6910E5767ED1D22C
[cRIO] FPGA Software GUID: 0x1394F6DC1FEB42EC6910E5767ED1D22C
[cRIO] FPGA Hardware Version: 2012
[cRIO] FPGA Software Version: 2012
[cRIO] FPGA Hardware Revision: 1.6.4
[cRIO] FPGA Software Revision: 1.6.4
[cRIO] * Loading FRC_JavaVM.out: FRC_JavaVM
[cRIO]
[cRIO]
[cRIO] [OTA Server] Version: 2012 FRC, Jan 5 2012, 17:20:48
[cRIO]
[cRIO]
[cRIO] Welcome to LabVIEW Real-Time 13.0
[cRIO] task 0x187b4f0 (sysapi-rpc) deleted: errno=0 (0) status=0 (0)
[cRIO]
[cRIO] [Squawk VM] Version: 2011 FRC, Nov 5 2011, 14:34:13
[cRIO] FPGA Hardware GUID: 0x1394f6dc1feb42ec6910e5767ed1d22c
[cRIO] FPGA Software GUID: 0xa14c11bde4bb64aef6a86fc52a294cd9
[cRIO] java.lang.IllegalArgumentException: no ':' in URI
[cRIO] at javax.microedition.io.Connector.open(221)
[cRIO] at javax.microedition.io.Connector.open(193)
[cRIO] at javax.microedition.io.Connector.openDataOutputStream(400)
[cRIO] at javax.microedition.io.Connector.openOutputStream(354)
[cRIO] at edu.wpi.first.wpilibj.templates.DataLogger.<init>(DataLogger.java:25)
[cRIO] at edu.wpi.first.wpilibj.templates.AerialAssist.robotInit(AerialAssist.java:84)
[cRIO] at edu.wpi.first.wpilibj.IterativeRobot.startCompetition(IterativeRobot.java:72)
[cRIO] at edu.wpi.first.wpilibj.RobotBase.startApp(RobotBase.java:235)
[cRIO] in virtual method #10 of javax.microedition.midlet.MIDlet(bci=17)
[cRIO] at javax.microedition.midlet.MIDletTunnelImpl.callStartApp(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.
Any help is appreciated. Thanks in advance. |
|
#2
|
|||
|
|||
|
Re: New Robot programmers. Trouble deploying
The stack trace in the console output you posted is trying to point you to the issue.
Quote:
|
|
#3
|
|||
|
|||
|
Re: New Robot programmers. Trouble deploying
This isn't the exact code from the robot, but majority of it is the same.
This is from my computer, so its the closest thing I have to it. Only differences should be some variable names AerialAssist IterativeRobot Class: Line 84 is commented and put in red font Code:
public class PreWinter extends IterativeRobot {
private Command autonomousCommand;
private Joystick theJoystick = new JoystickOne( RobotMap.PORT, RobotMap.NUM_AXES, RobotMap.NUM_BUTTONS );
private MecanumDrive chassis;
/*
* This sets global variables that can be manipulated in order to make use
* of the joystick. The three "~ValueError" variables calibrate the initial
* settings of the joystick.
*/
private double xValueError;
private double yValueError;
private double twistValueError;
private double xValue;
private double yValue;
private double twistValue;
/*
* Timer Variables
*/
private Timer whatTime;
private double cToField;
private double autonomousStart;
private double teleOpStart;
private double lastTimeWritten;
/*
* Misc. Variables
*/
private DataLogger collectData;
private final String FILE_NAME = new String("PrewinterRobotData");
private DriverStation driverStation;
/**
* This function is run when the robot is first started up and should be
* used for any initialization code.
*/
public void robotInit() {
/*
* Creates initial objects
*/
whatTime = new Timer();
whatTime.start();
lastTimeWritten = whatTime.get();
//line 84
collectData = new DataLogger(FILE_NAME);
driverStation = DriverStation.getInstance();
/*
* Finds the beginning values of X and Y in order to calculate any error
* values the joystick may have.
*/
xValueError = theJoystick.getAxis(Joystick.AxisType.kX);
yValueError = theJoystick.getAxis(Joystick.AxisType.kY);
twistValueError = theJoystick.getAxis(Joystick.AxisType.kTwist);
// instantiate the command used for the autonomous period
autonomousCommand = new AutonomousCommand();
// Initialize all subsystems
chassis = new MecanumDrive();
chassis.initDefaultCommand();
CommandBase.init();
}
/*
* Runs once after the robot connects to the field
*/
public void disabledInit() {
cToField = whatTime.get();
collectData.nextLine("Joystick X-Error: " + xValueError);
collectData.nextLine("Joystick Y-Error: " + yValueError);
collectData.nextLine("Joystick Twist-Error: " + twistValueError);
}
/*
* Runs periodically as the robot is connected to the field
*/
public void disabledPeriodic() {
collectSomeData();
}
/*
* Runs once at the start of the autonomous period begins
*/
public void autonomousInit() {
// schedule the autonomous command (example)
autonomousCommand.start();
autonomousStart = whatTime.get();
}
/**
* Runs periodically as the robot is running through autonomous mode
*/
public void autonomousPeriodic() {
Scheduler.getInstance().run();
collectSomeData();
}
/*
* Runs once at the start of the teleop period
*/
public void teleopInit() {
// This makes sure that the autonomous stops running when
// teleop starts running. If you want the autonomous to
// continue until interrupted by another command, remove
// this line or comment it out.
autonomousCommand.cancel();
teleOpStart = whatTime.get();
}
/**
* This function is called periodically during operator control
*/
public void teleopPeriodic() {
Scheduler.getInstance().run();
/*
* Finds the values of the joystick. Calibrates the x, y, and twist values
* based on the initial configuration
*/
xValue = theJoystick.getAxis(Joystick.AxisType.kX) - xValueError;
yValue = theJoystick.getAxis(Joystick.AxisType.kY) - yValueError;
twistValue = theJoystick.getAxis(Joystick.AxisType.kTwist) - twistValueError;
/*
* Moves and twists the robot
*/
if(Math.abs(xValue) > RobotMap.ERROR_BOUND || Math.abs(yValue) > RobotMap.ERROR_BOUND )
chassis.getDrivetrain().mecanumDrive_Cartesian( xValue - xValueError, yValue - yValueError, 0, 0 );
if(Math.abs(twistValue) > RobotMap.ERROR_BOUND)
chassis.getDrivetrain().mecanumDrive_Cartesian( 0, 0, twistValue - twistValueError, 0);
collectSomeData();
}
/**
* This function is called periodically during test mode
*/
public void testPeriodic() {
LiveWindow.run();
}
public void collectSomeData() {
if(whatTime.get() - lastTimeWritten > 100) {
collectData.nextLine("Battery Voltage: " + driverStation.getBatteryVoltage());
collectData.nextLine("Joystick X-Value: " + xValue);
collectData.nextLine("Joystick Y-Value: " + yValue);
collectData.nextLine("Joystick Twist-Value: " + twistValue);
lastTimeWritten = whatTime.get();
}
}
}
Code:
package edu.wpi.first.wpilibj.templates;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintStream;
import javax.microedition.io.Connector;
/**
* Datalogger class. prints data to file
* @author Justin S. and Jeremy G.
*/
public class DataLogger {
private PrintStream out = null;
private boolean enabled = false;
public DataLogger(String filename) {
try {
OutputStream os = Connector.openOutputStream(filename);
out = new PrintStream(os);
enabled = true;
} catch (IOException ioe) {
ioe.printStackTrace();
}
}
/**
* Prints a string to file
* @param s
*/
public void sameLine(String s) {
if (enabled) {
out.print(s);
out.flush();
}
}
/**
* Prints a string to file, appends with a newline char
* @param s
*/
public void nextLine(String s) {
if (enabled) {
out.println(s);
out.flush();
}
}
}
|
|
#4
|
|||
|
|||
|
Re: New Robot programmers. Trouble deploying
The issue appears to be in your use of:
Code:
Connector.openOutputStream(filename); I'm not familiar with the Connector class you are using, but you could try changing your filename value to: "file:///PrewinterRobotData" (a URI which specifies a file on the cRIO file system). NOTE: If this works, you will need to ftp to your cRIO to download the file when you want to look at it's contents. Hope that helps, Paul |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|