Skip to content

drivers: i2c: Add I2C driver support for Renesas RX #89553

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions boards/renesas/rsk_rx130/rsk_rx130.dts
Original file line number Diff line number Diff line change
Expand Up @@ -81,3 +81,10 @@
status = "okay";
};
};

&i2c0 {
pinctrl-0 = <&i2c0_default>;
pinctrl-names = "default";
clock-frequency = <DT_FREQ_K(400)>;
status = "okay";
};
8 changes: 7 additions & 1 deletion boards/renesas/rsk_rx130/rsk_rx130_512kb-pinctrl.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,16 @@
*/

&pinctrl {
sci1_default: sci1_default {
sci1_default: sci1_default {
group1 {
psels = <RX_PSEL(RX_PSEL_SCI_1, 2, 6)>, /* TX */
<RX_PSEL(RX_PSEL_SCI_1, 3, 0)>; /* RX */
};
};
i2c0_default: i2c0_default {
group1 {
psels = <RX_PSEL(RX_PSEL_P1nPFS_SDA, 1, 3)>, /* SDA P13*/
<RX_PSEL(RX_PSEL_P1nPFS_SCL, 1, 2)>; /* SCL P12*/
};
};
};
1 change: 1 addition & 0 deletions boards/renesas/rsk_rx130/rsk_rx130_512kb.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ supported:
- gpio
- serial
- timer
- i2c
ram: 48
flash: 512
1 change: 1 addition & 0 deletions drivers/i2c/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ zephyr_library_sources_ifdef(CONFIG_I2C_OMAP i2c_omap.c)
zephyr_library_sources_ifdef(CONFIG_I2C_RCAR i2c_rcar.c)
zephyr_library_sources_ifdef(CONFIG_I2C_RENESAS_RA_IIC i2c_renesas_ra_iic.c)
zephyr_library_sources_ifdef(CONFIG_I2C_RENESAS_RA_SCI_B i2c_renesas_ra_sci_b.c)
zephyr_library_sources_ifdef(CONFIG_I2C_RENESAS_RX_RIIC i2c_renesas_rx_riic.c)
zephyr_library_sources_ifdef(CONFIG_I2C_RENESAS_RZ_RIIC i2c_renesas_rz_riic.c)
zephyr_library_sources_ifdef(CONFIG_I2C_RV32M1_LPI2C i2c_rv32m1_lpi2c.c)
zephyr_library_sources_ifdef(CONFIG_I2C_SAM0 i2c_sam0.c)
Expand Down
1 change: 1 addition & 0 deletions drivers/i2c/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ source "drivers/i2c/Kconfig.numaker"
source "drivers/i2c/Kconfig.omap"
source "drivers/i2c/Kconfig.rcar"
source "drivers/i2c/Kconfig.renesas_ra"
source "drivers/i2c/Kconfig.renesas_rx"
source "drivers/i2c/Kconfig.renesas_rz"
source "drivers/i2c/Kconfig.sam0"
source "drivers/i2c/Kconfig.sam_twihs"
Expand Down
20 changes: 20 additions & 0 deletions drivers/i2c/Kconfig.renesas_rx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Renesas RX Family

# Copyright (c) 2025 Renesas Electronics Corporation
# SPDX-License-Identifier: Apache-2.0

config I2C_RENESAS_RX_RIIC
bool "Renesas RX I2C Master"
default y
depends on DT_HAS_RENESAS_RX_I2C_ENABLED
select USE_RX_RDP_I2C
select PINCTRL
help
Enable Renesas RX I2C Driver.

config I2C_RENESAS_RX_CALLBACK
bool "Renesas RX I2C Callback Support"
depends on I2C_CALLBACK && I2C_RENESAS_RX_RIIC
default y
help
Enable Callback support for the I2C Driver
Loading
Loading