autoware_carla_launch icon indicating copy to clipboard operation
autoware_carla_launch copied to clipboard

Carla port

Open JessicaFerrara opened this issue 1 year ago • 3 comments

hello. I would like to ask if I changed the Carla port (I don't use the default 2000) when I run the Carla server how do I change it also when I run the file in the Carla bridge container?

JessicaFerrara avatar May 01 '24 09:05 JessicaFerrara

Hello,

just to clarify the problem:

  • we changed the Carla server port to 3000. So, we wrote "./CarlaUE4.sh -quality-level=Epic -world-port=3000 -RenderOffScreen"
  • then, we modified "main.py" so that args.port is equal to 3000
  • we obtained the following error "terminate called after throwing an instance of 'carla::client::TimeoutException' what(): time-out of 5000ms while waiting for the simulator, make sure the simulator is ready and connected to 127.0.0.1:2000"
  • We are sure that in simulation.loop.py client = carla.Client(args.host, args.port) args.port is equal to 3000
  • We tried to launch the script simple_spawn.py and the connection with the server happened and we got the following message "Hello from the pygame community. https://www.pygame.org/contribute.html WARNING: sensor object went out of the scope but the sensor is still alive in the simulation: Actor 922 (sensor.other.gnss) WARNING: sensor object went out of the scope but the sensor is still alive in the simulation: Actor 923 (sensor.other.imu)"

We are not able to understand why a timeout on port 2000 is still notified if we set the port to 3000

Eventually, if we use the default port (2000) everything is fine but we need to use a different port.

epris avatar May 03 '24 16:05 epris

Hi @JessicaFerrara and @epris You only changed the port in Python script but not the bridge. Please add --carla-port 3000 in the script here https://github.com/evshary/autoware_carla_launch/blob/main/script/run-bridge.sh#L12

evshary avatar May 05 '24 00:05 evshary

Hi @JessicaFerrara and @epris You only changed the port in Python script but not the bridge. Please add --carla-port 3000 in the script here https://github.com/evshary/autoware_carla_launch/blob/main/script/run-bridge.sh#L12

it works, thanks!

epris avatar May 20 '24 13:05 epris