Get the error: attempt to call a nil value (field 'getobjectMatrix')
Posted: 13 Apr 2024, 16:04
In my sysCall_thread() function, I use the code below to get the Tranform matrix between camera and end-effector. But I have got the error: [string "/Franka@childScript"]:139: attempt to call a nil value (field 'getobjectMatrix')
And in my previous attemption, I use getObjectFloatParam() and getObjectInt32Param() in the sysCall_thread() function will also appear the same error.
I don't know where the problems are. Can you give me some advise?
Code: Select all
tip=sim.getObject('/Franka/connection')
camera=sim.getObject('/Franka/blobTo3dPosition/sensor')
Anc=Matrix:vertcat(Matrix(3,4,sim.getobjectMatrix(camera,tip)),Matrix(1,4,{0,0,0,1}))
I don't know where the problems are. Can you give me some advise?