Generated code in Raspberry Pi

Hi :wave: dear community,

thanks for acados! I have managed to generate c-code from a model.
Now I’m trying to use the generated c code on raspberry pi.

I first installed acados by following the instructions here: Installation — acados documentation
Then I copied the generated code to raspberry pi and then cmake with the directory:

cmake -DACADOS_WITH_QPOASES=ON -DACADOS_INSTALL_DIR=</home/pi/c_generated_code> ..

Then I try to build the main_pendulum.c file by using

gcc -o pendulum main_pendulum.c

But I get the following error:

I am not sure what caused this error, are there more installations needed besides acados? or is there a setting that I missed when using cmake? I also changed the BLASFEO_TARGET to ARMV7A_ARM_CORTEX_A15.
As far as I understand blasfeo and hpipm are built directly with the build of acados just like casadi?

Any help would be appreciated.

best,

Julio

Hi,

I suggest to use the Makefile that is generated with the C code instead of calling gcc manually.

Or is there a reason to not use it?

Hi Jonathan,

thank you for the reply. Yes, I tried to use the Makefile by doing

sudo make

in “c_generated_code”, but I get the error:

image

That’s why I tried something else. I tried other ARM - Blasfeotargets and cmake again, but still get this error. I found that the Raspberry Pi 4b has an ARM Cortex-A72 CPU which is not in the targets. Could this be a problem?

Best regards.

Hi,

I see.
The issue is that the Makefile is generated from Windows and thus for windows.

It is detected here:

Maybe you can add an option to not detect it and make a Pull request?

Cheers!