修复i2c通讯异常时的返回信息

This commit is contained in:
2023-08-01 16:47:37 +08:00
parent 42077a3529
commit 851d6436a7

View File

@ -78,7 +78,7 @@ rt_size_t rt_i2c_transfer(struct rt_i2c_bus_device *bus,
{
LOG_E("I2C bus operation not supported");
return 0;
return -RT_EIO;
}
}
@ -98,7 +98,7 @@ rt_err_t rt_i2c_control(struct rt_i2c_bus_device *bus,
{
LOG_E("I2C bus operation not supported");
return 0;
return -RT_EIO;
}
}