cancel
Showing results for 
Search instead for 
Did you mean: 

ASM330LHB on STEVAL-MKI236A difficulty connecting via I2C

govindrzook
Associate II

I am trying to connect the IMU sensor that is onboard the STEVAL_MKI236AA evaluation board. I am currently trying to connect that board to BeagleBone AI-64 or a basic Arduino via I2C and was able to detect an I2C device as 0x6A and 0x6B as the board has 2 IMU sensors. 
My current issue is making use of the .c drivers provided by ST on github (https://github.com/STMicroelectronics/asm330lhb-pid/tree/64dab105b84706e68a405678a4b0f10a28d7b489) and using the provided example over here (https://github.com/STMicroelectronics/STMems_Standard_C_drivers/blob/master/asm330lhb_STdC/examples/asm330lhb_read_data_polling.c) can someone guide me how to grab the 6-axis data for this evaluation board as the provided example doesn't have this board listed in it and is an example when you make use of the ST mems adapter motherboard (STEVAL-MKI109V3) for the evaluation board but I am taking direct pins of SDA, SCL for I2C from the evaluation board.

PXL_20240127_174704392.jpg

Thanks!

1 REPLY 1
Federica Bossi
ST Employee

Hi @govindrzook .

Your board is not listed because it is not an ST Microelectronics product. However, you can adjust our pid examples modifying the Initialization of driver interface:

dev_ctx.write_reg = platform_write;
dev_ctx.read_reg = platform_read;
dev_ctx.handle = &SENSOR_BUS;

You need to define a write, read and handle for your specific board.

Hope this helps.

 

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question.