How to resolve error "The ROS master is already running on port 11311"?

36 visualizaciones (últimos 30 días)
The following error is thrown
The ROS master is already running on port 11311. Try connecting to this master or creating a new ROS master
that uses a different port.
when running
core = ros.Core;
How can I resolve this error?

Respuesta aceptada

MathWorks Support Team
MathWorks Support Team el 19 de Abr. de 2021
One reason for this error might be an external process, which is already using this port. If you can determine which process exactly is causing this issue, you may be able to change its settings to use a different port. If not, or if it does not have settings, any computer-wide setting to block programs from using 11311 would also block ROS.
Port 11311 is the default port for ROS, but you can use any other port, as long as your other ROS machines target it, as shown in the example below
core = ros.Core(11312);
rosinit(core.MasterURI) ;

Más respuestas (0)

Categorías

Más información sobre Network Connection and Exploration en Help Center y File Exchange.

Etiquetas

Productos


Versión

R2020b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by