Currently Under Construction
Getting Started with Eclipse for RoboRIO
The following set of instructions is to help you get ready to download code to a RoboRIO robot controller
Installing the required software
- Download Eclipse (Windows Download, others available at eclipse.org)
- After the download is complete, extract the compressed folder to somewhere safe, like the desktop or the Program Files folder on your computer.
- Eclipse doesn't need to be installed, you can open the folder and double click the application to run it NOTE: Sometimes, you won't have the Java Development Kit installed and Eclipse won't open because of this, you can download it here. Make sure you get the one for your Operating System.
- Eclipse will ask about what workspace you want to use, this is where your projects will be stored, you can change this if you like, otherwise, the default is at (On PC) C:\Users\"username"\workspace. Click Ok to move on
- Once Eclipse is open, click Help > Install New Software. . .
- We need to add the software download website for FRC to Eclipse, to do this, click Add then in the Name field type FRC Plugins, and in the Location field type this exactly: http://first.wpi.edu/FRC/roborio/release/eclipse/ then click Ok
- Under the "Work with. . ." dropdown, select the FRC Plugins software site, and you should see WPILib Robot Development pop up below, click the arrow to the left of the name and then check the Robot Java Development checkbox.
- Then click Next > Next > Accept License Agreement(Radio Button) > Finish
- When the security warning appears, just click Ok. The installation will begin immediately
- When Eclipse asks if it's ok to restart click Yes
Now you're ready to create your first FRC Java project for the RoboRIO
Setting your Team Number
(On PC) Window > Preferences > WPILib Preferences > Enter Your Team Number > Apply > Ok
Creating your first FRC Java Project for RoboRIO
- Open Eclipse
- Click File > New > Project. . .
- Click WPILib Robot Java Development > Robot Java Project > Next
- Give the project and name, select Sample Robot
- Click Finish
- In Package Explorer, click the arrow to the left of your Project Name > then the arrow next to src > then the arrow next to org.usfirst.frc.team####.robot > Double Click Robot.Java
- You should now see the sample code and can develop your own when you're ready
Downloading Code to Your RoboRIO
- Right click your project name
- Go to Run As. . .
- Click WPI Java Deploy
- The Console will appear, and will let you know of errors or if your download was successful
Getting Started with Netbeans for cRIO
The following set of instructions is to help one get ready to download code to a cRio robot controller.
Installing the required software
- Download:
a.) Netbeans (Get the JavaSE version)
b.) FRC Java Plugins for Netbeans - Now that you've downloaded the items you need, you can install Netbeans
- Earlier you downloaded a zip archive (NetBeansPlugins20130105v407.zip), locate it and extract its content somewhere you can remember.
- Open Netbeans, once its installed (It may take a while depending on your computer.)
- go to: Tools > Plugins > Downloaded (tab)> Add Plugins (button)
- Locate the plugins you extracted in step 3. add them all to the install list.
- Press the Install button
- You may get a message or messages saying that the plugins aren't signed, just next through those and agree to the licence terms.
Now you are ready to create your first FRC Java project for the cRIO
Setting your Team Number
(On PC) Tools > options > Miscellaneous(tab) > FRC Configuration(tab) > Enter your team Number
Creating your first FRC Java Project for cRIO
- Open Netbeans
- File > New Project
- FRC Java (If Missing makes sure you followed the Installing the Required software section above.)
- Choose SimpleRobotTemplateProject
- All the fields are fairly straightforward, with a few exceptions:
a. You should change the name of the project.
b. I would recommend also changing the project package to: edu.teamxxyy (xxyy is your team number)
c. Robot Class: MyRobot (You can use a different name.)
NOTE: if you are importing someone else's code, you will need to change the Robot Class field to whatever they called it, you can find it in the code as the part of the opening statment, something like "public class LunacyBot". In that case, Robot Class would be LunacyBot. - Click the Finish button. Netbeans will now create your robot project.
- On the left side of your screen you should see the project you just created with two things under it. src and build.xml
- Click the small plus next to src
- Then the plus next to edu.team2648
- Now you should see MyRobot.java : Double click it (Open for editing)
- You should now see the default code that is provided for you as a basis for simple robot projects.
- Now you can begin developing your code.
Downloading code
So you are ready to download your code to your cRio and test it out!
- Right click on the project you wish to download to your robot
- Choose Set as Main Project
- Make sure your Robot is turned on and connected to your computer with an Ethernet cable.
- Your computer will need to have an IP address on the same subnet as your robot. (ie. 10.26.48.5) Directions
- If there were no problems with the download you should see an output window that says Build Successfull
Troubleshooting
As with any complex task there are many hundreds of thousands of things that could go wrong. One idea is to ask the intelligent people on Chief Delphi or on the FiIRST Forums.