I am trying to open a TCP port on coppeliaSim to connect to, but when doing the command
/Applications/coppeliaSim.app/Contents/MacOS/coppeliaSim -gREMOTEAPISERVERSERVICE_19999_FALSE_TRUE
it opens coppeliaSim without the flagging i presume. When running my script to test it out:
local sim = require("sim")
function sysCall_init()
local status, _info, _serverVersion, _clientVersion, _clientIp =
simRemoteApi.status(19999)
if status == -1 then
print([[
Warning: you did not start CoppeliaSim in the way required to connect to the server.
Please start with "-gREMOTEAPISERVERSERVICE_19999_FALSE_TRUE",
using ./scripts/start_coppelia_sim
]])
end
end
it gives me the error:
[string "/Robobo@childScript"]:5: attempt to index a nil value (global 'simRemoteApi')
stack traceback:
[string "/Robobo@childScript"]:5: in function 'sysCall_init'
So I think the problem is that I might be doing the flagging incorrect? or it is coppelia that has issues with MacOS, because it did work for my classmates who work on Windows and Linus operating systems.
Does anyone know how to resolve this issue?