Tag Archives: GY-87

Plotting X-Y-Z Magnetometer Data for Accurate Calibration

In this video lesson we create a PyQt5 Widget in Python to help calibrate the QMC5883L 3-Axis Magnetometer on the GY-87 module. The Widget plots the data coming from the Magnetometer in real time to allow more accurate calibration.

This is the circuit schematic for our project:

MPU6050
Schematic for connecting the GY-87 module to the Arduino

This is the simple code for the arduino to generate the raw data;

This is the code we run on the Python side to plot the raw data:

 

Using the QMC5883L Magnetometers on the GY-87 Module

In this video lesson we activate the QMC5883L 3-axis magnetometer on our GY-87 module. We show how to read the raw magnetic field strength in the x, y, and z axis. Your homework assignment will be to then calibrate the measurements such that you center the measured values around 0, and create a unit circle. This calibration will be very similar to what we did for the accelerometers a few weeks ago. This is the schematic we continue to use in this lesson:

MPU6050
Schematic for connecting the GY-87 module to the Arduino

This is the code we developed in todays lesson to read the raw data from the magnetometers.

 

Using Arduino and MPU6050 to Measure Rotational Velocity with the Gyros

In this video lesson I show you how you can measure rotational velocity using the gyroscopes on the MPU6050 IMU module on the GY-87 board.

MPU6050
Schematic for connecting the GY-87 module to the Arduino

Below is the code which we develop in this lesson.

 

Applying a Low Pass Filter to Roll and Pitch Calculations on the MPU6050

In today’s video lesson we show how you can remove the vibration noise from your roll and pitch values using a low pass filter. The filter removes the high frequency noise resulting from vibrations.

MPU6050
Schematic for connecting the GY-87 module to the Arduino

Below is the code we developed in this lesson.

 

Using Arduino to Calibrate the MPU6050 Accelerometers

In this video lesson we show you how to calibrate the accelerometers on the MPU6050. You will have to find the min and max accelerometer numbers for your particular board, but I show you how in the video. Below, we show the schematic of how our circuit is connected.

MPU6050
Schematic for connecting the GY-87 module to the Arduino

In the lesson we developed the following code. Measure your min and max values of the three accelerometers according to the instructions in the video. Then enter those numbers in the code below, and un-comment out the commented lines. If you run the code as-is below, it should work, but the results will be uncalibrated and not as accurate as possible.