Download Eclipse JAVA tutorial: Requirements:

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
no text concepts found
Transcript
Eclipse JAVA tutorial:
Requirements:
-
Eclipse IDE for Java Developers
SynthesisLibs.jar
X64 .dll
If you have a robot project already, skip to step 5 and be sure to put your robot code into a Java Project
NOT Robot Project.
Process:
1. Open Eclipse and make sure that your version of Java is higher than SE 1.6.
Creating new robot:
2. Go to File -> New -> Java Project
3. Right click on the SRC folder and go to New -> Class (this will be your main robot class, you can
import or drag and drop if you wish OR you can use our sample robot code)
4. Now that you have the robot class you must add a specific line to Simulate the robot.
public static void main(String[] args){
EmulatorControl.start(TEAMNUMBER, Robot.class);
}
Adding the libraries (new project or current one):
5. Right click your project name and click Properties
6. Navigate to Java build path (1) and then to Libraries (2) and finally select Add External JARs…
(3)
2.
1.
3.
7. Find SynthesisLibs.jar in your installation folder under ….
Adding the natives:
8. Right click on the SynthesisLibs.jar file you just imported and navigate to Properties.
9. Now Navigate to the Native Library tab and find the folders that contain your X64 bit FPGA.dll
AND FPGA.lib files which are contained within (InstallationPath)/SynthesisDrive/dll.
1.
2.
10. Now right click on the project and select Run -> Java Application
11. Now plug in joysticks and either run your java application or run the application with Driver
Synthesis using the Driver Synthesis tutorial!
Note:
Please do not use anything with a port number of 0:
Ex:
Joystick doesntwork = new Joystick(0);
Joystick works = new Joystick(1);
Please for now refrain from using any CAN controller, you can change these settings while using the
robot compiler:
Ex:
CANTalon doesntwork = new CANTalon(0);
Talon work = new Talon(0);