bullet3
bullet3 copied to clipboard
cannot load URDF. Graphics server issue
I cannot load URDF from pybullet.GRAPHICS_SERVER on device 1. However, I can load URDF from the pybullet.GRAPHICS_SERVER_TCP on device 2 to connect to device 1. Is there any way for me to be able to load URDF at a single server from two different devices connected over the TCP or UDP?
Device 1 code-
`import pybullet as p
import time
import pybullet_data
p.disconnect() if p.isConnected() else print("Ready")
pid=p.connect(p.GRAPHICS_SERVER)
p.setAdditionalSearchPath(pybullet_data.getDataPath())
print("started graphics server",pid)
p.loadURDF("plane.urdf") #this line throws error - cannot load URDF files
`
Device 2 code-
`import pybullet as p
import pybullet_data as pd
import time
ip_addr = 192.xxx.xx.x #ip v4 address of device 1
p.connect(p.GRAPHICS_SERVER_TCP,ip_addr,6667)
p.setAdditionalSearchPath(pd.getDataPath())
p.syncBodyInfo()
p.loadURDF("r2d2.urdf", [1,1,3])
p.setGravity(0,0,-10)
if p.isConnected():
for _ in range(100):
p.stepSimulation()
time.sleep(0.01)
`
I am using Windows 11 x64 operating system and VScode version 1.82.3
_Originally posted by @Mridul1129261 in https://github.com/bulletphysics/bullet3/issues/2755#issuecomment-1744226066_