Closed gmsanchez closed 4 years ago
Hi @gmsanchez. This is great news.
OpEn can generate C/C++ bindings if you compile using the setting .with_build_c_bindings()
as discussed in the documentation. For that you need to install clang, which is a requirement of cbindgen
.
OpEn will generate C bindings as well as an example C file. You may then modify this file. Compiling and linking is easy, but I think it would be a very good idea for OpEn to auto-generate a cmake file as well.
@gmsanchez I created a pull request (#152) to address this issue. As a first step, I am auto-generating a CMakeLists file that allows you to compile the auto-generated example C file. Once you compile using with_build_c_bindings()
, you can do:
cmake .
make run
to run the auto-generated example.
This is a first-step to an auto-generated ROS node.
Note: See ros_optimization_engine
First implementation: https://github.com/alphaville/open_ros
It remains to make Jinja2 templates and support automatic code generation for ROS packages
Hi! I've been able to migrate a MHE problem that I had running on IPOPT to OpEn. So far so good, I am able to get results in less than a millisecond!
The next step should be to use the generated C code with roscpp in a ROS C++ node. Is there any template or example on how to configure the CMakefile (using cmake or cmake_simple)?
Thanks in advance!