■ Integrated low- and high-pass filters with user-
selectable bandwidth
■ Ultra-stable over temperature and time
■ Wide supply voltage: 2.4 V to 3.6 V
■ Low voltage-compatible IOs (1.8 V)
■ Embedded power-down and sleep mode
■ Embedded temperature sensor
■ Embedded FIFO
■ High shock survivability
■ Extended operating temperature range (-40 °C
to +85 °C)
■ ECOPACK
Applications
■ Gaming and virtual reality input devices
■ Motion control with MMI (man-machine
interface)
■ GPS navigation systems
■ Appliances and robotics
®
RoHS and “Green” compliant
L3G4200D
MEMS motion sensor:
Preliminary data
LGA-16
Description
The L3G4200D is a low-power three-axis angular
rate sensor able to provide unprecedented
stablility of zero rate level and sensitivity over
temperature and time. It includes a sensing
element and an IC interface capable of providing
the measured angular rate to the external world
through a digital interface (I
The sensing element is manufactured using a
dedicated micro-machining process developed by
STMicroelectronics to produce inertial sensors
and actuators on silicon wafers.
The IC interface is manufactured using a CMOS
process that allows a high level of integration to
design a dedicated circuit which is trimmed to
better match the sensing element characteristics.
The L3G4200D has a full scale of ±250/±500/
±2000 dps and is capable of measuring rates with
a user-selectable bandwidth.
The L3G4200D is available in a plastic land grid
array (LGA)package and can operate within a
temperature range of -40 °C to +85 °C.
(4x4x1.1 mm)
2
C/SPI).
Table 1.Device summary
Order codeTemperature range (°C)PackagePacking
L3G4200D-40 to +85LGA-16 (4x4x1.1 mm)Tray
L3G4200DTR-40 to +85LGA-16 (4x4x1.1 mm)Tape and reel
December 2010Doc ID 17116 Rev 31/42
This is preliminary information on a new product now in development or undergoing evaluation. Details are subject to
change without notice.
The vibration of the structure is maintained by drive circuitry in a feedback loop. The sensing
signal is filtered and appears as a digital signal at the output.
1.1 Pin description
Figure 2.Pin connection
+Ω
1
(TOP VIEW)
DIRECTIONS OF THE
DETECTABLE
ANGULAR RATES
AM07225v1
PLLFILT
Z
X
+Ω
Y
RES
RES
GND
1316
12
BOTTOM
RES
Vdd
1
Vdd_IO
SCL/SPC
VIEW
+Ω
RES
RES
X
8
INT
RES
5
DRDY/INT2
CS
SDA/SDI/SDO
49
SDO/SA0
AM07226v1
Doc ID 17116 Rev 37/42
Page 8
Block diagram and pin descriptionL3G4200D
Table 2.Pin description
Pin#NameFunction
1Vdd_IOPower supply for I/O pins
2
SCL
SPC
SDA
3
SDI
SDO
4
SDO
SA0
5CS
6DRDY/INT2Data ready/FIFO interrupt
7INT1Programmable interrupt
8ReservedConnect to GND
9ReservedConnect to GND
10ReservedConnect to GND
11ReservedConnect to GND
2
I
C serial clock (SCL)
SPI serial port clock (SPC)
2
C serial data (SDA)
I
SPI serial data input (SDI)
3-wire interface serial data output (SDO)
SPI serial data output (SDO)
2
C least significant bit of the device address (SA0)
I
SPI enable
2
C/SPI mode selection (1:SPI idle mode / I2C communication
I
enabled; 0: SPI communication mode / I2C disabled)
12ReservedConnect to GND
13GND0 V supply
14PLLFILTPhase-locked loop filter (see Figure 3)
15ReservedConnect to Vdd
16VddPower supply
Figure 3.L3G4200D external low-pass filter values
%CRCEKVQTHQT
.QYRCUUHKNVGT
VQRKP
%
4%
(a)
)0&
#/X
a. Pin 14 PLLFILT maximum voltage level is equal to Vdd.
8/42Doc ID 17116 Rev 3
Page 9
L3G4200DBlock diagram and pin description
Table 3.Filter values
ParameterTypical value
C110 nF
C2470 nF
R210 kΩ
Doc ID 17116 Rev 39/42
Page 10
Mechanical and electrical characteristicsL3G4200D
2 Mechanical and electrical characteristics
2.1 Mechanical characteristics
Table 4.Mechanical characteristics @ Vdd = 3.0 V, T = 25 °C, unless otherwise noted
SymbolParameterTest conditionMin. Typ.
(2)
Max.Unit
±250
FSMeasurement rangeUser-selectable
±2000
FS = 250 dps8.75
SoSensitivity
FS = 2000 dps70
SoDr
Sensitivity change vs.
temperature
From -40 °C to +85 °C±2%
FS = 250 dps±10
DVoffDigital zero-rate level
FS = 2000 dps±75
OffDr
Zero-rate level change
vs. temperature
NLNon linearity
(3)
(4)
FS = 250 dps±0.03dps/°C
FS = 2000 dps±0.04dps/°C
Best fit straight line0.2% FS
FS = 250 dps130
DSTSelf-test output change
FS = 2000 dps530
RnRate noise densityBW = 50 Hz0.03
ODRDigital output data rate
Top
1. The product is factory calibrated at 3.0 V. The operational power supply range is specified in Table 5.
2. Typical specifications are not guaranteed.
3. Min/max values have been estimated based on the measurements of the current gyros in production.
Subject to general operating conditions for Vdd and Top.
Table 7.SPI slave timing values
(1)
Val ue
SymbolParameter
Min.Max.
tc(SPC)SPI clock cycle100ns
fc(SPC)SPI clock frequency10MHz
tsu(CS)CS setup time5
th(CS)CS hold time8
tsu(SI)SDI input setup time5
th(SI)SDI input hold time15
tv(SO)SDO valid output time50
th(SO)SDO output hold time6
tdis(SO)SDO output disable time50
Unit
ns
1. Values are guaranteed at 10 MHz clock frequency for SPI with both 4 and 3 wires, based on characterization results; not
tested in production.
K6,
(b)
Y62
F63&
K62
K&6
/6%,1
GLV62
/6%287
!-V
Figure 4.SPI slave timing diagram
&6
VX&6
63&
VX6,
6',
6'2
06%,1
06%287
b. Measurement points are done at 0.2·Vdd_IO and 0.8·Vdd_IO, for both input and output ports.
12/42Doc ID 17116 Rev 3
Page 13
L3G4200DMechanical and electrical characteristics
W
W
W
W
W
W
W
W
W
W
W
W
2.4.2 I2C - inter IC control interface
Subject to general operating conditions for Vdd and Top.
Table 8.I2C slave timing values
SymbolParameter
I2C standard mode
(1)
I2C fast mode
MinMaxMinMax
(1)
Unit
f
(SCL)
t
w(SCLL)
t
w(SCLH)
t
su(SDA)
t
h(SDA)
t
r(SDA) tr(SCL)
t
f(SDA) tf(SCL)
t
h(ST)
t
su(SR)
t
su(SP)
t
w(SP:SR)
1. Data based on standard I2C protocol requirement; not tested in production.
2. Cb = total capacitance of one bus line, in pF.
Figure 5.I
SCL clock frequency01000400kHz
SCL clock low time4.71.3
SCL clock high time4.00.6
SDA setup time250100ns
SDA data hold time03.4500.9µs
SDA and SCL rise time1000
SDA and SCL fall time300
START condition hold time40.6
Repeated START condition
setup time
4.70.6
STOP condition setup time40.6
Bus free time between STOP
and START condition
2
C slave timing diagram
67$57
(c)
4.71.3
20 + 0.1C
20 + 0.1C
µs
(2)
b
(2)
b
300
ns
300
µs
5(3($7('
67$57
6'$
I6'$
U6'$
VX6'$
K6'$
6&/
Z6&//
K67
c. Measurement points are done at 0.2·Vdd_IO and 0.8·Vdd_IO, for both ports.
Z6&/+
U6&/
I6&/
Doc ID 17116 Rev 313/42
VX65
VX63
Z6365
67$57
6723
!-V
Page 14
Mechanical and electrical characteristicsL3G4200D
2.5 Absolute maximum ratings
Any stress above that listed as “Absolute maximum ratings” may cause permanent damage
to the device. This is a stress rating only and functional operation of the device under these
conditions is not implied. Exposure to maximum rating conditions for extended periods may
affect device reliability.
Table 9.Absolute maximum ratings
SymbolRatingsMaximum valueUnit
VddSupply voltage-0.3 to 4.8V
T
ESDElectrostatic discharge protection2 (HBM)kV
Storage temperature range-40 to +125°C
STG
SgAcceleration g for 0.1 ms10,000g
This is a mechanical shock sensitive device, improper handling can cause permanent
damage to the part
This is an ESD sensitive device, improper handling can cause permanent damage to
the part
14/42Doc ID 17116 Rev 3
Page 15
L3G4200DMechanical and electrical characteristics
2.6 Terminology
2.6.1 Sensitivity
An angular rate gyroscope is a device that produces a positive-going digital output for
counterclockwise rotation around the sensitive axis considered. Sensitivity describes the
gain of the sensor and can be determined by applying a defined angular velocity to it. This
value changes very little over temperature and time.
2.6.2 Zero-rate level
Zero-rate level describes the actual output signal if there is no angular rate present. The
zero-rate level of precise MEMS sensors is, to some extent, a result of stress to the sensor
and, therefore, the zero-rate level can slightly change after mounting the sensor onto a
printed circuit board or after exposing it to extensive mechanical stress. This value changes
very little over temperature and time.
2.6.3 Stability over temperature and time
Thanks to the unique single driving mass approach and optimized design, ST gyroscopes
are able to guarantee a perfect match of the MEMS mechanical mass and the ASIC
interface, and deliver unprecedented levels of stability over temperature and time.
With Zero rate level and sensitivity performances, up to ten times better than equivalent
products now available on the market, L3G4200D allows the user to avoid any further
compensation and calibration during production for faster time to market, easy application
implementation, higher performances and cost saving.
2.7 Soldering information
The LGA package is compliant with the ECOPACK®, RoHS and “Green” standard.
It is qualified for soldering heat resistance according to JEDEC J-STD-020.
Leave “pin 1 Indicator” unconnected during soldering.
Land pattern and soldering recommendations are available at www.st.com/
.
Doc ID 17116 Rev 315/42
Page 16
Main digital blocksL3G4200D
3 Main digital blocks
3.1 Block diagram
Figure 6.Block diagram
/UT?3E
L
$ATA2EG
!$#
3.2 FIFO
,0&
(0&
(0EN
,0&
).4?3EL
&)&/
X
X
)NTERRUPT
GENERATOR
)#
30)
3#22%'
#/.&2%'
).4
!-V
The L3G4200D embeds a 32-slot, 16-bit data FIFO for each of the three output channels:
yaw, pitch, and roll. This allows consistent power saving for the system, as the host
processor does not need to continuously poll data from the sensor. Instead, it can wake up
only when needed and burst the significant data out from the FIFO. This buffer can work in
five different modes. Each mode is selected by the FIFO_MODE bits in the
FIFO_CTRL_REG. Programmable watermark level, FIFO_empty or FIFO_Full events can
be enabled to generate dedicated interrupts on the DRDY/INT2 pin (configured through
CTRL_REG3), and event detection information is available in FIFO_SRC_REG. The
watermark level can be configured to WTM4:0 in FIFO_CTRL_REG.
3.2.1 Bypass mode
In bypass mode, the FIFO is not operational and for this reason it remains empty. As
illustrated in Figure 7, only the first address is used for each channel. The remaining FIFO
slots are empty. When new data is available, the old data is overwritten.
16/42Doc ID 17116 Rev 3
Page 17
L3G4200DMain digital blocks
Figure 7.Bypass mode
XIYIZ
I
X
Y
Y
I
Z
EMPTY
3.2.2 FIFO mode
In FIFO mode, data from the yaw, pitch, and roll channels are stored in the FIFO. A
watermark interrupt can be enabled (I2_WMK bit in CTRL_REG3), which is triggered when
the FIFO is filled to the level specified in the WTM 4:0 bits of FIFO_CTRL_REG. The FIFO
continues filling until it is full (32 slots of 16-bit data for yaw, pitch, and roll). When full, the
FIFO stops collecting data from the input channels. To restart data collection, it is necessary
to write FIFO_CTRL_REG back to bypass mode.
FIFO mode is represented in Figure 8.
Figure 8.FIFO mode
X
X
X
Y
Y
Y
Z
Z
Z
!-V
XIYIZ
3.2.3 Stream mode
In stream mode, data from yaw, pitch, and roll measurements are stored in the FIFO. A
watermark interrupt can be enabled and set as in FIFO mode. The FIFO continues filling
until full (32 slots of 16-bit data for yaw, pitch, and roll). When full, the FIFO discards the
I
X
X
X
X
Doc ID 17116 Rev 317/42
Y
Y
I
Y
Y
Y
Z
Z
Z
Z
!-V
Page 18
Main digital blocksL3G4200D
older data as the new data arrives. Programmable watermark level events can be enabled to
generate dedicated interrupts on the DRDY/INT2 pin (configured through CTRL_REG3).
Stream mode is represented in Figure 9.
Figure 9.Stream mode
XIYIZ
I
X
Y
Z
X
X
X
X
3.2.4 Bypass-to-stream mode
In bypass-to-stream mode, the FIFO starts operating in bypass mode, and once a trigger
event occurs (related to INT1_CFG register events), the FIFO starts operating in stream
mode (see Figure 10).
Figure 10. Bypass-to-stream mode
Y
Y
Y
Y
Z
Z
Z
Z
!-V
XIYIZ
I
%MPTY
X
X
X
X
Y
Y
Y
Y
Y
Z
I
Z
Z
Z
"YPASSMODE
4RIGGER EV E NT
18/42Doc ID 17116 Rev 3
XIYIZ
I
X
X
X
X
Y
X
3T
REAMMODE
Y
Y
Y
Y
Z
Z
Z
Z
Z
!-V
Page 19
L3G4200DMain digital blocks
3.2.5 Stream-to-FIFO mode
In stream-to-FIFO mode, data from yaw, pitch, and roll measurements are stored in the
FIFO. A watermark interrupt can be enabled on pin DRDY/INT2, setting the I2_WTM bit in
CTRL_REG3, which is triggered when the FIFO is filled to the level specified in the WTM4:0
bits of FIFO_CTRL_REG. The FIFO continues filling until full (32 slots of 16-bit data for yaw,
pitch, and roll). When full, the FIFO discards the older data as the new data arrives. Once a
trigger event occurs (related to INT1_CFG register events), the FIFO starts operating in
FIFO mode (see Figure 11).
Figure 11. Trigger stream mode
XIYIZ
I
X
X
X
X
X
Y
Y
Y
Y
Y
3TREAM-ODE
3.2.6 Retrieve data from FIFO
FIFO data is read through the OUT_X, OUT_Y and OUT_Z registers. When the FIFO is in
stream, trigger or FIFO mode, a read operation to the OUT_X, OUT_Y or OUT_Z registers
provides the data stored in the FIFO. Each time data is read from the FIFO, the oldest pitch,
roll, and yaw data are placed in the OUT_X, OUT_Y and OUT_Z registers and both single
read and read_burst (X,Y & Z with auto-incremental address) operations can be used. In
read_burst mode, when data included in OUT_Z_H is read, the system again starts to read
information from addr OUT_X_L.
XIYIZ
Z
Z
Z
Z
Z
I
X
X
X
X
&)&/
Y
Y
I
Y
Y
Y
-ODE
Z
Z
Z
Z
4RIGGEREVENT
!-V
Doc ID 17116 Rev 319/42
Page 20
Application hintsL3G4200D
4 Application hints
Figure 12. L3G4200D electrical connections and external component values
(TOP VIEW)
DIRECTIONS OF THE
DETECTABLE
ANGULAR RATES
10nF
10kOhm470nF
R2
AM07949V1
1
C1
C2
+Ω
Z
X
GND
+Ω
+Ω
PLLFILT
VddGND
100 nF
Y
X
SDA_SDI_SDO
Vdd_IO
SCL/SPC
SDO/SA0
SCL/SPC
SDA_SDI_SDO
Pull-up to be added when I2C interface isused
1
49
GND
Vdd
TOP
VIEW
5
DR
CS
Vdd I2C bus
10 µF
PLLFILT
INT
Rpu = 10kOhmRpu
1316
12
8
GND
Power supply decoupling capacitors (100 nF ceramic or polyester +10 µF) should be placed
as near as possible to the device (common design practice).
If Vdd and Vdd_IO are not connected together, power supply decoupling capacitors
(100 nF and 10 µF between Vdd and common ground, 100 nF between Vdd_IO and
common ground) should be placed as near as possible to the device (common design
practice).
The L3G4200D IC includes a PLL (phase locked loop) circuit to synchronize driving and
sensing interfaces. Capacitors and resistors must be added at the PLLFILT pin (as shown in
Figure 12) to implement a second-order low-pass filter. Table 10 summarizes the PLL low-
pass filter component values.
Table 10.PLL low-pass filter component values
ComponentValue
C110 nF ± 10 %
C2470 nF ± 10 %
R210 kΩ ± 10 %
20/42Doc ID 17116 Rev 3
Page 21
L3G4200DDigital interfaces
5 Digital interfaces
The registers embedded in the L3G4200D may be accessed through both the I2C and SPI
serial interfaces. The latter may be software-configured to operate either in 3-wire or 4-wire
interface mode.
The serial interfaces are mapped onto the same pins. To select/exploit the I
CS line must be tied high (i.e., connected to Vdd_IO).
C serial data (SDA)
SPI serial data input (SDI)
3-wire interface serial data output (SDO)
SPI serial data output (SDO)
2
C least significant bit of the device address
I
2
C disabled)
2
C interface, the
5.1 I2C serial interface
The L3G4200D I2C is a bus slave. The I2C is employed to write data to registers whose
content can also be read back.
The relevant I
Table 12.I2C terminology
TransmitterThe device which sends data to the bus
ReceiverThe device which receives data from the bus
Master
There are two signals associated with the I2C bus: the serial clock line (SCL) and the serial
data line (SDA). The latter is a bidirectional line used for sending and receiving the data
to/from the interface. Both lines must be connected to Vdd_IO through an external pull-up
resistor. When the bus is free both the lines are high.
2
The I
C interface is compliant with fast mode (400 kHz) I2C standards as well as with normal
mode.
2
C terminology is given in the table below.
TermDescription
The device which initiates a transfer, generates clock signals and terminates a
transfer
SlaveThe device addressed by the master
Doc ID 17116 Rev 321/42
Page 22
Digital interfacesL3G4200D
5.1.1 I2C operation
The transaction on the bus is started through a START (ST) signal. A START condition is
defined as a HIGH to LOW transition on the data line while the SCL line is held HIGH. After
this has been transmitted by the master, the bus is considered busy. The next byte of data
transmitted after the start condition contains the address of the slave in the first 7 bits and
the eighth bit tells whether the master is receiving data from the slave or transmitting data to
the slave. When an address is sent, each device in the system compares the first 7 bits after
a start condition with its address. If they match, the device considers itself addressed by the
master.
The slave address (SAD) associated with the L3G4200D is 110100xb. The SDO pin can be
used to modify the least significant bit (LSb) of the device address. If the SDO pin is
connected to the voltage supply, LSb is ‘1’ (address 1101001b). Otherwise, if the SDO pin is
connected to ground, the LSb value is ‘0’ (address 1101000b). This solution permits the
connection and addressing of two different gyroscopes to the same I
Data transfer with acknowledge is mandatory. The transmitter must release the SDA line
during the acknowledge pulse. The receiver must then pull the data line LOW so that it
remains stable low during the HIGH period of the acknowledge clock pulse. A receiver which
has been addressed is obliged to generate an acknowledge after each byte of data
received.
2
The I
C embedded in the L3G4200D behaves like a slave device, and the following protocol
must be adhered to. After the START (ST) condition, a slave address is sent. Once a slave
acknowledge (SAK) has been returned, an 8-bit sub-address is transmitted. The 7 LSb
represent the actual register address while the MSB enables address auto-increment. If the
MSb of the SUB field is 1, the SUB (register address) is automatically incremented to allow
multiple data read/write.
2
C bus.
The slave address is completed with a read/write bit. If the bit is ‘1’ (read), a REPEATED
START (SR) condition must be issued after the two sub-address bytes; if the bit is ‘0’ (write)
the master transmits to the slave with the direction unchanged. Table 13 describes how the
SAD+read/write bit pattern is composed, listing all the possible configurations.
Table 13.SAD+read/write patterns
CommandSAD[6:1]SAD[0] = SDOR/WSAD+R/W
Read1101000111010001 (D1h)
Write1101000011010000 (D0h)
Read1101001111010011 (D3h)
Write1101001011010010 (D2h)
Table 14.Transfer when master is writing one byte to slave
MasterSTSAD + WSUBDATASP
SlaveSAKSAKSAK
22/42Doc ID 17116 Rev 3
Page 23
L3G4200DDigital interfaces
Table 15.Transfer when master is writing multiple bytes to slave
MasterSTSAD + WSUBDATADATASP
SlaveSAKSAKSAKSAK
Table 16.Transfer when master is receiving (reading) one byte of data from slave
MasterSTSAD + WSUBSRSAD + RNMAKSP
SlaveSAKSAKSAKDATA
Table 17.Transfer when master is receiving (reading) multiple bytes of data from slave
Master ST SAD+WSUBSR SAD+RMAKMAKNMAKSP
SlaveSAKSAKSAK DATADATADATA
Data are transmitted in byte format (DATA). Each data transfer contains 8 bits. The number
of bytes transferred per transfer is unlimited. Data is transferred with the most significant bit
(MSb) first. If a receiver cannot receive another complete byte of data until it has performed
some other function, it can hold the clock line SCL LOW to force the transmitter into a wait
state. Data transfer only continues when the receiver is ready for another byte and releases
the data line. If a slave receiver does not acknowledge the slave address (i.e., it is not able
to receive because it is performing some real-time function) the data line must be left HIGH
by the slave. The master can then abort the transfer. A LOW to HIGH transition on the SDA
line while the SCL line is HIGH is defined as a STOP condition. Each data transfer must be
terminated by the generation of a STOP (SP) condition.
In order to read multiple bytes, it is necessary to assert the most significant bit of the subaddress field. In other words, SUB(7) must be equal to 1, while SUB(6-0) represents the
address of the first register to be read.
In the presented communication format, MAK is “master acknowledge” and NMAK is “no
master acknowledge”.
5.2 SPI bus interface
The SPI is a bus slave. The SPI allows writing and reading of the device registers. The serial
interface interacts with the external world through 4 wires: CS, SPC, SDI, and SDO.
Doc ID 17116 Rev 323/42
Page 24
Digital interfacesL3G4200D
Figure 13. Read and write protocol
CS
SPC
SDI
DI7 DI6 DI5 DI4 DI3 DI2 DI1 DI0
DO7DO6DO5DO4DO3DO2DO1DO0
SDO
RW
MS
AD5 AD4 AD3 AD2 AD1 AD0
CS is the serial port enable and is controlled by the SPI master. It goes low at the start of the
transmission and returns to high at the end. SPC is the serial port clock and is controlled by
the SPI master. It is stopped high when CS is high (no transmission). SDI and SDO are,
respectively, the serial port data input and output. These lines are driven at the falling edge
of SPC and should be captured at the rising edge of SPC.
Both the read register and write register commands are completed in 16 clock pulses, or in
multiples of 8 in case of multiple read/write bytes. Bit duration is the time between two falling
edges of SPC. The first bit (bit 0) starts at the first falling edge of SPC after the falling edge
of CS while the last bit (bit 15, bit 23, etc.) starts at the last falling edge of SPC just before
the rising edge of CS.
Bit 0: RW
from the device is read. In the latter case, the chip drives SDO at the start of bit 8.
Bit 1: MS
When 1, the address is auto-incremented in multiple read/write commands.
Bit 2-7: address AD(5:0). This is the address field of the indexed register.
Bit 8-15: data DI(7:0) (write mode). This is the data that is written to the device (MSb first).
Bit 8-15: data DO(7:0) (read mode). This is the data that is read from the device (MSb first).
In multiple read/write commands, further blocks of 8 clock periods are added. When the MS
bit is 0, the address used to read/write data remains the same for every block. When the MS
bit is 1, the address used to read/write data is incremented at every block.
The function and the behavior of SDI and SDO remain unchanged.
5.2.1 SPI read
Figure 14. SPI read protocol
bit. When 0, the data DI(7:0) is written to the device. When 1, the data DO(7:0)
bit. When 0, the address remains unchanged in multiple read/write commands.
CS
SPC
SDI
RW
MS
AD5 AD4 AD3 AD2 AD1 AD0
SDO
DO7 DO6 DO5DO4 DO3 DO2 DO1DO0
24/42Doc ID 17116 Rev 3
Page 25
L3G4200DDigital interfaces
The SPI read command is performed with 16 clock pulses. A multiple byte read command is
performed by adding blocks of 8 clock pulses to the previous one.
Bit 0: READ bit. The value is 1.
Bit 1: MS
bit. When 0, do not increment address; when 1, increment address in multiple
reading.
Bit 2-7: address AD(5:0). This is the address field of the indexed register.
Bit 8-15: data DO(7:0) (read mode). This is the data that is read from the device (MSb first).
Bit 16-... : data DO(...-8). Further data in multiple byte reading.
The SPI write command is performed with 16 clock pulses. A multiple byte write command is
performed by adding blocks of 8 clock pulses to the previous one.
Bit 0: WRITE bit. The value is 0.
Bit 1: MS
bit. When 0, do not increment address; when 1, increment address in multiple
writing.
Bit 2 -7: address AD(5:0). This is the address field of the indexed register.
Bit 8-15: data DI(7:0) (write mode). This is the data that is written to the device (MSb first).
Bit 16-... : data DI(...-8). Further data in multiple byte writing.
3-wire mode is entered by setting the SIM (SPI serial interface mode selection) bit to 1 in
CTRL_REG2.
Figure 18. SPI read protocol in 3-wire mode
CS
SPC
SDI/O
RW
MS
AD5 AD4 AD3 AD2 AD1 AD0
DO7 DO6 DO5 DO4 DO3 DO2 DO1 DO0
The SPI read command is performed with 16 clock pulses:
Bit 0: READ bit. The value is 1.
Bit 1: MS
bit. When 0, do not increment address; when 1, increment address in multiple
reading.
Bit 2-7: address AD(5:0). This is the address field of the indexed register.
Bit 8-15: data DO(7:0) (read mode). This is the data that is read from the device (MSb first).
The multiple read command is also available in 3-wire mode.
26/42Doc ID 17116 Rev 3
Page 27
L3G4200DOutput register mapping
6 Output register mapping
The table given below provides a listing of the 8 bit registers embedded in the device and
the related addresses:
Table 18.Register address map
Register address
NameType
HexBinary
Reserved-00-0E--
WHO_AM_Ir0F000 1111 11010011
Reserved-10-1F--
CTRL_REG1rw20010 0000 00000111
CTRL_REG2rw21010 0001 00000000
CTRL_REG3rw22010 0010 00000000
CTRL_REG4rw23010 0011 00000000
CTRL_REG5rw24010 0100 00000000
REFERENCErw25010 0101 00000000
OUT_TEMPr26010 0110output
DefaultComment
STATUS_REGr27010 0111output
OUT_X_Lr28010 1000output
OUT_X_Hr29010 1001output
OUT_Y_Lr2A010 1010output
OUT_Y_Hr2B010 1011output
OUT_Z_Lr2C010 1100output
OUT_Z_Hr2D010 1101output
FIFO_CTRL_REGrw2E010 1110 00000000
FIFO_SRC_REGr2F010 1111output
INT1_CFGrw30011 0000 00000000
INT1_SRCr31011 0001output
INT1_TSH_XHrw32011 0010 00000000
INT1_TSH_XLrw33011 0011 00000000
INT1_TSH_YHrw34011 0100 00000000
INT1_TSH_YLrw35011 0101 00000000
INT1_TSH_ZHrw36011 0110 00000000
INT1_TSH_ZLrw37011 0111 00000000
INT1_DURATIONrw38011 1000 00000000
Doc ID 17116 Rev 327/42
Page 28
Output register mappingL3G4200D
Registers marked as Reserved must not be changed. The writing to those registers may
cause permanent damages to the device.
The content of the registers that are loaded at boot should not be changed. They contain the
factory calibration values. Their content is automatically restored when the device is
powered-up.
28/42Doc ID 17116 Rev 3
Page 29
L3G4200DRegister description
7 Register description
The device contains a set of registers which are used to control its behavior and to retrieve
acceleration data. The registers address, made of 7 bits, is used to identify them and to
write the data through serial interface.
7.1 WHO_AM_I (0Fh)
Table 19.WHO_AM_I register
11010011
Device identification register.
7.2 CTRL_REG1 (20h)
Table 20.CTRL_REG1 register
DR1DR0BW1BW0PDZenYenXen
Table 21.CTRL_REG1 description
DR1-DR0Output Data Rate selection. Refer to Table 22
BW1-BW0Bandwidth selection. Refer to Table 22
PD
ZenZ axis enable. Default value: 1
YenY axis enable. Default value: 1
XenX axis enable. Default value: 1
Power down mode enable. Default value: 0
(0: power down mode, 1: normal mode or sleep mode)
(0: Z axis disabled; 1: Z axis enabled)
(0: Y axis disabled; 1: Y axis enabled)
(0: X axis disabled; 1: X axis enabled)
DR<1:0> is used to set ODR selection. BW <1:0> is used to set Bandwidth selection.
In the following table are reported all frequency resulting in combination of DR / BW bits.
Table 22.DR and BW configuration setting
DR <1:0>BW <1:0>ODR [Hz]Cut-Off
000010012.5
000110025
001010025
001110025
Doc ID 17116 Rev 329/42
Page 30
Register descriptionL3G4200D
Table 22.DR and BW configuration setting (continued)
DR <1:0>BW <1:0>ODR [Hz]Cut-Off
010020012.5
010120025
011020050
011120070
100040020
100140025
101040050
1011400110
110080030
110180035
111080050
1111800110
Combination of PD, Zen, Yen, Xen are used to set device in different modes (power down /
normal / sleep mode) according with the following table.
Table 23.Power mode selection configuration
ModePDZenYenXen
Power down0---
Sleep1000
Normal1---
7.3 CTRL_REG2 (21h)
Table 24.CTRL_REG2 register
(1)
0
1. Value loaded at boot. This value must not be changed
AND/OR combination of Interrupt events. Default value: 0
(0: OR combination of interrupt events 1: AND combination of interrupt events
LIR
ZHIE
ZLIE
YHIE
YLIE
XHIE
XLIE
Latch Interrupt Request. Default value: 0
(0: interrupt request not latched; 1: interrupt request latched)
Cleared by reading INT1_SRC reg.
Enable interrupt generation on Z high event. Default value: 0
(0: disable interrupt request; 1: enable interrupt request on measured accel. value
higher than preset threshold)
Enable interrupt generation on Z low event. Default value: 0
(0: disable interrupt request; 1: enable interrupt request on measured accel. value
lower than preset threshold)
Enable interrupt generation on Y high event. Default value: 0
(0: disable interrupt request; 1: enable interrupt request on measured accel. value
higher than preset threshold)
Enable interrupt generation on Y low event. Default value: 0
(0: disable interrupt request; 1: enable interrupt request on measured accel. value
lower than preset threshold)
Enable interrupt generation on X high event. Default value: 0
(0: disable interrupt request; 1: enable interrupt request on measured accel. value
higher than preset threshold)
Enable interrupt generation on X low event. Default value: 0
(0: disable interrupt request; 1: enable interrupt request on measured accel. value
lower than preset threshold)
Configuration register for Interrupt source.
7.16 INT1_SRC (31h)
Table 50.INT1_SRC register
0 IA ZHZLYHYLXHXL
36/42Doc ID 17116 Rev 3
Page 37
L3G4200DRegister description
Table 51.INT1_SRC description
IA
ZHZ high. Default value: 0 (0: no interrupt, 1: Z High event has occurred)
ZLZ low. Default value: 0 (0: no interrupt; 1: Z Low event has occurred)
YHY high. Default value: 0 (0: no interrupt, 1: Y High event has occurred)
YLY low. Default value: 0 (0: no interrupt, 1: Y Low event has occurred)
XHX high. Default value: 0 (0: no interrupt, 1: X High event has occurred)
XLX low. Default value: 0 (0: no interrupt, 1: X Low event has occurred)
Interrupt active. Default value: 0
(0: no interrupt has been generated; 1: one or more interrupts have been generated)
Interrupt source register. Read only register.
Reading at this address clears INT1_SRC IA bit (and eventually the interrupt signal on INT1
pin) and allows the refreshment of data in the INT1_SRC register if the latched option was
chosen.
D6 - D0 bits set the minimum duration of the Interrupt event to be recognized. Duration
steps and maximum values depend on the ODR chosen.
WAI T bit has the following meaning:
Wait =’0’: the interrupt falls immediately if signal crosses the selected threshold
38/42Doc ID 17116 Rev 3
Page 39
L3G4200DRegister description
Wait =’1’: if signal crosses the selected threshold, the interrupt falls only after the duration
has counted number of samples at the selected data rate, written into the duration counter
register.
Figure 20. Wait disabled
Figure 21. Wait enabled
Doc ID 17116 Rev 339/42
Page 40
Package informationL3G4200D
8 Package information
In order to meet environmental requirements, ST offers these devices in different grades of
ECOPACK
specifications, grade definitions and product status are available at www.st.com.
ECOPACK is an ST trademark.
Figure 22. LGA-16: mechanical data and package dimensions
®
packages, depending on their level of environmental compliance. ECOPACK®
40/42Doc ID 17116 Rev 3
Page 41
L3G4200DRevision history
9 Revision history
Table 66.Document revision history
DateRevisionChanges
01-Apr-20101Initial release.
03-Sep-20102Complete datasheet review.
22-Dec-20103
Inserted Section 6: Output register mapping and Section 7: Register
description.
Doc ID 17116 Rev 341/42
Page 42
L3G4200D
Please Read Carefully:
Information in this document is provided solely in connection with ST products. STMicroelectronics NV and its subsidiaries (“ST”) reserve the
right to make changes, corrections, modifications or improvements, to this document, and the products and services described herein at any
time, without notice.
All ST products are sold pursuant to ST’s terms and conditions of sale.
Purchasers are solely responsible for the choice, selection and use of the ST products and services described herein, and ST assumes no
liability whatsoever relating to the choice, selection or use of the ST products and services described herein.
No license, express or implied, by estoppel or otherwise, to any intellectual property rights is granted under this document. If any part of this
document refers to any third party products or services it shall not be deemed a license grant by ST for the use of such third party products
or services, or any intellectual property contained therein or considered as a warranty covering the use in any manner whatsoever of such
third party products or services or any intellectual property contained therein.
UNLESS OTHERWISE SET FORTH IN ST’S TERMS AND CONDITIONS OF SALE ST DISCLAIMS ANY EXPRESS OR IMPLIED
WARRANTY WITH RESPECT TO THE USE AND/OR SALE OF ST PRODUCTS INCLUDING WITHOUT LIMITATION IMPLIED
WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE (AND THEIR EQUIVALENTS UNDER THE LAWS
OF ANY JURISDICTION), OR INFRINGEMENT OF ANY PATENT, COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT.
UNLESS EXPRESSLY APPROVED IN WRITING BY AN AUTHORIZED ST REPRESENTATIVE, ST PRODUCTS ARE NOT
RECOMMENDED, AUTHORIZED OR WARRANTED FOR USE IN MILITARY, AIR CRAFT, SPACE, LIFE SAVING, OR LIFE SUSTAINING
APPLICATIONS, NOR IN PRODUCTS OR SYSTEMS WHERE FAILURE OR MALFUNCTION MAY RESULT IN PERSONAL INJURY,
DEATH, OR SEVERE PROPERTY OR ENVIRONMENTAL DAMAGE. ST PRODUCTS WHICH ARE NOT SPECIFIED AS "AUTOMOTIVE
GRADE" MAY ONLY BE USED IN AUTOMOTIVE APPLICATIONS AT USER’S OWN RISK.
Resale of ST products with provisions different from the statements and/or technical features set forth in this document shall immediately void
any warranty granted by ST for the ST product or service described herein and shall not create or extend in any manner whatsoever, any
liability of ST.
ST and the ST logo are trademarks or registered trademarks of ST in various countries.
Information in this document supersedes and replaces all information previously supplied.
The ST logo is a registered trademark of STMicroelectronics. All other names are the property of their respective owners.