Problem
During continuous XYZ acquisition using the FIFO, the output sometimes becomes persistently constant while FIFO reads continue. The occurrence is unpredictable: it can happen within a few seconds or after many minutes. Some runs show constant output on one or two axes; others show the same value on all three.
Digital signal captures confirm the constant values in the raw SPI MISO data, independently of the application’s decoder.
So far, this behavior has only been observed with the external clock enabled. In a recent comparison, no issue was detected during one hour using the internal clock. After re-enabling the external clock, 18 errors were detected within approximately six minutes. Further measurements are ongoing.
Setup
The ADXL373 is connected by SPI to an FRDM-RW612 running Zephyr v4.4.0. The custom driver is derived from Zephyr’s ADXL372 implementation, with added features including external-clock support and integration with the sensor stream API.
Sensor revision: 0xFB, verified by SPI readback.
SPI: approximately 8 MHz, mode 0, MSB first, active-low CS.
External clock: generated by the FRDM-RW612 PWM peripheral and connected to INT1; approximately 240.076 kHz measured in the digital captures.
ODR setting: code 3.
FIFO: XYZ stream mode, watermark of 384 axis entries (128 XYZ sample sets).
FIFO interrupt: INT2.
Regular FIFO reads: 381 axis words (127 XYZ sample sets).
The diagnostic application detects 1270 consecutive identical values on any axis, logs the event and automatically restarts the test.
Configuration sequence
The example recording includes initialization following a manual board reset, acquisition start, the failure and the subsequent automatic restart.
During initialization, the driver places the sensor in standby, issues a software reset, configures the registers and enables measurement. Pressing the acquisition-start button later enables the FIFO interrupt, places the sensor in standby, disables and reconfigures the FIFO, then enables measurement again.
Selected writes from the recording are shown below. Other transactions are omitted here; the complete decoded sequence includes every captured MOSI/MISO byte.
Stage Operation MOSI bytes
Initialization Sensor software reset 82 52
Initialization Set TIMING = 0x62, enabling external clock 7A 62
Initialization Set POWER_CTL = 0x0F, measurement mode 7E 0F
Acquisition start Set INT2_MAP = 0x04 78 04
Acquisition start Set POWER_CTL = 0x0C, standby 7E 0C
Acquisition start Set FIFO_CTL = 0x01, FIFO disabled 74 01
Acquisition start Set FIFO_CTL = 0x03, XYZ stream mode 74 03
Acquisition start Set FIFO_SAMPLES = 0x80 72 80
Acquisition start Set POWER_CTL = 0x0F, measurement mode 7E 0F
Example failure
In this recording, all three axes become constant at −10 approximately 3.65 seconds after acquisition is enabled. The transition occurs in the third XYZ group of SPI transaction #208 (attached file). Subsequent FIFO reads continue returning the same acceleration values.
The decoded SPI sequence includes initialization and the transition from normal to constant output, with timestamps and raw bytes. The original digital recording is also available.
Request for support
Could you review the configuration and FIFO read sequence and identify anything incorrect or any recommended changes?
Is this constant-output behavior known, particularly when using an external clock? What additional measurements would help determine its cause?
/cfs-file/__key/communityserver-discussions-components-files/334/adxl373_5F00_spi_5F00_startup_5F00_and_5F00_failure.txt