File tree Expand file tree Collapse file tree 5 files changed +24
-0
lines changed Expand file tree Collapse file tree 5 files changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -124,6 +124,13 @@ static int frdm_mcxa156_init(void)
124
124
CLOCK_EnableClock (kCLOCK_GateDAC0 );
125
125
#endif
126
126
127
+ #if DT_NODE_HAS_STATUS_OKAY (DT_NODELABEL (lpadc0 ))
128
+ CLOCK_SetClockDiv (kCLOCK_DivADC0 , 1u );
129
+ CLOCK_AttachClk (kFRO12M_to_ADC0 );
130
+
131
+ CLOCK_EnableClock (kCLOCK_GateADC0 );
132
+ #endif
133
+
127
134
/* Set SystemCoreClock variable. */
128
135
SystemCoreClock = CLOCK_INIT_CORE_CLOCK ;
129
136
Original file line number Diff line number Diff line change @@ -54,6 +54,8 @@ The FRDM-MCXA156 board configuration supports the following hardware features:
54
54
+-----------+------------+-------------------------------------+
55
55
| FLASH | on-chip | soc flash |
56
56
+-----------+------------+-------------------------------------+
57
+ | ADC | on-chip | adc |
58
+ +-----------+------------+-------------------------------------+
57
59
| DAC | on-chip | dac |
58
60
+-----------+------------+-------------------------------------+
59
61
| PWM | on-chip | pwm |
Original file line number Diff line number Diff line change 31
31
drive-strength = "low";
32
32
};
33
33
};
34
+ pinmux_lpadc0: pinmux_lpadc0 {
35
+ group0 {
36
+ pinmux = <ADC0_A0_P2_0>,
37
+ <ADC0_A1_P2_1>;
38
+ slew-rate = "fast";
39
+ drive-strength = "low";
40
+ };
41
+ };
34
42
};
Original file line number Diff line number Diff line change 101
101
pinctrl-0 = <&pinmux_flexpwm0_pwm0>;
102
102
pinctrl-names = "default";
103
103
};
104
+
105
+ &lpadc0 {
106
+ status = "okay";
107
+ pinctrl-0 = <&pinmux_lpadc0>;
108
+ pinctrl-names = "default";
109
+ };
Original file line number Diff line number Diff line change @@ -15,6 +15,7 @@ toolchain:
15
15
- gnuarmemb
16
16
- xtools
17
17
supported :
18
+ - adc
18
19
- flash
19
20
- gpio
20
21
- dac
You can’t perform that action at this time.
0 commit comments