FreeIMU demo program for mbed
Dependencies: FreeIMU mbed-rtos mbed
Revision 3:39f5e2c1af36, committed 2018-03-29
- Comitter:
- tyftyftyf
- Date:
- Thu Mar 29 22:35:55 2018 +0000
- Parent:
- 2:a3bdc53fab66
- Commit message:
- parameter tuning
Changed in this revision
diff -r a3bdc53fab66 -r 39f5e2c1af36 FreeIMU.lib --- a/FreeIMU.lib Fri Jan 10 05:53:34 2014 +0000 +++ b/FreeIMU.lib Thu Mar 29 22:35:55 2018 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/users/tyftyftyf/code/FreeIMU/#a79af1283446 +http://mbed.org/users/tyftyftyf/code/FreeIMU/#de24fce0509a
diff -r a3bdc53fab66 -r 39f5e2c1af36 main.cpp --- a/main.cpp Fri Jan 10 05:53:34 2014 +0000 +++ b/main.cpp Thu Mar 29 22:35:55 2018 +0000 @@ -18,7 +18,7 @@ void getIMUdata(void const *n){ i++; - if (i%10==0){ + if (i%20==0){ float *q = (float *)imu_queue.alloc(); t.reset(); t.start(); @@ -34,11 +34,16 @@ } int main() { + pc.baud(115200); imu.init(true); - pc.baud(115200); RtosTimer IMUTimer(getIMUdata, osTimerPeriodic, (void *)0); IMUTimer.start(2); t2.start(); + int16_t raw_values[9]; + + Thread::wait(10); + + pc.printf("Init\r\n"); while (true) { t2.reset(); @@ -47,7 +52,6 @@ imu_t *obj = (imu_t*)evt.value.p; pc.printf("Y: %f, P: %f, R: %f, Alt: %f, Temp: %fC\r\n", obj->ypr[0], obj->ypr[1], obj->ypr[2], obj->alt, obj->temp); imu_queue.free(obj); - pc.printf("\r\n"); } } }
diff -r a3bdc53fab66 -r 39f5e2c1af36 mbed-rtos.lib --- a/mbed-rtos.lib Fri Jan 10 05:53:34 2014 +0000 +++ b/mbed-rtos.lib Thu Mar 29 22:35:55 2018 +0000 @@ -1,1 +1,1 @@ -https://mbed.org/users/mbed_official/code/mbed-rtos/#29007aef10a4 +http://mbed.org/users/mbed_official/code/mbed-rtos/#5713cbbdb706
diff -r a3bdc53fab66 -r 39f5e2c1af36 mbed.bld --- a/mbed.bld Fri Jan 10 05:53:34 2014 +0000 +++ b/mbed.bld Thu Mar 29 22:35:55 2018 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/users/mbed_official/code/mbed/builds/f37f3b9c9f0b \ No newline at end of file +http://mbed.org/users/mbed_official/code/mbed/builds/994bdf8177cb \ No newline at end of file