redo examples

This commit is contained in:
shrkey
2016-10-04 22:41:57 +01:00
parent fd9c62fc6a
commit 039ca68b27
5 changed files with 33 additions and 14 deletions

View File

@@ -29,7 +29,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import spidev
import time
import sys
from darkwater_640.mpu9250 import MPU9250
from darkwater_640 import MPU9250
imu = MPU9250()
@@ -58,8 +58,8 @@ while True:
m9a, m9g, m9m = imu.getMotion9()
print("Acc:", "{:+7.3f}".format(m9a[0]), "{:+7.3f}".format(m9a[1]), "{:+7.3f}".format(m9a[2]), end=" ")
print(" Gyr:", "{:+8.3f}".format(m9g[0]), "{:+8.3f}".format(m9g[1]), "{:+8.3f}".format(m9g[2]), end=" ")
print(" Mag:", "{:+7.3f}".format(m9m[0]), "{:+7.3f}".format(m9m[1]), "{:+7.3f}".format(m9m[2]) )
print("Acc:", "{:+7.3f}".format(m9a[0]), "{:+7.3f}".format(m9a[1]), "{:+7.3f}".format(m9a[2]) )
print("Gyr:", "{:+8.3f}".format(m9g[0]), "{:+8.3f}".format(m9g[1]), "{:+8.3f}".format(m9g[2]) )
print("Mag:", "{:+7.3f}".format(m9m[0]), "{:+7.3f}".format(m9m[1]), "{:+7.3f}".format(m9m[2]) )
time.sleep(0.5)