Digilent Pmodgyro 3-axis Gyroscope User Manual

PmodGYRO 3-Axis Gyroscope

Product Information

The PmodGYRO is a 3-axis gyroscope powered by the
STMicroelectronics L3G4200D. It is designed to provide motion
sensing data on each of the three Cartesian axes. The module can be
configured to report angular momentum at a resolution of up to 2000
dps (degrees per second) at an output rate of up to 800Hz. It
features a 3-axis MEMS digital gyroscope with high shock
survivability and user-selectable resolution (250/500/2000dps).

Product Usage Instructions

To interface with the PmodGYRO, you can use either SPI or I2C
communication protocols. The module communicates with the ST
L3G4200D gyroscope chip to retrieve motion sensing data.

Interfacing with the Pmod

The PmodGYRO has two headers, J1 and J2, which provide the
pinout for connection. The pinout description table is as
follows:

HeaderPinSignalDescription
J11~CSChip Select
2MOSIMaster-Out-Slave-In
3MISOMaster-In-Slave-Out
4SCLKSerial Clock
5GNDPower Supply Ground
6VCCPositive Power Supply (3.3V)
J21, 5SCLSerial Clock
2, 6SDASerial Data
3, 7GNDPower Supply Ground
4, 8VCCPositive Power Supply (3.3V)

Note: Any external power applied to the PmodGYRO must be within
the range of 2.4V and 3.6V, although it is recommended to operate
the Pmod at 3.3V.

Data Retrieval

The measured data from the gyroscope is recorded and stored in
the registers of the L3G4200D in degrees per second (dps). A
measured value of 360 dps is equivalent to 60 rpm. You can retrieve
the data from the PmodGYRO by following the provided code example
in the user manual.

PmodGYROTM Reference Manual
Revised April 12, 2016 This manual applies to the PmodGYRO rev. A

1300 Henley Court Pullman, WA 99163
509.334.6306 www.digilentinc.com

Overview
The PmodGYRO is a 3-axis gyroscope powered by the STMicroelectronics L3G4200D. By communicating with the chip through SPI or I2C, users may configure the module to report angular momentum at a resolution of up to 2000 dps at an output rate up to 800Hz.

The PmodGYRO.

Features include:
3-axis MEMS digital gyroscope with high shock survivability
Get angular momentum data with user selectable resolution (250/500/2000dps)
Two customizable interrupt pins User configurable signal filtering Power-down and Sleep modes Small PCB size for flexible designs 1.0 in × 0.8 in
(2.5 cm × 2.0 cm) 12-pin Pmod port with SPI interface and
additional I²C interface Library and example code available in resource
center

1 Functional Description
The PmodGYRO utilizes ST L3G4200D gyroscope to provide motion sensing data on each of the three Cartesian axes. Users may configure both the resolution and filtering options for the measured data.

2 Interfacing with the Pmod
The PmodGYRO communicates with the host board via the SPI or I²C protocols. By driving the Chip Select (CS) line to a logic low voltage state, SPI mode is enabled. The first byte sent over SPI informs the on-board chip if a read or write command is going to be issued, if the register address should be incremented after a particular command has been completed, and the 5 bit address of the register that is to be written to.
An example timing diagram for SPI read and writes from the L3G4200D datasheet is provided below:

DOC#: 502-215
Downloaded from Arrow.com.

Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.

Page 1 of 3

PmodGYROTM Reference Manual

Figure 1. Timing diagram.
Correspondingly, if the CS line is left at a high voltage state by an internal pull-up resistor, the I²C mode of the PmodGYRO is enabled. The on-board chip has two possible slave address in the form of 110100x where x is the voltage state of the Master-In-Slave-Out (MISO) pin on the SPI header. After the slave address and the read or write bit has been transmitted and the message was acknowledged, a 7-bit register address can then be transmitted. The most significant bit (the first bit of the 8-bit of the transfer) indicates if multiple bytes of information are to be transferred.
An example transfer scheme for a master device reading multiple bytes of data from the PmodGYRO is provided below:

Master Start Slave address and Write bit
Multi-byte bit and register address
Restart Slave address and read bit
ACK
ACK
NACK Stop

Slave
ACK ACK
ACK Data Data Data

Table 1. Example transfer scheme.
Data is recorded and stored within the registers of the L3G4200D in degrees per second (dps). Correspondingly, a measured value of 360 dps is equivalent to 60 rpm. Users can retrieve data from the PmodGYRO by following the provided code example.

Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Downloaded from Arrow.com.

Page 2 of 3

PmodGYROTM Reference Manual
2.1 Pinout Description Table

Header J1

Pin Signal Description

Pin Signal Description

1 ~CS Chip Select

7 INT1 Interrupt 1

2

MOSI

Master-Out-SlaveIn

8

INT2 Interrupt 2

3

MISO

Master-In-SlaveOut

9 (NC) Not Connected

4 SCLK Serial Clock

10 (NC) Not Connected

5

GND

Power Supply Ground

6

VCC

Positive Power Supply (3.3V)

11 GND 12 VCC

Power Supply Ground
Positive Power Supply (3.3V)

Header J2

Pin Signal Description

1, 5

SCL

Serial Clock

2, 6

SDA

Serial Data

3, 7

GND

Power Supply Ground

4, 8

VCC

Positive Power Supply (3.3V)

Table 2. Pinout description table.
Any external power applied to the PmodGYRO must be within 2.4V and 3.6V; however, it is recommended that Pmod is operated at 3.3V.

3 Physical Dimensions
The pins on the pin header are spaced 100 mil apart. The PCB is 1 inch long on the sides parallel to the pins on the pin header and 0.8 inches long on the sides perpendicular to the pin header.

Copyright Digilent, Inc. All rights reserved. Other product and company names mentioned may be trademarks of their respective owners.
Downloaded from Arrow.com.

Page 3 of 3

References

Documents / Resouces

Download manual
Here you can download full pdf version of manual, it may contain additional safety instructions, warranty information, FCC rules, etc.


Related Manuals