BMM350 issue, Different CHIP-ID. Infinite loop in otp_dump_after_boot(). Help needed

Hello,

We have a custom board with nRF54 as a host communicating with BMM350 over I2C with 100 Kbit/s.

We are using Zephyr RTOS, I have ported the following example to the Zephyr API I just added Zephyr I2C glue functions for the BMM350 files, which remain unchanged.

The first issue we run into is that when reading out CHIP-ID, instead of 0x33 it is 0x30 This causes an init failure as there is an if condition in the bmm350_init() A function that checks whether or not CHIP-ID is truly 0x33 or not.

I have tested on two boards, and on both boards, the CHIP-ID is 0x30.

I tried to modify the code and change the definition of expected CHIP-ID to 0x30 to pass this if condition, after which I experienced problems with the otp_dump_after_boot() function. Here, basically the code gets stuck in an infinite loop as it tries to read out the OTP memory, the following is part of the snippet captured by the logic analyzer on the I2C bus, which repeats forever.

write to 0x14 ack data: 0x55 
read to 0x14 ack data: 0x00 0x00 0x00
write to 0x14 ack data: 0x55 
read to 0x14 ack data: 0x00 0x00 0x00
write to 0x14 ack data: 0x55 
read to 0x14 ack data: 0x00 0x00 0x00

If I comment this out also, the execution is able to continue. However, after each call of bmm350_get_compensated_mag_xyz_temp_data(), I get 7F in data for each register starting from MAG_X_XLSB to TEMP_MSB. Which is the reset value for each register.

We require assistance on how to fix this

26 replies