-
Notifications
You must be signed in to change notification settings - Fork 4
Setup
Noah Zemlin edited this page Apr 4, 2020
·
5 revisions
If you have any issues, please check the FAQ. If you cannot find your issue there, feel free to message me on Slack or Discord or ask the #software-challenge
channel!
-
For this challenge, you must use ROS Melodic. It is recommended to install it on Ubuntu 18 either by dual-booting your system or using Windows Subsystem for Linux (WSL). Follow the steps here: http://wiki.ros.org/melodic/Installation/Ubuntu.
-
The rest of this setup will assume you understand basic ROS. You can brush up by reading the tutorials here: http://wiki.ros.org/ROS/Tutorials
-
Once you have ROS Melodic installed, install ROS Bridge by running
sudo apt install ros-melodic-rosbridge-server
- Fork and clone the latest version of this repo to wherever you would like inside your Ubuntu file system. You can delete the Unity folder as you won't need it.
- Test that the example workspace compiles by running
catkin_make
insideswc_ws
- Explore the example code in
swc_ws
and also the configuration options available insimulator.cfg
andcompetition.cg
- Download the latest release of the simulator here: https://github.com/SoonerRobotics/SCR-SWC-20/releases You should choose Windows if you are using WSL, otherwise choose Linux!
- Extract the zip wherever you would like. If you are using Ubuntu, run
sudo chmod +x SCRSWC20.x86_64
to mark the simulator as an executable.
- Run the simulator. You will likely get an error saying that there was an error loading the config files. Change the root directory at the top of the simulator window to wherever the root of your cloned repo is. If you are using WSL, you can use the WSL UNC path. For example
\\wsl$\Ubuntu-18.04\home\<user>\SCR-SWC-20
would work if you cloned the repo into your user directory. - If it was able to read the config file, it should now say it is waiting for ROS Bridge
- To connect the simulator to your ROS code, all you have to do is launch the rosbridge_websocket along with your code. An example of this is the
swc_example.launch
launch file inswc_ws/swc_example/launch
. - As soon as you launch the rosbridge_websocket, the simulator will connect to ROS and the simulation should begin!