Skip to content

Commit 8b54e8a

Browse files
teburdkartben
authored andcommitted
boards: frdm-mcxn947: Enable flexcomm3
Flexcomm3 is used for the mikrobus header, enable the clock for it and setup a pinctrl group for i2c. Signed-off-by: Tom Burdick <[email protected]>
1 parent 163fe87 commit 8b54e8a

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

boards/nxp/frdm_mcxn947/board.c

+6
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,12 @@ void board_early_init_hook(void)
159159
CLOCK_AttachClk(kFRO_HF_DIV_to_FLEXCOMM2);
160160
#endif
161161

162+
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(flexcomm3))
163+
/* Configure input clock to be able to reach the datasheet specified SPI band rate. */
164+
CLOCK_SetClkDiv(kCLOCK_DivFlexcom3Clk, 1u);
165+
CLOCK_AttachClk(kFRO_HF_DIV_to_FLEXCOMM3);
166+
#endif
167+
162168
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(flexcomm4))
163169
/* Configure input clock to be able to reach the datasheet specified SPI band rate. */
164170
CLOCK_SetClkDiv(kCLOCK_DivFlexcom4Clk, 1u);

boards/nxp/frdm_mcxn947/frdm_mcxn947-pinctrl.dtsi

+12
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,18 @@
3131
};
3232
};
3333

34+
pinmux_flexcomm3_lpi2c: pinmux_flexcomm3_lpi2c {
35+
group0 {
36+
pinmux = <FC3_P0_PIO1_0>,
37+
<FC3_P1_PIO1_1>;
38+
slew-rate = "fast";
39+
drive-strength = "low";
40+
input-enable;
41+
bias-pull-up;
42+
drive-open-drain;
43+
};
44+
};
45+
3446
pinmux_flexcomm7_lpi2c: pimux_flexcomm7_lpi2c {
3547
group0 {
3648
pinmux = <FC7_P0_PIO3_2>,

0 commit comments

Comments
 (0)