MPU6050 and hmc5883l

The hmc5883l on the GY-87 board is only reachable through the MPU6050 chip

SO YOU HAVE TO ACTIVATE BYPASS ON THE MPU6050:

#include <Wire.h>
#include <MPU6050.h>
#include <hmc5883l.h>

MPU6050 mpu;  // we need the MPU6050
void setup()
{
  Wire.begin();
  mpu.begin(); //initalise MPU6050
  mpu.setI2CBypassEnabled(true); // and activate Bypass
  // hereafter hmc5883l code
