File tree Expand file tree Collapse file tree 5 files changed +65
-0
lines changed
tests/drivers/pwm/pwm_api Expand file tree Collapse file tree 5 files changed +65
-0
lines changed Original file line number Diff line number Diff line change 80
80
slew-rate = "fast";
81
81
};
82
82
};
83
+
84
+ pinmux_flexio_pwm: pinmux_flexio_pwm {
85
+ group0 {
86
+ pinmux = <FLEXIO0_D20_PTC4>;
87
+ drive-strength = "low";
88
+ slew-rate = "fast";
89
+ };
90
+ };
91
+
83
92
};
Original file line number Diff line number Diff line change 77
77
drive-open-drain;
78
78
};
79
79
};
80
+
81
+ pinmux_flexio_pwm: pinmux_flexio_pwm {
82
+ group0 {
83
+ pinmux = <FLEXIO0_D20_PTC4>;
84
+ drive-strength = "low";
85
+ slew-rate = "fast";
86
+ };
87
+ };
80
88
};
Original file line number Diff line number Diff line change
1
+ /*
2
+ * Copyright 2025 NXP
3
+ *
4
+ * SPDX-License-Identifier: Apache-2.0
5
+ */
6
+
7
+ / {
8
+ aliases {
9
+ pwm-0 = &flexio_pwm;
10
+ };
11
+ };
12
+
13
+ /* Conflicting gpio pins */
14
+ &flexcan0 {
15
+ status = "disabled";
16
+ };
17
+
18
+ &flexio {
19
+ status = "okay";
20
+ flexio_pwm: flexio_pwm {
21
+ status = "okay";
22
+ pinctrl-0 = <&pinmux_flexio_pwm>;
23
+ pinctrl-names = "default";
24
+
25
+ pwm_0 {
26
+ pin-id = <20>;
27
+ prescaler = <1>;
28
+ };
29
+ };
30
+ };
Original file line number Diff line number Diff line change 75
75
#define DEFAULT_PULSE_CYCLE 16384
76
76
#define DEFAULT_PERIOD_NSEC 2000000
77
77
#define DEFAULT_PULSE_NSEC 500000
78
+ #elif defined(CONFIG_SOC_SERIES_MCXW )
79
+ #define DEFAULT_PERIOD_CYCLE 64000
80
+ #define DEFAULT_PULSE_CYCLE 32000
81
+ #define DEFAULT_PERIOD_NSEC 4000000
82
+ #define DEFAULT_PULSE_NSEC 2000000
78
83
#else
79
84
#define DEFAULT_PERIOD_CYCLE 64000
80
85
#define DEFAULT_PULSE_CYCLE 32000
Original file line number Diff line number Diff line change @@ -53,3 +53,16 @@ tests:
53
53
- native_sim
54
54
integration_platforms :
55
55
- native_sim
56
+ drivers.pwm.mcxw7x_flexio_pwm :
57
+ tags :
58
+ - drivers
59
+ - pwm
60
+ - userspace
61
+ extra_args : DTC_OVERLAY_FILE="boards/frdm_mcxw7x_flexio_pwm.overlay"
62
+ platform_allow :
63
+ - frdm_mcxw71
64
+ - frdm_mcxw72/mcxw727c/cpu0
65
+ filter : (dt_alias_exists("pwm-0") or dt_alias_exists("pwm-1") or dt_alias_exists("pwm-2")
66
+ or dt_alias_exists("pwm-3")) and CONFIG_DT_HAS_NXP_FLEXIO_ENABLED and
67
+ CONFIG_DT_HAS_NXP_FLEXIO_PWM_ENABLED
68
+ depends_on : pwm
You can’t perform that action at this time.
0 commit comments