@@ -22,6 +22,8 @@ processor_version: 0.15.0
2222 */
2323/* clang-format on */
2424
25+ #include "rtconfig.h"
26+
2527#include "fsl_common.h"
2628#include "fsl_port.h"
2729#include "pin_mux.h"
@@ -159,6 +161,109 @@ void BOARD_InitPins(void)
159161 kPORT_UnlockRegister };
160162 /* PORT3_12 (pin 63) is configured as LED_RED */
161163 PORT_SetPinConfig (PORT3 , 12U , & port3_12_pin63_config );
164+
165+ #ifdef BSP_USING_SPI1
166+ const port_pin_config_t port2_12_pin34_config = {/* Internal pull-up/down resistor is disabled */
167+ kPORT_PullDisable ,
168+ /* Low internal pull resistor value is selected. */
169+ kPORT_LowPullResistor ,
170+ /* Fast slew rate is configured */
171+ kPORT_FastSlewRate ,
172+ /* Passive input filter is disabled */
173+ kPORT_PassiveFilterDisable ,
174+ /* Open drain output is disabled */
175+ kPORT_OpenDrainDisable ,
176+ /* Low drive strength is configured */
177+ kPORT_LowDriveStrength ,
178+ /* Normal drive strength is configured */
179+ kPORT_NormalDriveStrength ,
180+ /* Pin is configured as LPSPI1_SCK */
181+ kPORT_MuxAlt2 ,
182+ /* Digital input enabled */
183+ kPORT_InputBufferEnable ,
184+ /* Digital input is not inverted */
185+ kPORT_InputNormal ,
186+ /* Pin Control Register fields [15:0] are not locked */
187+ kPORT_UnlockRegister };
188+ /* PORT2_12 (pin 34) is configured as LPSPI1_SCK */
189+ PORT_SetPinConfig (PORT2 , 12U , & port2_12_pin34_config );
190+
191+ const port_pin_config_t port2_13_pin35_config = {/* Internal pull-up/down resistor is disabled */
192+ kPORT_PullDisable ,
193+ /* Low internal pull resistor value is selected. */
194+ kPORT_LowPullResistor ,
195+ /* Fast slew rate is configured */
196+ kPORT_FastSlewRate ,
197+ /* Passive input filter is disabled */
198+ kPORT_PassiveFilterDisable ,
199+ /* Open drain output is disabled */
200+ kPORT_OpenDrainDisable ,
201+ /* Low drive strength is configured */
202+ kPORT_LowDriveStrength ,
203+ /* Normal drive strength is configured */
204+ kPORT_NormalDriveStrength ,
205+ /* Pin is configured as LPSPI1_SDO */
206+ kPORT_MuxAlt2 ,
207+ /* Digital input enabled */
208+ kPORT_InputBufferEnable ,
209+ /* Digital input is not inverted */
210+ kPORT_InputNormal ,
211+ /* Pin Control Register fields [15:0] are not locked */
212+ kPORT_UnlockRegister };
213+ /* PORT2_13 (pin 35) is configured as LPSPI1_SDO */
214+ PORT_SetPinConfig (PORT2 , 13U , & port2_13_pin35_config );
215+
216+ const port_pin_config_t port2_16_pin37_config = {/* Internal pull-up/down resistor is disabled */
217+ kPORT_PullDisable ,
218+ /* Low internal pull resistor value is selected. */
219+ kPORT_LowPullResistor ,
220+ /* Fast slew rate is configured */
221+ kPORT_FastSlewRate ,
222+ /* Passive input filter is disabled */
223+ kPORT_PassiveFilterDisable ,
224+ /* Open drain output is disabled */
225+ kPORT_OpenDrainDisable ,
226+ /* Low drive strength is configured */
227+ kPORT_LowDriveStrength ,
228+ /* Normal drive strength is configured */
229+ kPORT_NormalDriveStrength ,
230+ /* Pin is configured as LPSPI1_SDI */
231+ kPORT_MuxAlt2 ,
232+ /* Digital input enabled */
233+ kPORT_InputBufferEnable ,
234+ /* Digital input is not inverted */
235+ kPORT_InputNormal ,
236+ /* Pin Control Register fields [15:0] are not locked */
237+ kPORT_UnlockRegister };
238+ /* PORT2_16 (pin 37) is configured as LPSPI1_SDI */
239+ PORT_SetPinConfig (PORT2 , 16U , & port2_16_pin37_config );
240+
241+ const port_pin_config_t port2_6_pin28_config = {/* Internal pull-up/down resistor is disabled */
242+ kPORT_PullDisable ,
243+ /* Low internal pull resistor value is selected. */
244+ kPORT_LowPullResistor ,
245+ /* Fast slew rate is configured */
246+ kPORT_FastSlewRate ,
247+ /* Passive input filter is disabled */
248+ kPORT_PassiveFilterDisable ,
249+ /* Open drain output is disabled */
250+ kPORT_OpenDrainDisable ,
251+ /* Low drive strength is configured */
252+ kPORT_LowDriveStrength ,
253+ /* Normal drive strength is configured */
254+ kPORT_NormalDriveStrength ,
255+ /* Pin is configured as LPSPI1_PCS1 */
256+ kPORT_MuxAsGpio ,
257+ /* Digital input enabled */
258+ kPORT_InputBufferEnable ,
259+ /* Digital input is not inverted */
260+ kPORT_InputNormal ,
261+ /* Pin Control Register fields [15:0] are not locked */
262+ kPORT_UnlockRegister };
263+ /* PORT2_6 (pin 20) is configured as LPSPI1_PCS1 */
264+ PORT_SetPinConfig (PORT2 , 6U , & port2_6_pin28_config );
265+ #endif
266+
162267}
163268/***********************************************************************************************************************
164269 * EOF
0 commit comments