Open nikcleju opened 1 year ago
I managed to get it running by replacing the sim.wait()
after sim.start()
with polling if running:
sim.start(threads=4, time=100000, reduce=True)
#sim.wait()
while sim.is_running():
sleep(0.01)
With sim.wait()
it would sometimes work, and sometimes not. I still don't understand why is this happening. When exactly should I use sim.wait()
and when not?
The problem is that there is a mistake in wait()
. It calls PyTask::join()
which interrupts the task then waits for it to exit. It will be fixed in the next release. What you're doing with the while loop is fine.
I'm trying to run one of the examples via the Python API.
After some trial and error, I have something like this:
The simulation runs successfully, but the resulting surface is empty, so
get_surface()
andwrite_surface()
fail. Do you have any idea why?Basically I'm looking for a way to save the simulation result to a STL file.