Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DIABIO-SIM-ENV

License language platform

The basic webots simulation environment for DIABLO.

Noted that the environment has no controller, but you can design your own controller to control the robot.


Platform Support

  • Ubuntu 20.04/22.04 (64-bit PC (AMD64) desktop)
  • Windows 10

Dependencies

  • Docker (if you use docker to install, this is necessary)

Use without Docker

Use this script to install Webots,gdbgui,and clonthe diablo-A1 project without controller

Run the following in the bash :

./scripts/webots_install.sh

Use Docker

  1. Install nvidia driver
./scripts/docker_install.sh
  1. Imort the docker image (recommended by rmecboy)
docker pull registry.cn-guangzhou.aliyuncs.com/ddt_robot/diablo_sim:v1
  1. Use docker container(run the script in your local host)
./scripts/create_container.sh

You shall see this if everything is normal.

webots-0

./scripts/enter_container.sh
./scripts/halt.sh

Run webots with docker

use the following command to run webots

webots

Step1:Load the webots model

webots-4

webots-5-gui-open-wbt-file

webots-6

Step2:Run the simulation

2.2.1 Enter the makefile directory :

cd /opt/webots-sim-projects/sim-webots/diablo_A1/controllers/diablo_webots/

2.2.2 compile the code

make debug

2.2.3 Run the simulation, you shall see the robot fall down. Now you can start to design your own controller.

./diablo_webots

webots7-manul-control

Windows Configuration

1.Install gcc-arm-none-eabi

  • Remeber to choose Add path to envieonment variable

2.Install minGW

  • unzip and open mingw64\bin,change mingw32-make.exe to make.exe,then add the bin file to PATH.

3.Install Webots

4.Install the following in VSCODE

4.1 modify launch.json

  • Open VSCODE in diablo-sim-env\diablo_A1\controllers,then modify launch.json

将launch.json内容替换为如下代码

{
    "version": "0.2.0",
    "configurations": [
      {
        "type": "cppdbg",
        "request": "launch",
        "name": "Webots",
        "program": "${workspaceFolder}/diablo_webots/diablo_webots.exe",
        "stopAtEntry": false,
        "cwd": "${workspaceFolder}",
        "args": [ ],
        "environment": [],
        "externalConsole": false
      }
    ]
  }

4.2 Modify Makefile

  • Open diablo_webots\Makefile

Change WEBOTS_HOME_PATH to your webots path

  • then make your project to generate diablo_webots.exe
cd /d/study/liao/diablo-sim-env/diablo_A1/controllers/diablo_webots

make debug

About

DIABLO基于Webots的基本仿真环境,由rmecboy和agentyhj1提供

Resources

Stars

8 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages