-
Notifications
You must be signed in to change notification settings - Fork 2
Using Eclipse IDE to develop
Martin Llofriu edited this page Feb 19, 2018
·
3 revisions
This page contains instructions on how to configure Eclipse to develop SCS.
This was last tested with Eclipse Oxygen and Oracle Java 8.
On the SCS folder, run ./scripts/setupEclipseProject.sh.
Then, import the projects in eclipse:
- Right click on the package explorer
- Import...
- General/Existing projects into workspace
- Browse - go to the SCS folder
- Unselect the projects on the deps/ folder
- Finish
Add dependencies to each project:
- Right click on the project
- Build path
- Add external archives
- Add all jars in scs/deps/
If the micronsl project does not compile once this is done, the source folder might have to be reset:
- Right click on the failing project
- Build path - configure build path
- Source
- Add folder: src
- Say yes to the option of removing the project as the source folder
The v2 branch uses maven to manage dependencies and compile.
Some initial steps must be followed to use maven with eclipse: http://www.vogella.com/tutorials/EclipseMaven/article.html
Once the maven indexes are updated, the projects can be imported:
- Right click on the project explorer
- Import...
- Maven/Existing maven projects
- select the scs folder
- Import the root scs and all dependencies
To run a model from Eclipse:
- Click on black arrow besides the green "play" button
- Run configurations
- On the left, Java Application
- Click on new (the paper sheet with a plus sign)
- Select models as project
- Input edu.usf.experiment.Experiment as the main class
- In arguments: ** -display to show the GUI ** then the usual arguments (see How to run our models) ** one example: -display multiscalemodel/src/edu/usf/ratsim/model/pathplanning/graphbased/randomwalls/virtual.xml logs/randwalls Bug1 0 ** Set the working directory to your scs folder (by pressing File System)
- Give the run configuration a name, at the top
- Click run
- Afterwards, the configuration will be available in the green play button.