Dydaktyka
Dependencies: FastPWM mbed-src
Fork of 2015_04_17_quadro_bez_sterowania by
Diff: Offsets.cpp
- Revision:
- 12:e955cc086c42
- Parent:
- 10:605b0bfadc2e
--- a/Offsets.cpp Fri Apr 17 07:48:05 2015 +0000 +++ b/Offsets.cpp Fri Apr 17 14:25:25 2015 +0000 @@ -31,7 +31,7 @@ float d[9]; float yaw; - sprintf(buff, "Hello!\n\rPlace Qudrocopter motionlessly and press o\n\r"); + sprintf(buff, "Hello!\n\rPlace Qudrocopter motionlessly and press a\n\r"); serial.printf(buff); do{ if(serial.readable()){ @@ -56,10 +56,6 @@ offsetGyr[2]/=1000; yaw = yaw/1000; - //o[0] = offsetGyr[0]; - //o[1] = offsetGyr[1]; - //o[2] = offsetGyr[2]; - // lub tak: *(o+0) = offsetGyr[0]; *(o+1) = offsetGyr[1]; *(o+2) = offsetGyr[2]; @@ -87,9 +83,6 @@ void Offsets::offsetData(float *d, float *D, float *O) { - /*for (int i=0; i<3; i++) { - O[i] = d[i]-D[i]; - }*/ O[0] = d[0]-D[0]; O[1] = d[1]-D[1]; O[2] = d[2]-D[2]; @@ -97,9 +90,6 @@ void Offsets::offsetData2(double *d, float *D, float *O) { - /*for (int i=0; i<3; i++) { - O[i] = d[i]-D[i]; - }*/ O[0] = d[0]-D[0]; O[1] = d[1]-D[1]; O[2] = d[2]-D[2]; @@ -107,8 +97,5 @@ void Offsets::offsetMagneto(float *d, float *D, float *O) { - /*for (int i=0; i<3; i++) { - O[i] = d[i]-D[i]; - }*/ O[0] = d[0]-D[0]; } \ No newline at end of file