from machine import Pin, ADC, I2C
from utime import sleep, sleep_ms
from MPU6050 import MPU6050
i2c = I2C(scl=Pin(9), sda=Pin(8))
print("Dirección:", i2c.scan())
mpu = MPU6050(i2c)
while True:
tem = mpu.read_temperature()
gyro = mpu.read_gyro_data()
acel = mpu.read_accel_data()
ax= acel[0]
ay= acel[1]
az= acel[2]
print("AX:{:.1f}g, AY:{:.1f}g, AZ:{:.1f}g".format( ax, ay, az))
sleep(1)