mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2026-09-23 04:04:15 +08:00
[bsp][renesas] RTduino configuration update
sync update some optimize [bsp][driver] Updates the naming convention of the i2c configuration item
This commit is contained in:
@@ -51,7 +51,7 @@ struct swm_soft_i2c_cfg
|
||||
struct swm_soft_i2c_device
|
||||
{
|
||||
struct rt_i2c_bit_ops ops;
|
||||
struct rt_i2c_bus_device i2c2_bus;
|
||||
struct rt_i2c_bus_device i2c_bus;
|
||||
};
|
||||
|
||||
static const struct swm_soft_i2c_cfg swm_soft_i2c_cfg[] =
|
||||
@@ -201,9 +201,9 @@ int swm_i2c_init(void)
|
||||
{
|
||||
i2c_obj[i].ops = swm_i2c_bit_ops;
|
||||
i2c_obj[i].ops.data = (void *)&swm_soft_i2c_cfg[i];
|
||||
i2c_obj[i].i2c2_bus.priv = &i2c_obj[i].ops;
|
||||
i2c_obj[i].i2c_bus.priv = &i2c_obj[i].ops;
|
||||
swm_i2c_gpio_init(&i2c_obj[i]);
|
||||
result = rt_i2c_bit_add_bus(&i2c_obj[i].i2c2_bus, swm_soft_i2c_cfg[i].name);
|
||||
result = rt_i2c_bit_add_bus(&i2c_obj[i].i2c_bus, swm_soft_i2c_cfg[i].name);
|
||||
RT_ASSERT(result == RT_EOK);
|
||||
|
||||
LOG_D("software simulation %s init done, pin scl: %d, pin sda %d",
|
||||
|
||||
Reference in New Issue
Block a user