Skip to content

Commit ff8c890

Browse files
committed
Add formatting
1 parent 19a39bb commit ff8c890

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

donkeycar/parts/imu.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,8 +158,9 @@ def shutdown(self):
158158
p = Mpu6050Ada()
159159
while True:
160160
try:
161-
data = p.run()
162-
print(data)
161+
accel, gyro = p.run()
162+
print(f"accel: ", ",".join(f"{x:+5.4f}" for x in accel),
163+
" gyro: ", ",".join(f"{x:+5.4f}" for x in gyro))
163164
time.sleep(0.05)
164165
count += 1
165166
except KeyboardInterrupt:

0 commit comments

Comments
 (0)