self-balancing-robot
Dependencies: mbed mbed-rtos Motor
Diff: main.cpp
- Revision:
- 14:f9c2cf6643cf
- Parent:
- 13:8d8ac3189984
- Child:
- 15:f0f19572c4a5
--- a/main.cpp Sat Apr 18 21:46:34 2020 +0000 +++ b/main.cpp Sat Apr 18 22:03:15 2020 +0000 @@ -136,6 +136,7 @@ void get_current_angle() { // return; imu.readGyro(); + pc.printf("gyro: %d %d %d\n\r", imu.gx, imu.gy, imu.gz); } @@ -150,7 +151,7 @@ Thread bluetooth; Thread system_update; -// imu.begin(); + imu.begin(); bluetooth.start(bluetooth_update); system_update.start(update_system); @@ -163,7 +164,7 @@ parametersmutex.unlock(); get_current_angle(); - pc.printf("gyro: %d %d %d\n\r", imu.gx, imu.gy, imu.gz); + Thread::wait(100); }