cancel
Showing results for 
Search instead for 
Did you mean: 

BDU - Block Data Update - Which registers are covered ASM330LHH

m_kolesinski
Associate

Hello,

For the ASM330LHH, it's not clear which registers are covered by the BDU setting.  Although the datasheet and application notes list some registers that are covered, they are presented more as examples than an exhaustive list.

In my testing, it appears the BDU register doesn't protect the temperature (non-FIFO) registers at all.  With BDU enabled, I would still get ~1 degC temperature spikes when the sensor was operating at the rollover boundary (LSB near 0x00 or near 0xFF), due to the slight time skew between the two registers.  I was able to work around this by using the FIFO.

I also need to be able to sample the TIMESTAMP registers (TIMESTAMP1, TIMESTAMP2, TIMESTAMP3, TIMESTAMP4), from outside of the FIFO.  This is important because I need to periodically correlate the ASM330LHH's internal timestamp to an external time/clock; using the FIFO would introduce a large skew and a lot of complexity.

Are the timestamp registers protected by the BDU feature?  Can I reliably read them consecutively, and not have to handle saturation/rollover conditions at each byte's boundary?

 

Thanks!

 

2 REPLIES 2
m_kolesinski
Associate

Well, I haven't gotten any response, so I don't know if these results are expected, but I will share my observations based upon low-level testing:

  • Timestamp registers (not in the FIFO) are *not* protected by BDU; if you read them spanning a rollover in any of the bytes, it will most definitely bias your time upwards by the corresponding amount.  Why this wasn't considered in the design I don't know, but the documentation on this feature is incomplete and misleading.
  • Temperature sensor registers (not in the FIFO) are *not* protected by BDU.  Another topic on this forum was closed with the suggestion that the user turn on BDU, but it does not work on temperature data outside of the FIFO.  Again, why this sensor was excluded, I don't know.

 

Here is some sample data proving the rollover issue affecting timestamps (this example is on the LSB; it's more difficult to catch the other bytes since they come up less frequently)...the timestamp was sampled at approx 50ms intervals; anytime the LSB is within a few ticks of rollover, there's a large delta on the order of ~6ms (on the order of ~256 ticks, with some variability due to the imprecision of task scheduling in Linux, which corresponds to full-scale of the LSB):

 

timestamp%255delta
0x00EC2FCB2032112
0x00EC37CF2072052
0x00EC402D452142
0x00EC4860962099
0x00EC50821302082
0x00EC588E1422060
0x00EC61FF2552417
0x00EC6925371830
0x00EC715D932104
0x00EC79AF1752130
0x00EC81D32112084
0x00EC8A0112094
0x00EC9227392086
0x00EC9A731152124
0x00ECA2721142047

Yes, your data is skewed.  See analysis.