LOGIN
North eugene
8
Top Contributor
Designer special solution && automation , Software engneering student , Robotics developer
Share
Report
Get Link
HELLO

If programmer has any thing else to do , even while he is eating , Then he made a wrong choice . As programming is a a possessive emotion and does not allow any other emotion , that is why a programmer has a Life beyond the horizons , OR he has no life

Internships
Currently a Student
Join Projects
Start a Project
3 likes 
Like
Award Contribution
North eugene
8
Top Contributor
Designer special solution && automation , Software engneering student , Robotics developer
Share
Report
Get Link
Works fine but fusion with PID will be a task

#include <Wire.h>
#include <GY80.h>

GY80 sensor = GY80(); //create GY80 instance

void setup()
{
   // initialize serial communication at 115200 bits per second:
   Serial.begin(115200);
   sensor.begin();       //initialize sensors
}


void loop()
{
   GY80_scaled val = sensor.read_scaled();       //get values from all sensors
   // print out values

   Serial.print("Mag:");                         //magnetometer values
   Serial.print(val.m_x,2);
   Serial.print(',');
   Serial.print(val.m_y,2);
   Serial.print(',');
   Serial.print(val.m_z,2);
   Serial.print(' ');
   Serial.print("Acc:");                         //accelerometer values
   Serial.print(val.a_x,3);
   Serial.print(',');
   Serial.print(val.a_y,3);
   Serial.print(',');
   Serial.print(val.a_z,3);
   Serial.print(' ');
   Serial.print("Gyro:");                        //gyroscope values
   Serial.print(val.g_x,1);
   Serial.print(',');
   Serial.print(val.g_y,1);
   Serial.print(',');
   Serial.print(val.g_z,1);
   Serial.print(' ');
   Serial.print("P:");                           //pressure values
   Serial.print(val.p,5);
   Serial.print(' ');
   Serial.print("T:");                           //temperature values
   Serial.println(val.t,1);


   delay(250);        // delay in between reads for stability
}



Like
1 like 
Award Contribution
Leave a reply...
DISCOVER
CHAT
HIRE
ACTIVITY
FEED
New Post
Help
Start Project
Online Users
Share Link