Build for Applications Processor (ARM CPU)

VOXL uses a Snapdragon 821 with an ARMv8-A 64-bit Qualcomm® Kyro Quad Core CPU.

The following are good examples of how to build applications processor (apps-proc) code with the voxl-emulator docker image:

Name Description Link
librc_math Example of linear algebra routines in C Source
OpenCV 3.4.6 How to build OpenCV 3.4.6 for VOXL, with examples Source
voxl-vision-px4 Example use of ModalAI Vision Library for VIO and VOA Source

Background

VOXL uses a 64-bit linux kernel, however most of the core libraries on VOXL are 32-bit and are built using GCC4.9. Most applications running natively on VOXL have to be built with that same version of compiler. GCC4.9 toolchain that comes with VOXL is only capable of building 32-bit applications, however building and running 64-bit applications is still possible and recommended for maximum performance benefit. We are currently enabling many of the core components and migrating examples to 64-bit.

The https://docs.modalai.com/install-voxl-docker/ builds 32-bit applications and is easy to use for quick ports of existing applications.

Our recommended compiler flags for 32-bit architecture are as follows. Note that it is very important to specify correct fpu flags, otherwise the NEON engine will not be used for floating-point computations, significantly slowing down floating-point math.

-march=armv7-a -mfloat-abi=softfp -mfpu=neon-vfpv4

Build 64-bit applications

The https://https://gitlab.com/voxl-public/utilities/voxl-docker/ Docker can be used to cross-compile 64-bit applications using GCC 4.9

Alternatively, a 64-bit docker image, such as, arm64v8/ubuntu or arm64v8/ros can also build and run 64-bit application in a Docker container directly on VOXL.

Our recommended compiler flags for 64-bit are as follows - specifying fpu flags is optional :

-march=armv8-a