This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[TDA4VM] Compiling and running sample userspace ADC application

Hello,

I encountered a problem while running sample iio_generic_buffer application. As suggested in SDK Documentation I compiled the application as follows:

make -C ./ ARCH=aarch64

This gave me the expected result:

make[1]: Entering directory '/home/u20474/ti/j7/ti-processor-sdk-linux-automotive-j7-evm-06_01_00_05/board-support/linux-4.19.73+gitAUTOINC+0cabba2b47-g0cabba2b47/tools/iio'
  CC       iio_generic_buffer.o
  LD       iio_generic_buffer-in.o
make[1]: Leaving directory '/home/u20474/ti/j7/ti-processor-sdk-linux-automotive-j7-evm-06_01_00_05/board-support/linux-4.19.73+gitAUTOINC+0cabba2b47-g0cabba2b47/tools/iio'
  LINK     iio_generic_buffer

Having moved the iio_generic_buffer onto the target OS I was given an error:

root@j7-evm:~# ./iio_generic_buffer
-sh: ./iio_generic_buffer: cannot execute binary file: Exec format error

What might be the reason? Is it possible that the application was compiled for arm and not aarch64 architecture despite "ARCH=aarch64" argument?

Kind regard
Łukasz Gruszczelak

  • Hi

    For target side code you need to be using compiler that builds for the target architecture - have you set this up

    If you are using SDK version 6.0 or later, the steps to setup for cross compilation are described as part of "1.1.6. GCC ToolChain" section of the SDK documentation