get attitude(roll,pitch,yaw) by Nucleo-F303K8 and MPU9250.

Dependencies:   mbed

Fork of MPU9250 by Ilia Manenok

main.cpp

Committer:
gitakichi
Date:
2016-08-06
Revision:
3:15a3bd361cb3
Parent:
2:855c83d4c7d6

File content as of revision 3:15a3bd361cb3:

#include "mbed.h"
#include "attitude.h"

Serial pc(USBTX, USBRX); // tx, rx

int main()
{
    pc.baud(9600);
    attitude_setup();

    while(1) {
        attitude_get();
        pc.printf("Yaw,   Pitch,   Roll:  %.0f  %.0f  %.0f \n\r",  yaw,   pitch,   roll);
    }

}