How to Interface the GY-521 Module with evive

Description
Learn how to interface the GY-521 module with evive in this tutorial. Discover how to display the readings of the accelerometer, gyroscope, and temperature sensor on the serial monitor and integrate the GY-521 module for various applications.

Introduction

This tutorial explains how to interface the GY-521 module with evive. The module has MPU6050 on it, which has a 3-axis accelerometer, a 3-axis gyroscope, and a Digital Motion Processor on it. This module works on the principle of MEMS(Micro electro-mechanical system).

Before running into the details of working with the module, first, we should have an idea about what an accelerometer or a gyroscope is. Starting with the accelerometer: it gives a measure of acceleration along all 3 axes- x,y, and z. Every accelerometer module has a micro-electromechanical structure that suffers a displacement due to acceleration this displacement is sensed in terms of a change in capacitance which changes out voltage given by the accelerometer unit. The GY-521 module has registers that store the acceleration value of all axes.

Similarly, the gyroscope gives the amount of rotation along each of the x,y, and z-axes. Rotation along x,y, and z-axes are popularly known as roll, pitch, and yaw respectively. The Gyroscope sensor also has a special structure that vibrates due to the rotation of the sensor leading to a change in the capacitance and hence output voltage changes.

Applications

  • Navigation
  • Automobiles
  • Robotics
  • Smartphones
  • Aircrafts

Circuit Diagram

  • Connect “VCC” of GY-521 with “VCC” of evive
  • Connect “GND” of GY-521 with “GND” of evive
  • Connect “SDA”  of GY-521 with “SDA” of evive (Serial data)
  • Connect “SCL” of GY-521 with “SCL” of evive (Serial clock)

Arduino Code

This code demonstrates the Interfacing of the GY-521 module with evive. We are going to display the readings of the accelerometer, Gyroscope, and temperature sensor on the serial monitor. In this code, we have used the Wire library which is used for “I2C” communication (Inter-Integrated Circuit communication)

Expected Result

Conclusion

In conclusion, this lesson showed how to interface the GY-521 module with evive using the Wire library. This module is useful for navigation, robotics, automobiles, smartphones, and aircraft. It has a 3-axis accelerometer, a 3-axis gyroscope, and a digital motion processor. The Arduino code demonstrated how to display the readings of the accelerometer, gyroscope, and temperature sensor on the serial monitor. With the knowledge of this lesson, you are now able to integrate the GY-521 module with evive for various applications.

Table of Contents