Attempt to Get Run_All.sh Working

- Remove ariac_ws from docker-compose
- Update home.md to indicate that GEAR is final simulation
- Update run_all.sh with comments and add sleep between commands
This commit is contained in:
Sravan Balaji
2020-04-27 10:09:13 -04:00
parent d750b3500e
commit 5db44689b4
3 changed files with 65 additions and 17 deletions

View File

@@ -78,7 +78,6 @@ services:
# Mount gear folder on host to app folder in container # Mount gear folder on host to app folder in container
volumes: volumes:
- ../src/rrrobot_ws:/app/rrrobot_ws - ../src/rrrobot_ws:/app/rrrobot_ws
- ../src/ariac_ws:/app/ariac_ws
# Set DISPLAY variable and network mode for GUIs # Set DISPLAY variable and network mode for GUIs
environment: environment:
- DISPLAY=${IP_ADDRESS}:0.0 - DISPLAY=${IP_ADDRESS}:0.0

View File

@@ -8,8 +8,8 @@
- [Docker Compose Services](#docker-compose-services) - [Docker Compose Services](#docker-compose-services)
- [GUI Support](#gui-support) - [GUI Support](#gui-support)
- [Running Docker Containers](#running-docker-containers) - [Running Docker Containers](#running-docker-containers)
- [Gazebo Grasping Simulation](#gazebo-grasping-simulation) - [Gazebo Grasping Simulation (Testing)](#gazebo-grasping-simulation-testing)
- [GEAR Simulation](#gear-simulation) - [GEAR Simulation (Final)](#gear-simulation-final)
- [Tips & Tricks](#tips--tricks) - [Tips & Tricks](#tips--tricks)
## Contributors ## Contributors
@@ -55,15 +55,15 @@ ros-turtlesim is a container that tests whether GUI support is working. This wil
#### ros <!-- omit in toc --> #### ros <!-- omit in toc -->
ros is the production container for all ROS nodes we create. This is meant to run our final code and interface with the gazebo container for simulation. ros is a container based on the ROS Melodic docker image. This is provided for convenience, but not used for running the final simulation.
#### gazebo <!-- omit in toc --> #### gazebo <!-- omit in toc -->
Similarly to ros, gazebo is the production container for gazebo. This is meant to run our final simulation. gazebo is a container based on the Gazebo Server 9 docker image. This is provided for convenience, but not used for running the final simulation.
#### gear <!-- omit in toc --> #### gear <!-- omit in toc -->
The GEAR container includes the Gazebo Environment for Agile Robotics from the Agile Robotics for Industrial Automation Competition 2019. The GEAR container includes the Gazebo Environment for Agile Robotics from the Agile Robotics for Industrial Automation Competition 2019. This is used for running the final simulation.
### GUI Support ### GUI Support
@@ -106,7 +106,7 @@ Additionally, be sure to update the `IP_ADDRESS` variable in [.env](src/.env) wi
4. Use Docker Compose to run a service (refer to [docker-compose.yml](src/docker-compose.yml) or [Docker Compose Services](#docker-compose-services)) 4. Use Docker Compose to run a service (refer to [docker-compose.yml](src/docker-compose.yml) or [Docker Compose Services](#docker-compose-services))
- `docker-compose run --rm <service_name>` - `docker-compose run --rm <service_name>`
### Gazebo Grasping Simulation ### Gazebo Grasping Simulation (Testing)
1. Source ROS Setup 1. Source ROS Setup
- `source /opt/ros/melodic/setup.bash` - `source /opt/ros/melodic/setup.bash`
@@ -119,7 +119,7 @@ Additionally, be sure to update the `IP_ADDRESS` variable in [.env](src/.env) wi
- `gazebo /app/rrrobot_src/world/rrrobot.world` - `gazebo /app/rrrobot_src/world/rrrobot.world`
5. Run control and perception programs 5. Run control and perception programs
### GEAR Simulation ### GEAR Simulation (Final)
Instructions for working in the GEAR Simulation can be found on the [GEAR](gear.md) page. Instructions for working in the GEAR Simulation can be found on the [GEAR](gear.md) page.

View File

@@ -1,11 +1,60 @@
#/app/rrrobot_ws/src/rrrobot/scripts/rrrobot_run_no_build.sh & #!/bin/bash
# Build Workspace
cd /app/rrrobot_ws
catkin_make clean
catkin_make
source devel/setup.bash
export GAZEBO_RESOURCE_PATH=$(pwd)/world:$GAZEBO_RESOURCE_PATH
# ARIAC Environment
cd /app/rrrobot_ws/src/rrrobot/scripts
./rrrobot_run_no_build.sh &
sleep 25
rosparam set /use_sim_time true
# CV Model
cd /app/rrrobot_ws/src/rrrobot/src cd /app/rrrobot_ws/src/rrrobot/src
python3 cv_model.py & python3 cv_model.py &
cd /app/rrrobot_ws/devel/lib/rrrobot sleep 10
./rrrobot_node &
./depth_camera_node >> /dev/null & # Arm Controller Node
./object_spawner_node & cd /app/rrrobot_ws
./arm_controller_node & rosrun rrrobot arm_controller_node &
rostopic echo /arm_controller/destination & sleep 3
rostopic echo /desired_grasp_pose &
rostopic echo /cv_model & # Depth Camera Node
rosrun rrrobot depth_camera_node &
sleep 3
# RRRobot Node
rosrun rrrobot rrrobot_node &
sleep 3
# Object Spawner
rosrun rrrobot object_spawner_node &
sleep 3
# Start Competition
source /opt/ros/melodic/setup.bash
rosservice call /ariac/start_competition
sleep 1
rosservice call /ariac/conveyor/control "power: 100"
sleep 1
rosservice call /ariac/arm1/gripper/control "enable: false"
sleep 1
rosservice call /ariac/arm1/gripper/control "enable: true"
sleep 1
rosservice call /ariac/arm1/gripper/control "enable: false"
#/app/rrrobot_ws/src/rrrobot/scripts/rrrobot_run_no_build.sh &
# cd /app/rrrobot_ws/src/rrrobot/src
# python3 cv_model.py &
# cd /app/rrrobot_ws/devel/lib/rrrobot
# ./rrrobot_node &
# ./depth_camera_node >> /dev/null &
# ./object_spawner_node &
# ./arm_controller_node &
# rostopic echo /arm_controller/destination &
# rostopic echo /desired_grasp_pose &
# rostopic echo /cv_model &