beautypg.com

3 multi-axis measurement (mam) operation, 1 mam spi activity sequence, 2 mam command byte – PNI RM3000-F Sensor Suite User Manual

Page 33: Multi-axis measurement (mam) operation, Mam spi activity sequence, Mam command byte

background image

PNI Sensor Corporation

Doc #1016102 r04

RM3000-f & RM2000-f Sensor Suite User Manual

Page 33

5.3 Multi-Axis Measurement (MAM) Operation

An initial 2-byte command initiates a sensor measurement for up to 3 sensors. After

measurements are made and DRDY goes HIGH, another 1-byte command initiates reading of

the measured values on the MISO line. See the

Appendix

for code examples.

5.3.1 MAM SPI Activity Sequence

The SPI timing sequence is given below for MAM operation. SPI timing is discussed in

Section 4.4. The Return Byte is 0x9A. If the Return Byte is 0x9B, then the 3D MagIC is

in Legacy Mode. The number of data bytes will be determined by the number of axes

that are to be measured. Each axis is comprised of 3 bytes of data, so for a 3 axis

measurement 9 total bytes would be clocked out to receive all the data. The Command

Byte and Axes Select Byte are discussed below.

Figure 5-2: SPI Activity Sequence Diagram for MAM Operation

5.3.2 MAM Command Byte

The initial MAM Command Byte is sent to set up the 3D MagIC to take a sensor

measurement and a different MAM Command Byte is later sent to initiate reading the

measurement results registers on the MISO line. The MAM Command Byte is 0x82 to

set-up for a sensor measurement and 0xC9 to retrieve the data starting at the X axis. Note

the initial Command Byte (0x82) does not actually initiate a sensor measurement, as the

measurement is initiated after the MAM Axes Select Byte is sent.