MMA6222EG
Sensors
22 Freescale Semiconductor
4.1.6 Acceleration Response Error Status
Several error conditions may be detected and reported in response to an acceleration data command.
Figure 4-7 ND/HE Error Frame
4.1.6.1 ND - No Data Available
Bit 4 will be set to indicate a “No Data” condition if acceleration data is requested while the device is undergoing device initializa-
tion following reset. To ensure that an unexpected device reset will always be detectable regardless of the interval at which the
sensor is accessed, “No Data” status will be returned in response to the first acceleration data request following device initializa-
tion.
4.1.6.2 HE - Hardware Error
A fault has been detected within the MMA62XXEG device. Detectable fault conditions are listed below
Device over-temperature
Offset error
Internal parity error
Specific error conditions are indicated in the device status register. The contents of this register are returned in response to a
device test operation, as described in Section 4.1.10. Oscillator fault status will be reported only if the internal oscillator is func-
tional but frequency comparison between the primary and reference oscillators fails. If an oscillator fault condition exists, the de-
vice will respond as described in Section 4.2.2.2.
4.1.6.3 CNC - Conditions Not Correct
Acceleration data will not be provided when bit 15 of command is detected as logic ‘1’. The response to such requests is illus-
trated below. Should a No Data Available or Hardware Error condition also exist, it will be reported as well.
Figure 4-8 CNC Error Frame
4.1.7 Non-Acceleration Transfers
Three different types of non-acceleration transfers are supported; register write, register read and device test. Non-acceleration
data transfers are initiated when bit 13 from the master is set to a logic ‘0’ state. The operation to be performed is indicated by
bits 15 and 14.
Table 4-3 Non-Acceleration Operations
Bit 15 Bit 14 Operation
0 0 Unused
0 1 Register Write
1 0 Register Read
1 1 Device Test
0
SCLK
BIT
D
OUT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0AXISP ND0110000 0HE 00
0
SCLK
BIT
D
OUT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
1 AXIS P0110000 010ND HE
MMA6222EG
Sensors
Freescale Semiconductor 23
Non-acceleration transfers will always succeed except in the case of oscillator fault, SPI error or request error conditions. Only
oscillator failure, SPI error or request error conditions are reported in response to non-acceleration commands. Other error con-
dition are reported as hardware errors in response to acceleration data requests.
4.1.8 Register Write Operations
Register write operations are initiated when bits 15 and 13 from the master is set to a logic ‘0’ and bit 14 is set to a logic ‘1’. Bits
12 through 8 contain a five-bit address, while the last eight bits contain the data value to be written. Only the DEVCTL register is
writable. If an attempt is made to write to any register other than DEVCTL, a request error response (see Figure 4-15) will occur.
Figure 4-9 Register Write Command
Response to a register write operation is illustrated below. DEVCTL bits which can be read as logic ‘1’ (HPFB, ST1 and ST0) will
be indicated during the last eight clock cycles, as shown.
Figure 4-10 Register Write Command Response
4.1.9 Register Read Operations
Register read operations are initiated when bit 15 from the master is set to a logic ‘1’ state and bits 14 and 13 are driven to a logic
low level. The address of the register to be accessed is contained in bits 12 through 8. D
IN
bits 7 through 0 are ignored by
MMA62XXEG during register read command transfers.
Figure 4-11 Register Read Command
Data read from the selected register is returned in bits 7 through 0, as shown below.
Figure 4-12 Register Read Command Response
SCLK
BIT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
D
IN
1
0
A4 A3 A2 A1 A0 D7 D6 D5 D4 D3 D2 D1 D00
SCLK
BIT
D
OUT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
01
P 0 HPFB 0 ST1
ST0
00
0
1110 0
SCLK
BIT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
D
IN
0
0
A4 A3 A2 A1 A0 X X X X X X X X1
SCLK
BIT
D
OUT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
10
P D4D3D2D1
D0
D6 D5
0
1110 D7
MMA6222EG
Sensors
24 Freescale Semiconductor
4.1.10 Device Test Operation
A device test operation is conducted when D
IN
bits 15 and 14 are at a logic high level and bit 13 is driven to a logic low level.
Figure 4-13 Device Test Command
The content of the device status register are transmitted in bits D7 through D0 in response to a device test operation. Refer to
Section 3.1.3 for details regarding the device status register
Figure 4-14 Device Test Command Response
Status register bit 0 is set following any device reset. This bit will remain set until explicitly cleared by writing the CE bit in the
device control register, as described in Section 3.1.1.
4.1.11 Non-Acceleration Request Error
An error condition is indicated if a non-acceleration command is detected and D
IN
bits 15 and 14 are both zero, as no operation
is specified for this combination.
Figure 4-15 Non-Acceleration Request Error
4.1.12 SPI Error Response
The following conditions detected at D
IN
will result in a SPI error. Since the error condition likely indicate a corrupted transfer, the
response frame is the same regardless of the state of bit 13 at D
IN
.
SCLK high when CS
asserted
Fewer than 16 rising edges of SCLK detected while CS
is asserted
Greater than 16 rising edges of SCLK detected while CS
is asserted
SCLK high when CS
negated
SCLK
BIT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
D
IN
1
0
XXXXXXXXXXXXX1
SCLK
BIT
D
OUT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
11PD4D3D2D1D0D6 D50 1110 D7
0
SCLK
BIT
D
OUT
CS
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
00P0111000 10000

MMA621010EGR2

Mfr. #:
Manufacturer:
NXP / Freescale
Description:
Accelerometers 100 /100 XY DIGITAL
Lifecycle:
New from this manufacturer.
Delivery:
DHL FedEx Ups TNT EMS
Payment:
T/T Paypal Visa MoneyGram Western Union