Simple test application for DMU Library
Dependencies: SiliconSensingDMU mbed
main.cpp
00001 #include "mbed.h" 00002 #include "DMU.h" 00003 00004 DMU dmu(p11, p12, p13, p8, p9, p10); 00005 Serial pc(USBTX, USBRX); 00006 00007 00008 int main() { 00009 dmu.test(); 00010 while(1){ 00011 pc.printf("Y accel:%.1f\n",dmu.acceleration('y')); 00012 pc.printf("X accel:%.1f\n",dmu.acceleration('x')); 00013 pc.printf("Z accel:%.1f\n",dmu.acceleration('z')); 00014 pc.printf("Pitch:%.2f\n",dmu.pitch()); 00015 pc.printf("Roll:%.2f\n",dmu.roll()); 00016 pc.printf("Yaw:%.2f\n",dmu.yaw()); 00017 } 00018 }
Generated on Thu Jul 14 2022 02:41:51 by 1.7.2