Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

home world with delivery and looping tasks #147

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ By specifying `server_uri`, the fleetadapter will update `rmf-web` `api-server`

* [Hotel World](#Hotel-World)
* [Office World](#Office-World)
* [Home World](#Home-World)
* [Airport Terminal World](#Airport-Terminal-World)
* [Clinic World](#Clinic-World)

Expand Down Expand Up @@ -157,7 +158,32 @@ To run a scenario with multiple task requests, load [office_tasks.json](https://
The office demo can be run in secure mode using ROS 2 DDS-Security integration. Click [here](docs/secure_office_world.md) to learn more.

---
### Home World
This demo world shows robot inside a home environment where the robot is configured to serve beverages to multiple drop points and also perform looping tasks.


```bash
source ~/rmf_demos_ws/install/setup.bash
ros2 launch rmf_demos_gz home.launch.xml
```
2 types of Tasks are defined: **Delivery** and **Loop**

To send task requests, open rmf_demos web panel: https://open-rmf.github.io/rmf-panel-js/

![](../media/home_world.gif?raw=true)

To submit a delivery task, select ```Delivery``` from the ```Select a request type``` dropdown list. Next, select ```your desired coke delivery location``` from the ```Select delivery task``` list. Choose a desired start time for task and click submit.

Or, submit a task via CLI:

```bash
ros2 run rmf_demos_tasks dispatch_patrol -p kitchen dining_table -n 2 --use_sim_time
ros2 run rmf_demos_tasks dispatch_delivery -p kitchen -ph coke_dispenser -d bedroom_1 -dh coke_ingestor_bedroom_1 --use_sim_time
```

To submit a **loop task**, select ```Loop``` from the ```Select a request type``` dropdown list. Choose desired start and end locations and click submit.

---
### Airport Terminal World

This demo world shows robot interaction on a much larger map, with a lot more lanes, destinations, robots and possible interactions between robots from different fleets, robots and infrastructure, as well as robots and users. In the illustrations below, from top to bottom we have how the world looks like in `traffic_editor`, the schedule visualizer in `rviz`, and the full simulation in `gazebo`,
Expand Down
56 changes: 56 additions & 0 deletions rmf_demos/config/home/tinyRobot_config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# FLEET CONFIG =================================================================
# RMF Fleet parameters

rmf_fleet:
name: "tinyRobot"
fleet_manager:
ip: "127.0.0.1"
port: 22011
user: "some_user"
password: "some_password"
limits:
linear: [0.5, 0.75] # velocity, acceleration
angular: [0.6, 2.0] # velocity, acceleration
profile: # Robot profile is modelled as a circle
footprint: 0.3 # radius in m
vicinity: 0.5 # radius in m
reversible: True # whether robots in this fleet can reverse
battery_system:
voltage: 12.0 # V
capacity: 24.0 # Ahr
charging_current: 5.0 # A
mechanical_system:
mass: 20.0 # kg
moment_of_inertia: 10.0 #kgm^2
friction_coefficient: 0.22
ambient_system:
power: 20.0 # W
tool_system:
power: 0.0 # W
recharge_threshold: 0.10 # Battery level below which robots in this fleet will not operate
recharge_soc: 1.0 # Battery level to which robots in this fleet should be charged up to during recharging tasks
publish_fleet_state: 10.0 # Publish frequency for fleet state, ensure that it is same as robot_state_update_frequency
account_for_battery_drain: True
task_capabilities: # Specify the types of RMF Tasks that robots in this fleet are capable of performing
loop: True
delivery: True
clean: False
finishing_request: "park" # [park, charge, nothing]

# TinyRobot CONFIG =================================================================

robots:
# Here the user is expected to append the configuration for each robot in the
# fleet.
# Configuration for tinyRobot
tinyRobot:
robot_config:
max_delay: 15.0 # allowed seconds of delay of the current itinerary before it gets interrupted and replanned
rmf_config:
robot_state_update_frequency: 10.0
start:
map_name: "L1"
waypoint: "tinyRobot_charger"
orientation: 0.0 # radians
charger:
waypoint: "tinyRobot_charger"
23 changes: 23 additions & 0 deletions rmf_demos/launch/home.launch.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version='1.0' ?>

<launch>
<arg name="use_sim_time" default="false"/>

<!-- Common launch -->
<include file="$(find-pkg-share rmf_demos)/common.launch.xml">
<arg name="use_sim_time" value="$(var use_sim_time)"/>
<arg name="viz_config_file" value ="$(find-pkg-share rmf_demos)/include/home/home.rviz"/>
<arg name="config_file" value="$(find-pkg-share rmf_demos_maps)/home/home.building.yaml"/>
<arg name="dashboard_config_file" value="$(find-pkg-share rmf_demos_dashboard_resources)/home/dashboard_config.json"/>
</include>

<!-- TinyRobot fleet adapter -->
<group>
<include file="$(find-pkg-share rmf_demos_fleet_adapter)/launch/fleet_adapter.launch.xml">
<arg name="use_sim_time" value="$(var use_sim_time)"/>
<arg name="nav_graph_file" value="$(find-pkg-share rmf_demos_maps)/maps/home/nav_graphs/0.yaml" />
<arg name="config_file" value="$(find-pkg-share rmf_demos)/config/home/tinyRobot_config.yaml"/>
</include>
</group>

</launch>
217 changes: 217 additions & 0 deletions rmf_demos/launch/include/home/home.rviz
Original file line number Diff line number Diff line change
@@ -0,0 +1,217 @@
Panels:
- Class: rviz_common/Displays
Help Height: 138
Name: Displays
Property Tree Widget:
Expanded:
- /MarkerArray3/Topic1
- /MarkerArray4/Topic1
Splitter Ratio: 0.5
Tree Height: 270
- Class: rviz_common/Selection
Name: Selection
- Class: rviz_common/Tool Properties
Expanded:
- /2D Goal Pose1
- /Publish Point1
Name: Tool Properties
Splitter Ratio: 0.5886790156364441
- Class: rviz_common/Views
Expanded:
- /Current View1
Name: Views
Splitter Ratio: 0.5
- Class: rmf_visualization_rviz2_plugins/SchedulePanel
Finish: 600
Map: L1
Name: SchedulePanel
Topic: /rmf_visualization/parameters
- Class: rmf_visualization_rviz2_plugins/DoorPanel
Name: DoorPanel
Visualization Manager:
Class: ""
Displays:
- Alpha: 0.5
Cell Size: 1
Class: rviz_default_plugins/Grid
Color: 160; 160; 164
Enabled: false
Line Style:
Line Width: 0.029999999329447746
Value: Lines
Name: Grid
Normal Cell Count: 0
Offset:
X: 0
Y: 0
Z: 0
Plane: XY
Plane Cell Count: 10
Reference Frame: <Fixed Frame>
Value: false
- Class: rviz_default_plugins/MarkerArray
Enabled: true
Name: MarkerArray
Namespaces:
fleet_markers: true
Topic:
Depth: 5
Durability Policy: Volatile
History Policy: Keep Last
Reliability Policy: Reliable
Value: /fleet_markers
Value: true
- Class: rviz_default_plugins/MarkerArray
Enabled: true
Name: MarkerArray
Namespaces:
participant 0: true
participant location 0: true
Topic:
Depth: 5
Durability Policy: Volatile
History Policy: Keep Last
Reliability Policy: Reliable
Value: /schedule_markers
Value: true
- Class: rviz_default_plugins/MarkerArray
Enabled: true
Name: MarkerArray
Namespaces:
labels: true
map: true
Topic:
Depth: 5
Durability Policy: Transient Local
History Policy: Keep Last
Reliability Policy: Reliable
Value: /map_markers
Value: true
- Class: rviz_default_plugins/MarkerArray
Enabled: true
Name: MarkerArray
Namespaces:
front_door: true
front_door_text: true
dining_door: true
dining_door_text: true
bathroom_door: true
bathroom_door_text: true
bd1_door: true
bd1_door_text: true
bd2_door: true
bd2_door_text: true
kitchen_door: true
kitchen_door_text: true
bd2_toilet_door: true
bd2_toilet_door_text: true
laundry_door: true
laundry_door_text: true
bd1_cloth_door: true
bd1_cloth_door_text: true

Topic:
Depth: 5
Durability Policy: Transient Local
History Policy: Keep Last
Reliability Policy: Reliable
Value: /building_systems_markers
Value: true
- Alpha: 0.7
Class: rviz_default_plugins/Map
Color Scheme: map
Draw Behind: true
Enabled: true
Name: Map
Topic:
Depth: 5
Durability Policy: Transient Local
History Policy: Keep Last
Reliability Policy: Reliable
Value: /floorplan
Update Topic:
Depth: 5
Durability Policy: Transient Local
History Policy: Keep Last
Reliability Policy: Reliable
Value: /floorplan_updates
Use Timestamp: false
Value: true
Enabled: true
Global Options:
Background Color: 48; 48; 48
Fixed Frame: map
Frame Rate: 30
Name: root
Tools:
- Class: rviz_default_plugins/Interact
Hide Inactive Objects: true
- Class: rviz_default_plugins/MoveCamera
- Class: rviz_default_plugins/Select
- Class: rviz_default_plugins/FocusCamera
- Class: rviz_default_plugins/Measure
Line color: 128; 128; 0
- Class: rviz_default_plugins/SetInitialPose
Topic:
Depth: 5
Durability Policy: Volatile
History Policy: Keep Last
Reliability Policy: Reliable
Value: /initialpose
- Class: rviz_default_plugins/SetGoal
Topic:
Depth: 5
Durability Policy: Volatile
History Policy: Keep Last
Reliability Policy: Reliable
Value: /goal_pose
- Class: rviz_default_plugins/PublishPoint
Single click: true
Topic:
Depth: 5
Durability Policy: Volatile
History Policy: Keep Last
Reliability Policy: Reliable
Value: /clicked_point
Transformation:
Current:
Class: rviz_default_plugins/TF
Value: true
Views:
Current:
Angle: 0
Class: rviz_default_plugins/TopDownOrtho
Enable Stereo Rendering:
Stereo Eye Separation: 0.05999999865889549
Stereo Focal Distance: 1
Swap Stereo Eyes: false
Value: false
Invert Z Axis: false
Name: Current View
Near Clip Distance: 0.009999999776482582
Scale: 95.94175720214844
Target Frame: <Fixed Frame>
Value: TopDownOrtho (rviz_default_plugins)
X: 14.163299560546875
Y: -7.102552890777588
Saved: ~
Window Geometry:
Displays:
collapsed: false
DoorPanel:
collapsed: false
Height: 1726
Hide Left Dock: false
Hide Right Dock: true
QMainWindow State: 000000ff00000000fd00000004000000000000033400000622fc0200000009fb0000001200530065006c0065006300740069006f006e00000001e10000009b000000b000fffffffb0000001e0054006f006f006c002000500072006f007000650072007400690065007302000001ed000001df00000185000000a3fb000000120056006900650077007300200054006f006f02000001df000002110000018500000122fb000000200054006f006f006c002000500072006f0070006500720074006900650073003203000002880000011d000002210000017afb000000100044006900730070006c006100790073000000006e000001910000018200fffffffb0000002000730065006c0065006300740069006f006e00200062007500660066006500720200000138000000aa0000023a00000294fb00000014005700690064006500530074006500720065006f02000000e6000000d2000003ee0000030bfb0000000c004b0069006e0065006300740200000186000001060000030c00000261fc0000006e000006220000062201000039fa000000020100000003fb0000001a005300630068006500640075006c006500500061006e0065006c0100000000ffffffff0000028300fffffffb000000120044006f006f007200500061006e0065006c0100000000ffffffff0000029300fffffffb000000120052004d0046002000500061006e0065006c0100000000000003340000033400ffffff000000010000015f00000765fc0200000003fb0000001e0054006f006f006c002000500072006f00700065007200740069006500730100000041000000780000000000000000fb0000000a00560069006500770073000000006e000007650000013200fffffffb0000001200530065006c0065006300740069006f006e010000025a000000b200000000000000000000000200000490000000a9fc0100000001fb0000000a00560069006500770073030000004e00000080000002e10000019700000003000004420000003efc0100000002fb0000000800540069006d00650100000000000004420000000000000000fb0000000800540069006d00650100000000000004500000000000000000000006440000062200000004000000040000000800000008fc0000000100000002000000010000000a0054006f006f006c00730100000000ffffffff0000000000000000
SchedulePanel:
collapsed: false
Selection:
collapsed: false
Tool Properties:
collapsed: false
Views:
collapsed: true
Width: 2436
X: 4064
Y: 116
2 changes: 2 additions & 0 deletions rmf_demos_dashboard_resources/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ ament_package()
set(outputs
${CMAKE_CURRENT_SOURCE_DIR}/airport_terminal/main.json
${CMAKE_CURRENT_SOURCE_DIR}/office/main.json
${CMAKE_CURRENT_SOURCE_DIR}/home/main.json
)

if(${CMAKE_VERSION} VERSION_GREATER_EQUAL 3.12)
Expand All @@ -32,5 +33,6 @@ install(DIRECTORY
office
hotel
clinic
home
DESTINATION share/${PROJECT_NAME}
)
Loading