TWIM Errata 109

Hello Nordic,

I've been attempting to convert our system's TWIM implementation from the blocking to the non-blocking mode. I have been able to communicate fine with the external device (an LIS2MDL Magnetometer) while in the blocking mode, however, when I attempt to convert my implementation to the non-blocking mode, it appears that the MCU is not correctly sending the configurations that I am interested in.

When I use the blocking mode, I use a NRFX_TWIM_XFER_DESC_TX() descriptor with the nrfx_twim_xfer() to transfer a configuration, and then use the NRFX_TWIM_XFER_DESC_RX() descirptor with the nrfx_twim_xfer() to check if the configuration was applied, and it has. When in non-blocking mode, I use the NRFX_TWIM_XFER_DESC_TXTX descriptor and wait until the handler provides a NRFX_TWIM_EVT_DONE event where I check the p_event information. The information stored there appears to be the correct information (aka the value of the configuration I wanted to set on the LIS2MDL). However, when I then check this using the NRFX_TWIM_XFER_DESC_TXRX descriptor, the value of the register that I just tried to change remains unchanged (in this case, the LIS2MDL is idle and won't send me sensor data).

From doing a little research, I found this document on Anomaly/Errata 109 which appears to be related to this issue. I've tried to enable the TWIM_NRF52_ANOMALY_109_WORKAROUND_ENABLED macro in both the apply_old_config.h and the sdk_config.h, but this did not fix the issue.

Any help would be greatly appreciated.

Joseph

Related