Skip to content

Commit afa86e0

Browse files
committed
tests: drivers: i2c_target_api: boards: add support for nucleo_h753zi
- enable i2c2 node in dts - add .conf and .overlay with appropriate configurations for nucleo_h753zi. - update testcase.yaml file for CI testing Signed-off-by: Fabrice DJIATSA <[email protected]>
1 parent be50b68 commit afa86e0

File tree

4 files changed

+38
-1
lines changed

4 files changed

+38
-1
lines changed

boards/st/nucleo_h753zi/nucleo_h753zi.dts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,13 @@ zephyr_udc0: &usbotg_fs {
144144
clock-frequency = <I2C_BITRATE_FAST>;
145145
};
146146

147+
&i2c2 {
148+
pinctrl-0 = <&i2c2_scl_pb10 &i2c2_sda_pb11>;
149+
pinctrl-names = "default";
150+
status = "okay";
151+
clock-frequency = <I2C_BITRATE_FAST>;
152+
};
153+
147154
&timers12 {
148155
st,prescaler = <10000>;
149156
status = "okay";
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
CONFIG_I2C_STM32_INTERRUPT=y
2+
CONFIG_I2C_VIRTUAL=n
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
/* SPDX-License-Identifier: Apache-2.0 */
2+
3+
/* I2C bus pins are exposed on the ST morpho header.
4+
*
5+
* Bus SDA SCL
6+
* Pin Hdr Pin Hdr
7+
* i2c1 PB9 CN7:4 PB8 CN7:2
8+
* i2c2 PB11 CN10:34 PB10 CN10:32
9+
*
10+
* Short Pin PB9 to PB11, and PB8 to PB10, for the test to pass.
11+
*/
12+
13+
&i2c1 {
14+
eeprom0: eeprom@54 {
15+
compatible = "zephyr,i2c-target-eeprom";
16+
reg = <0x54>;
17+
size = <256>;
18+
};
19+
};
20+
21+
&i2c2 {
22+
eeprom1: eeprom@56 {
23+
compatible = "zephyr,i2c-target-eeprom";
24+
reg = <0x56>;
25+
size = <256>;
26+
};
27+
};

tests/drivers/i2c/i2c_target_api/testcase.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,13 @@ tests:
2525
- nucleo_f401re
2626
- nucleo_f429zi
2727
- nucleo_h503rb
28-
- nucleo_wl55jc
28+
- nucleo_h753zi
2929
- nucleo_l073rz
3030
- nucleo_l152re
3131
- nucleo_u083rc
3232
- nucleo_u385rg_q
3333
- nucleo_wba55cg
34+
- nucleo_wl55jc
3435
- nucleo_wb55rg
3536
- rpi_pico
3637
- sltb010a@0

0 commit comments

Comments
 (0)