lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


ROS having a C++ API was a bad, bad design decision.

I'd go whatever is faster to write. Probably the binding. On the other hand, writing algorithms is way more rewarding than messing around with C++ bindings (YMMV).

I'd not worry about the performance on either alternative. If at some point in the future it shows to be a problem (unlikely), only then I'd look into it.

Jorge


On 04/11/16 05:34, Ravi Joshi wrote:
Hello,

I am using Lua for Dynamic Simulation of Baxter Robot. For this purpose, I need to calculate Mass Inertia Matrix from URDF file. Earlier, I was using pykdl [1] in ros (python), which has a function for calculating inertia matrix [2,3]. pykdl uses KDL structure internally, which can be initialized from URDF file.

The python library pykdl, internally uses Orocos Kinematics Dynamics library [4], which is written in CPP. At this moment, I can think of two possible solutions to calculate Mass Inertia Matrix from URDF file-

1. Write the code completely in Lua
2. Call the CPP library from Lua

In case of point 1, I need to first read the URDF (xml) file and construct the KDL structure. then using this structure calculate the Mass Inertia Matrix as done in [4]. This is looking like re-inventing the wheel again. In case of point 2, I doubt on the efficiency.

Any idea please.

References-


Thanks

-
Ravi