Skip to content

Commit

Permalink
WEBOTS_HOME was not correct set for linux and MacOS.
Browse files Browse the repository at this point in the history
  • Loading branch information
BlueAndi committed Oct 20, 2024
1 parent 363148b commit fa27e05
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions scripts/webots_launcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,21 +48,21 @@
+ '--serialTxCh ' + ROBOT_SERIAL_TX_CHANNEL + ' ' \
+ '-v'
WEBOTS_CONTROLLER_OPTIONS = '--robot-name=' + ROBOT_NAME + ' --stdout-redirect'
WEBOTS_HOME = os.getenv('WEBOTS_HOME')

if OS_PLATFORM_TYPE == OS_PLATFORM_TYPE_WIN:

WEBOTS_HOME = os.getenv('WEBOTS_HOME').replace('\\', '/')
WEBOTS_CONTROLLER = '"' + WEBOTS_HOME + '/msys64/mingw64/bin/webots-controller.exe"'
WEBOTS_CONTROLLER = f"\"{WEBOTS_HOME.replace('\\', '/')}/msys64/mingw64/bin/webots-controller.exe\""
PROGRAM_NAME = "${PROGNAME}.exe"

elif OS_PLATFORM_TYPE == OS_PLATFORM_TYPE_LINUX:

WEBOTS_CONTROLLER = "$WEBOTS_HOME/webots-controller"
WEBOTS_CONTROLLER = f"{WEBOTS_HOME}/webots-controller"
PROGRAM_NAME = "${PROGNAME}"

elif OS_PLATFORM_TYPE == OS_PLATFORM_TYPE_MACOS:

WEBOTS_CONTROLLER = "$WEBOTS_HOME/Contents/MacOS/webots-controller"
WEBOTS_CONTROLLER = f"{WEBOTS_HOME}/Contents/MacOS/webots-controller"
PROGRAM_NAME = "${PROGNAME}"

else:
Expand Down

0 comments on commit fa27e05

Please sign in to comment.