Skip to content

Commit f90465b

Browse files
Minh Tangquytranpzz
authored andcommitted
boards: renesas: Add support CTSU for RSK-RX130 board
Add Pinctrl, status okay for CTSU node on RSK-RX130 Signed-off-by: Minh Tang <[email protected]>
1 parent 8d77541 commit f90465b

File tree

2 files changed

+67
-0
lines changed

2 files changed

+67
-0
lines changed

boards/renesas/rsk_rx130/rsk_rx130.dts

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,10 @@
8181
status = "okay";
8282
};
8383

84+
&ioportc {
85+
status = "okay";
86+
};
87+
8488
&ioportd {
8589
status = "okay";
8690
};
@@ -113,6 +117,58 @@
113117
clock-frequency = <DT_FREQ_K(400)>;
114118
};
115119

120+
&ctsu {
121+
pinctrl-0 = <&ctsu_default>;
122+
pinctrl-names = "default";
123+
max-num-sensors = <36>;
124+
tscap-gpios = <&ioportc 4 0>;
125+
status = "okay";
126+
127+
onboard_slider: touch_slider_0 {
128+
component-type = "slider";
129+
ssdiv = <1>;
130+
so = <0x040>;
131+
snum = <0x03>;
132+
sdpa = <0x07>;
133+
channels-num = <10>, <9>, <8>, <7>;
134+
zephyr,code = <INPUT_ABS_THROTTLE>;
135+
touch-count-threshold = <750>;
136+
137+
sld0 {
138+
compatible = "renesas,rx-ctsu-slider";
139+
status = "okay";
140+
};
141+
};
142+
143+
onboard_button_1: touch_button_1 {
144+
component-type = "button";
145+
ssdiv = <0x0>;
146+
snum = <0x07>;
147+
sdpa = <0x03>;
148+
channels-num = <11>;
149+
zephyr,code = <INPUT_KEY_1>;
150+
151+
button1 {
152+
compatible = "renesas,rx-ctsu-button";
153+
status = "okay";
154+
};
155+
};
156+
157+
onboard_button_2: touch_button_2 {
158+
component-type = "button";
159+
ssdiv = <0x0>;
160+
snum = <0x07>;
161+
sdpa = <0x03>;
162+
channels-num = <12>;
163+
zephyr,code = <INPUT_KEY_2>;
164+
165+
button2 {
166+
compatible = "renesas,rx-ctsu-button";
167+
status = "okay";
168+
};
169+
};
170+
};
171+
116172
&port_irq1 {
117173
status = "okay";
118174
};

boards/renesas/rsk_rx130/rsk_rx130_512kb-pinctrl.dtsi

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,15 @@
4141
renesas,analog-enable;
4242
};
4343
};
44+
ctsu_default: ctsu_default {
45+
group1 {
46+
psels = <RX_PSEL(RX_PSEL_PHnPFS_TS7, 0x11, 3)>,
47+
<RX_PSEL(RX_PSEL_PHnPFS_TS8, 0x11, 2)>,
48+
<RX_PSEL(RX_PSEL_PHnPFS_TS9, 0x11, 1)>,
49+
<RX_PSEL(RX_PSEL_PHnPFS_TS10, 0x11, 0)>,
50+
<RX_PSEL(RX_PSEL_P5nPFS_TS11, 0x05, 5)>,
51+
<RX_PSEL(RX_PSEL_P5nPFS_TS12, 0x05, 4)>,
52+
<RX_PSEL(RX_PSEL_PCnPFS_TSCAP, 0x0c, 4)>;
53+
};
54+
};
4455
};

0 commit comments

Comments
 (0)