|
@@ -8,9 +8,9 @@
|
|
|
* 2019-10-23 yuzrain the first version
|
|
|
*/
|
|
|
|
|
|
-#include <rthw.h>
|
|
|
#include <rtthread.h>
|
|
|
#include <rtdevice.h>
|
|
|
+#include <rtdbg.h>
|
|
|
#include "board.h"
|
|
|
#include "drv_i2c.h"
|
|
|
#include "md_i2c.h"
|
|
@@ -159,7 +159,7 @@ static rt_size_t es32f0_master_xfer(struct rt_i2c_bus_device *bus,
|
|
|
{
|
|
|
if (__i2c_master_recv(bus->priv, msg->addr << 1, msg->buf, msg->len, TIMEOUT) != 0)
|
|
|
{
|
|
|
- i2c_dbg("i2c bus write failed,i2c bus stop!\n");
|
|
|
+ LOG_E("i2c bus write failed,i2c bus stop!\n");
|
|
|
goto out;
|
|
|
}
|
|
|
}
|
|
@@ -167,7 +167,7 @@ static rt_size_t es32f0_master_xfer(struct rt_i2c_bus_device *bus,
|
|
|
{
|
|
|
if (__i2c_master_send(bus->priv, msg->addr << 1, msg->buf, msg->len, TIMEOUT) != 0)
|
|
|
{
|
|
|
- i2c_dbg("i2c bus write failed,i2c bus stop!\n");
|
|
|
+ LOG_E("i2c bus write failed,i2c bus stop!\n");
|
|
|
goto out;
|
|
|
}
|
|
|
}
|
|
@@ -176,7 +176,7 @@ static rt_size_t es32f0_master_xfer(struct rt_i2c_bus_device *bus,
|
|
|
ret = i;
|
|
|
|
|
|
out:
|
|
|
- i2c_dbg("send stop condition\n");
|
|
|
+ LOG_E("send stop condition\n");
|
|
|
|
|
|
return ret;
|
|
|
}
|