ROS System Requirements

ROS 1 Requirements

Since R2020b, the ROS Toolbox supports the ROS Melodic Morenia distribution for ROS.

Platforms

  • Windows® — Windows 10 recommended.

  • Linux® — Ubuntu 18.04 recommended.

  • Mac OS X

For more information about ROS Melodic support, see their Target Platforms page.

Python Version 2.7

To connect to ROS networks with the rosinit function, you must install and setup Python 2.7.

To check your Python® version, use the pyenv function.

pyenv
ans = 
  PythonEnvironment with properties:

          Version: "2.7"
       Executable: "C:\Python27\pythonw.exe"
          Library: "C:\windows\system32\python27.dll"
             Home: "C:\Python27"
           Status: NotLoaded
    ExecutionMode: OutOfProcess

If your Python interpreter is set to a different version, restart MATLAB® and set the version with pyenv.

pyenv('Version','2.7')

ROS Custom Messages

When generating custom messages for ROS, you must build the ROS packages. This requires you to have Python, CMake, and a C++ compiler for your platform:

Download and install CMake 3.15.5+.

C++ Compilers

ROS 2 Requirements

Since R2020a, the ROS Toolbox supports the Dashing Diademata distribution for ROS 2.

Platforms

  • Windows 10 only

  • Linux — Ubuntu 18.04 recommended

  • macOS — Sierra (10.12.x)

For more information about ROS Dashing support, see their Dashing Diademata page.

ROS 2 Custom Messages

When generating custom messages for ROS 2, you must build the ROS packages. This requires you to have Python, CMake, and a C++ compiler for your platform.

Python Version 3.7

Install and setup Python 3.7.

To check your Python version, use the pyenv function.

pyenv
ans = 
  PythonEnvironment with properties:

          Version: "3.7"
       Executable: "C:\Python37\pythonw.exe"
          Library: "C:\windows\system32\python37.dll"
             Home: "C:\Python37"
           Status: NotLoaded
    ExecutionMode: OutOfProcess

If your Python interpreter is set to a different version, restart MATLAB and set the install version with pyenv.

pyenv('Version','3.7')

CMake

Download and install CMake 3.15.5+.

C++ Compilers

Related Topics