Skip to content
Merged
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
47 changes: 47 additions & 0 deletions webots/protos/FlagShip.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
#VRML_SIM R2025a utf8

# FlagShip is an extension that is mounted on top of the ZumoComSystem (DroidControlShip).
# It provides 360-degree lidar scanning capabilities for the Zumo robot platform.
PROTO FlagShip [
Comment thread
stefanvogel marked this conversation as resolved.
field SFString name "FlagShip"
field SFBool synchronization TRUE
]
{
Slot {
type "FlagShip"
endPoint Robot {
children [
Transform {
translation 0 0 0.03
children [
Shape {
appearance PBRAppearance {
baseColor 0.9 0.15 0.15
roughness 0.4
metalness 0
}
geometry Cylinder {
height 0.01
radius 0.03
}
}
Lidar {
name "lidar"
horizontalResolution 1440
fieldOfView 6.28318530718
numberOfLayers 1
minRange 0.15
maxRange 12
defaultFrequency 8
minFrequency 5
maxFrequency 20
}
]
}
]
name IS name
controller "<extern>"
synchronization IS synchronization
}
}
}
5 changes: 5 additions & 0 deletions webots/protos/ZumoComSystem.proto
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ PROTO ZumoComSystem [
field SFString name "ZumoComSystem"
field SFBool performanceMode FALSE # Use basic blocks for the robot instead of meshes. Increases performance.
field SFBool synchronization TRUE # Set to FALSE when used alongside another extern controller.
field SFNode flagShipSlot NULL # Slot for the FlagShip
]
{
Slot {
Expand Down Expand Up @@ -54,6 +55,10 @@ PROTO ZumoComSystem [
Compass {
name "compass"
}
Slot {
type "FlagShip"
endPoint IS flagShipSlot
}
]
name IS name
description "DroidControlShip"
Expand Down
40 changes: 40 additions & 0 deletions webots/worlds/zumo_with_flag_ship/DcsMinTrack.proto
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
#VRML_SIM R2025a utf8

EXTERNPROTO "https://raw.githubusercontent.com/cyberbotics/webots/R2025a/projects/objects/floors/protos/RectangleArena.proto"

PROTO DcsMinTrack [
field SFString contactMaterial "default" # Is `Solid.contactMaterial`.
]
{
RectangleArena {
contactMaterial IS contactMaterial
floorSize 2 2
floorTileSize 4 4
floorAppearance PBRAppearance {
baseColorMap ImageTexture {
url [
"./dcs.png"
]
}
roughness 1
roughnessMap ImageTexture {
url [
"https://raw.githubusercontent.com/cyberbotics/webots/R2022a/projects/appearances/protos/textures/parquetry/chequered_parquetry_roughness.jpg"
]
}
metalness 0
normalMap ImageTexture {
url [
"https://raw.githubusercontent.com/cyberbotics/webots/R2022a/projects/appearances/protos/textures/parquetry/chequered_parquetry_normal.jpg"
]
}
occlusionMap ImageTexture {
url [
"https://raw.githubusercontent.com/cyberbotics/webots/R2022a/projects/appearances/protos/textures/parquetry/chequered_parquetry_occlusion.jpg"
]
}
}
wallThickness 0.001
wallHeight 0.05
}
}
68 changes: 68 additions & 0 deletions webots/worlds/zumo_with_flag_ship/DcsMinimalLidarExample.wbt
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
#VRML_SIM R2025a utf8

EXTERNPROTO "https://raw.githubusercontent.com/cyberbotics/webots/R2025a/projects/objects/backgrounds/protos/TexturedBackground.proto"
EXTERNPROTO "https://raw.githubusercontent.com/cyberbotics/webots/R2025a/projects/objects/backgrounds/protos/TexturedBackgroundLight.proto"
EXTERNPROTO "../../protos/ZumoComSystem.proto"
EXTERNPROTO "../../protos/Zumo32U4.proto"
EXTERNPROTO "../../protos/FlagShip.proto"
EXTERNPROTO "./DcsMinTrack.proto"

WorldInfo {
info [
"World for testing DroidControlShip and a standalone native ROS2 LiDAR robot."
]
title "DCS Demo Track LiDAR Example"
basicTimeStep 8
}

Viewpoint {
orientation 0.3787583266277594 0.09714544028170935 -0.9203830145339561 2.677946076660944
position 1.2569587324159737 0.7945022889765716 1.5111964909293643
}

TexturedBackground {
}
TexturedBackgroundLight {
}

DcsMinTrack {
contactMaterial "cardboard"
}

Zumo32U4 {
name "Zumo"
performanceMode TRUE
zumoComSystemSlot ZumoComSystem {
name "ZumoComSystem"
performanceMode TRUE
flagShipSlot FlagShip {
name "FlagShip"
}
}
}

Solid {
name "LidarTarget"
translation 0.6 0.02 0.0
children [
Shape {
appearance PBRAppearance {
baseColor 0.1 0.6 0.9
roughness 0.5
metalness 0
}
geometry Box {
size 0.12 0.2 0.12
}
}
]
boundingObject Box {
size 0.12 0.2 0.12
}
}

Robot {
name "Ros2Supervisor"
controller "<extern>"
supervisor TRUE
}
Loading
Loading