Documentation Updates

- Add page links at the top of each website page
- Add link to draft video to home.md
- Fix links that don't point to files in the docs folder to point to file in GitHub repo
- Add instructions for using run_all.sh script to gear.md
- Add documentation.md to describe file structure and what each of the files are for
This commit is contained in:
Sravan Balaji
2020-04-27 12:35:02 -04:00
parent 271222645d
commit 1490e427bd
3 changed files with 159 additions and 32 deletions

View File

@@ -1,30 +1,44 @@
# GEAR Simulation
# GEAR Simulation <!-- omit in toc -->
## Page Links <!-- omit in toc -->
- [Home](home.md)
- [Documentation](documentation.md)
- [GEAR](gear.md)
## Table of Contents <!-- omit in toc -->
- [Running GEAR Container](#running-gear-container)
- [Building & Running Simulation](#building--running-simulation)
- [Controlling Sample Environment](#controlling-sample-environment)
- [Start Competition](#start-competition)
- [Controlling Arms](#controlling-arms)
- [Running Full Simulation](#running-full-simulation)
- [Manual Process for Testing](#manual-process-for-testing)
- [Semi-Automated Process](#semi-automated-process)
## Running GEAR Container
1. Go to `docker_env` folder
1. On your local system, go to `docker_env` folder
- `cd /PATH/TO/RRRobot/docker_env`
2. Start GEAR docker container
- `docker-compose run --rm gear`
## Building & Running Sample Environment
## Building & Running Simulation
1. Source ROS Setup
- `source /opt/ros/melodic/setup.bash`
<!-- 2. Go to rrrobot_ws folder in container
- `cd /app/rrrobot_ws`
3. Build package
- `catkin_make clean`
- `catkin_make`
- `catkin_make install` -->
2. Run sample environment
- `roslaunch osrf_gear sample_environment.launch`
2. Run Simulation
- Sample Environment
- `roslaunch osrf_gear sample_environment.launch`
- See [controlling sample environment](#controlling-sample-environment) for more information.
- Final Simulation
- See [running full simulation](#running-full-simulation) for more information.
## Controlling Sample Environment
While sample environment is running, open a new terminal (see tips & tricks section of [home](./home.md)) on the running docker container. The following sections provide a brief overview of the commands that can be used to control various aspects of the simulation. For a full list, check out the [ARIAC 2019 Wiki](https://bitbucket.org/osrf/ariac/wiki/2019/tutorials/gear_interface).
While sample environment is running, open a new terminal (see tips & tricks section of [home](home.md)) on the running docker container. The following sections provide a brief overview of the commands that can be used to control various aspects of the simulation. For a full list, check out the [ARIAC 2019 Wiki](https://bitbucket.org/osrf/ariac/wiki/2019/tutorials/gear_interface).
[sample_run.sh](../rrrobot_ws/src/gear/sample_run.sh) moves arm 1 over the gasket part, picks it up, moves it to AGV1's tray, drops it, and moves back to the starting position.
[sample_run.sh](https://github.com/EECS-467-W20-RRRobot-Project/RRRobot/blob/master/src/rrrobot_ws/src/rrrobot/scripts/sample_run.sh) moves arm 1 over the gasket part, picks it up, moves it to AGV1's tray, drops it, and moves back to the starting position.
### Start Competition
@@ -32,14 +46,14 @@ While sample environment is running, open a new terminal (see tips & tricks sect
### Controlling Arms
#### Gripper
#### Gripper <!-- omit in toc -->
- Turn gripper suction on
- `rosservice call /ariac/arm1/gripper/control "enable: true"`
- Turn gripper suction off
- `rosservice call /ariac/arm1/gripper/control "enable: false"`
#### Joints
#### Joints <!-- omit in toc -->
Move `arm1` over a gasket part
@@ -86,12 +100,14 @@ rostopic pub /ariac/arm1/arm/command trajectory_msgs/JointTrajectory "{joint_
## Running Full Simulation
### Terminal 1: ARIAC Environment
### Manual Process for Testing
#### Terminal 1: ARIAC Environment <!-- omit in toc -->
- `cd /app/rrrobot_ws/src/rrrobot/scripts`
- `./rrrobot_run_no_build.sh`
### Terminal 2: Build RRRobot Package & Arm Controller Node
#### Terminal 2: Build RRRobot Package & Arm Controller Node <!-- omit in toc -->
- `cd /app/rrrobot_ws`
- `catkin_make clean`
@@ -99,25 +115,38 @@ rostopic pub /ariac/arm1/arm/command trajectory_msgs/JointTrajectory "{joint_
- `source devel/setup.bash`
- `rosrun rrrobot arm_controller_node`
### Terminal 3: CV Model
#### Terminal 3: CV Model <!-- omit in toc -->
- `cd /app/rrrobot_ws/src/rrrobot/src/`
- `python3 cv_model.py`
### Terminal 4: Depth Camera Node (for getting pick up location)
#### Terminal 4: Depth Camera Node (for getting pick up location) <!-- omit in toc -->
- `cd /app/rrrobot_ws/`
- `source devel/setup.bash`
- `rosrun rrrobot depth_camera_node`
### Terminal 5: Run the main rrrobot node
#### Terminal 5: Run the main rrrobot node <!-- omit in toc -->
- `cd /app/rrrobot_ws/`
- `source devel/setup.bash`
- `rosrun rrrobot rrrobot_node`
### Terminal 6: Run the node to spawn random objects onto the conveyor belt
#### Terminal 6: Run the node to spawn random objects onto the conveyor belt <!-- omit in toc -->
- `cd /app/rrrobot_ws/`
- `source devel/setup.bash`
- `rosrun rrrobot object_spawner_node`
### Semi-Automated Process
#### Terminal 1 <!-- omit in toc -->
In terminal 1, run the script that will build all components and run the nodes. You may need to adjust the sleep times in [run_all.sh](https://github.com/EECS-467-W20-RRRobot-Project/RRRobot/blob/master/src/rrrobot_ws/run_all.sh) based on your system's performance such that there is enough time for each component to finish before proceeding.
- `cd /app/rrrobot_ws/`
- `./run_all.sh`
#### Terminal 2 <!-- omit in toc -->
When a new item is spawned after the arm drops off the previous item, the conveyor belt must be manually started again using `rosservice call /ariac/conveyor/control "power: 100"` so that the item moves to the depth camera and the process can continue. You can do this in a new terminal since terminal 1 is running all of the simulation nodes.