cancel
Showing results for 
Search instead for 
Did you mean: 

Compile Lsm6dsm self test

Shabtai
Visitor

Hi,

I am trying to use command line to compile self test of lsm6dsm by the following: 

arm-linux-gnueabi-gcc -static  lsm6dsm_self_test.c lsm6dsm_reg.c -o self test -I.

and got error: 

lsm6dsm_self_test.c:159:21: error: ‘SENSOR_BUS’ undeclared (first use in this function)

I couldn't find how to define SENSOR_BUS.

I have tried:

extern SPI_HandleTypeDef hspi1;
#define SENSOR_BUS hspi1

The device is connected using SPI.

Regards.

 

 

0 REPLIES 0