Simulation worlds, maps, CAD models, and game behavior nodes for the VEX Push Back field + a few test envionments. See the repository Autonomous-VEXU/otto_gazebo for robot simulation assets.
Note: If you want to prevent infinite rolling, refer to this section
In order to launch a world or really any launch file, the workspace must first be built and sourced. Make sure you are in the correct directory before running the commands: colcon build --symlink-install and then source install/setup.bash.
Here is a general command to launch a specific world:
ros2 launch pushback_sim world_select.launch.py world:=<world>Note:
<world>is where you put the name of the world that you want to launch.
This launch file is the top level launch file for this package and is highly configurable through launch arguments.
Documentation can be found here
ros2 launch pushback_sim full_simulation.launch.py- Available Worlds
- Package File Tree
- Launch Files
- Nodes
- Rolling Friction Plugin
- ROS + Gazebo Sim Resources
block_test: Empty world with one of each block model
empty: Just as it sounds, a completely empty world
empty_field: VEX Push Back field with no blocks
pushback: VEX Push Back field set up to competition standards
sensor_test: Asymmetric field used for testing sensors setups in sim
pushback_sim/
├── launch/
│ ├── full_simulation.launch.py
│ ├── opponent.launch.py
│ ├── sim_backend.launch.py
│ ├── strategy_ai.launch.py
│ ├── tb3_field.launch.py
│ └── world_select.launch.py
├── maps/
│ ├── keepout_full_goal.pgm
│ ├── keepout_full_goal.yaml
│ ├── vex_field_map.pgm
│ └── vex_field_map.yaml
├── models/
│ ├── blue-sphere
│ ├── clear-objects
│ ├── lidar-test-field
│ ├── red-sphere
│ └── vex-field
├── src/
│ ├── ai_driver.py
│ ├── field_location.py
│ ├── opponent.py
│ ├── pose_bridge.py
│ ├── scoring.py
│ ├── strategy_ai_bridge.py
│ └── world_services.py
├── worlds/
│ ├── block_test.sdf
│ ├── empty_field.sdf
│ ├── empty.sdf
│ ├── pushback.sdf
│ └── sensor_test.sdf
├── CMakeLists.txt
├── package.xml
└── resources.txt
models/
└── model-name/
├── meshes/
│ ├── model-part.dae
│ └── model-part-collision.dae
├── model.config
└── model.sdf
Launches the full simulation. This is the top level launch file for this package. Arguments:
keepout_filter: toggles using the keepout filter for the goalsopponent: toggles opponent spawning into world + other nodes launchingteleop: conditionally launches teleop controlworld_ctrl: toggles simulation post tracking and backend servicesnav2: toggles nav2 mppi controllersai: toggles the strategy AI model
Launches the opponent node and gazebo bridge node.
Launches all of the nodes that deal with simulaton logic/making the game playable. Includes field_location.py, pose_bridge.py, scoring.py, and world_services.py.
Launches the sai (strategy AI) node Arguments:
ai_delay: mount of time to delay launching the strategy AI model
Turtlebot3 + one of the worlds. Arguments:
x_pose: spawn in at a specific X coordinatey_pose: spawn in at a specific Y coordinatez_pose: spawn in at a specific Z coordinate
Launches the sim for Windows :(
Selects a world SDF file to load in Gazebo Sim. Arguments:
world: the world filename without the '.sdf'
Interprets the output of the strategy AI node and calls actions to control Otto. Just uses the Nav2 move to pose action for now.
Determines if an action (i.e. picking up a ball) can occur based on Otto's location and orientation. Basically collision checking for goal hitboxes to vaildate scoring.
Spawns in and randomly moves a box to predetermined points to simulate an opponent for the strategy AI node.
Purpose of this node is to listen to the gazebo topic /world/default/dynamic_pose/info, parse the data (JSON) reformat it to include the name of the model and its ID number and republishes it on the /object_locations topic.
Takes in vex_interfaces/Goal and returns the overall score. Includes control zones.
Collected world state information from various topics, packaged them into a vex_interfaces/WorldState message, and published them to a topic that the strategy AI node subscribes to.
Exposes a few services for adding things to loaders, intaking a ball, and outputting a ball (determines if ball falls on the ground or is scored). Main purpose is to communicate with the gazebo sim topic to manipulate entites.
Both the blue and red spheres use a gazebo plugin called rolling_friction::RollingFrictionPlugin the plugin + install instructions can be found here: kymadogg/gz_rolling_friction
ROS2 Jazzy Jalisco Documentation
ROS Index
Nav2 Documentation
Gazebo Harmonic Documentation
Open Robotics Discourse
Robotics Stack Exchange
Simulation Description Format (SDF)
RGBA 0-1 Color Picker